Documentation Index
Fetch the complete documentation index at: https://mintlify.com/remorses/kimaki/llms.txt
Use this file to discover all available pages before exploring further.
File Attachments
Kimaki processes file attachments in Discord messages, making them available to the AI for analysis, reference, and understanding.Supported File Types
Kimaki handles three categories of attachments:Text Files
Text-based files are read and included directly in the prompt:text/*(.txt,.md,.log, etc.)application/jsonapplication/xmlapplication/javascript/application/typescriptapplication/x-yamlapplication/toml
Images
Image files are processed and sent as base64 data URLs:image/pngimage/jpegimage/gifimage/webp
- Resized if larger than 2048x2048 pixels
- Converted to JPEG for efficient transmission
- Compressed to reduce token usage
discord/src/image-utils.ts:
PDFs
PDF files are processed similarly to images:application/pdf
How It Works
Attach files to message
Click the + icon in Discord and select files to attach.You can attach multiple files to a single message.
Kimaki downloads attachments
Files are fetched from Discord’s CDN.From
message-formatting.ts:234-273:Files added to message parts
Text attachments are included as XML blocks.Images/PDFs are added as file parts with base64 data URLs.
Text Attachment Format
Text files are wrapped in XML tags for clarity:Image Processing
Images go through a processing pipeline to optimize size and format:Use Cases
Screenshot debugging
Screenshot debugging
Attach screenshots of errors, UI bugs, or unexpected behavior.The AI can analyze the image and suggest fixes based on what it sees.
Code review from images
Code review from images
Take a photo of code on a screen or whiteboard.The AI can read the code and provide feedback.
Log file analysis
Log file analysis
Attach
.log files from your application.The AI can parse errors, identify patterns, and suggest solutions.Configuration examples
Configuration examples
Share
config.json, .env.example, or YAML files.The AI can validate syntax and suggest improvements.Design mockups
Design mockups
Attach UI mockups or wireframes.Ask the AI to implement the design or critique the layout.
Uploading from CLI
You can upload files to a thread programmatically:Requesting Files from Users
The AI can request files using thekimaki_file_upload tool:
uploads/ directory.
The file upload tool is only available when OpenCode is running via Kimaki, not in standalone OpenCode sessions.
Limitations
Security
Attachments are:- Downloaded from Discord CDN over HTTPS
- Processed in-memory (not saved to disk by default)
- Included in OpenCode sessions with standard permission checks
uploads/ which is outside the project directory by default, triggering permission prompts.
Related Features
- Text Messages - Send prompts without files
- Voice Messages - Audio transcription
- Memory - Persistent project context