View AI virtual memory state and manage persistent memories.
| 24 | |
| 25 | |
| 26 | class MemoryCommand(UnifiedCommand): |
| 27 | """View AI virtual memory state and manage persistent memories.""" |
| 28 | |
| 29 | @property |
| 30 | def name(self) -> str: |
| 31 | return "memory" |
| 32 | |
| 33 | @property |
| 34 | def aliases(self) -> list[str]: |
| 35 | return ["vm", "mem"] |
| 36 | |
| 37 | @property |
| 38 | def description(self) -> str: |
| 39 | return "View AI virtual memory state and manage persistent memories" |
| 40 | |
| 41 | @property |
| 42 | def help_text(self) -> str: |
| 43 | return """ |
| 44 | View AI virtual memory state and manage persistent memories. |
| 45 | |
| 46 | VM Subcommands (requires --vm flag): |
| 47 | /memory - Summary dashboard (mode, pages, utilization, metrics) |
| 48 | /memory pages - Table of all memory pages |
| 49 | /memory page <id> - Detailed view of a specific page |
| 50 | /memory page <id> --download - Download page content to file |
| 51 | /memory stats - Full debug dump of all VM subsystem stats |
| 52 | |
| 53 | Persistent Memory Subcommands: |
| 54 | /memory list [workspace|global] - List persistent memories |
| 55 | /memory add <scope> <key> <content> - Add a memory |
| 56 | /memory remove <scope> <key> - Remove a memory |
| 57 | /memory clear <scope> - Clear all memories in a scope |
| 58 | |
| 59 | Aliases: /vm, /mem |
| 60 | |
| 61 | Examples: |
| 62 | /vm - Quick overview of VM state |
| 63 | /memory list workspace - List workspace memories |
| 64 | /memory add global test_framework "always use pytest" |
| 65 | /memory remove workspace db_type |
| 66 | /memory clear global |
| 67 | """ |
| 68 | |
| 69 | @property |
| 70 | def modes(self) -> CommandMode: |
| 71 | return CommandMode.CHAT |
| 72 | |
| 73 | @property |
| 74 | def parameters(self) -> list[CommandParameter]: |
| 75 | return [ |
| 76 | CommandParameter( |
| 77 | name="action", |
| 78 | type=str, |
| 79 | required=False, |
| 80 | help="Subcommand: pages, page <id>, stats", |
| 81 | ), |
| 82 | ] |
| 83 |
no outgoing calls