utils/attachments/attachment_manager library
Classes
- Attachment
- Base attachment type.
- BudgetUsdAttachment
- Budget (USD) attachment.
- CompactFileReferenceAttachment
- Compact file reference (file was already in context, just reference it).
- DateChangeAttachment
- Date change attachment.
- DiagnosticsAttachment
- Diagnostics attachment (LSP or other diagnostic files).
- DirectoryAttachment
- Directory listing attachment.
- EditedTextFileAttachment
- Edited text file attachment.
- FileAttachment
- File attachment (user at-mentioned a file).
- HookAttachment
- Hook attachment base.
- HookCancelledAttachment
- Hook cancelled attachment.
- HookPermissionDecisionAttachment
- Hook permission decision attachment.
- HookSuccessAttachment
- Hook success attachment.
- MaxTurnsReachedAttachment
- Max turns reached attachment.
- McpResourceAttachment
- MCP resource attachment.
- MemoryEntry
- A single memory entry.
- OpenedFileInIdeAttachment
- Opened file in IDE attachment.
- OutputStyleAttachment
- Output style attachment.
- PDFReferenceAttachment
- PDF reference attachment.
- PlanModeAttachment
- Plan mode attachment.
- QueuedCommandAttachment
- Queued command attachment (user typed while model was working).
- RelevantMemoriesAttachment
- Relevant memories attachment.
- SelectedLinesInIdeAttachment
- IDE selection attachment (lines selected in an IDE).
- TodoReminderAttachment
- Todo reminder attachment.
- TokenUsageAttachment
- Token usage attachment.
Constants
- autoModeAttachmentConfig → const ({int fullReminderEveryNAttachments, int turnsBetweenAttachments})
- Config for auto mode attachment frequency.
- maxMemoryBytes → const int
- Max bytes from a memory file to inject.
- maxMemoryLines → const int
- Max lines from a memory file to inject.
- memoryHeader → const String
- Header prefix for memory file attachments.
- planModeAttachmentConfig → const ({int fullReminderEveryNAttachments, int turnsBetweenAttachments})
- Config for plan mode attachment frequency.
- relevantMemoriesConfig → const ({int maxSessionBytes})
- Config for relevant memories injection.
- todoReminderConfig → const ({int turnsBetweenReminders, int turnsSinceWrite})
- Config for todo reminder frequency.
- verifyPlanReminderConfig → const ({int turnsBetweenReminders})
- Config for plan verification reminders.
Functions
-
getQueuedCommandAttachments(
List< Map< queuedCommands) → List<String, dynamic> >Attachment> - Get queued command attachments from a list of queued commands.
-
normalizeAttachmentsForAPI(
List< Map< attachments) → List<String, dynamic> >UserMessage> - Normalize a list of attachment maps into user messages for API.
-
parseAttachment(
Map< String, dynamic> json) → Attachment? - Normalize an attachment map into the typed attachment.