CLIコマンド — ターミナルからAIエージェントメモリを管理
npx toon-memory # インタラクティブインストーラー(エージェント選択)npx toon-memory init # エージェント選択のインタラクティブセットアップnpx toon-memory init --agent opencode # ノンインタラクティブ: 特定のエージェントを設定npx toon-memory init --agent opencode --agent claude # 複数エージェントを設定npx toon-memory init --agent opencode --scope global # グローバルに設定npx toon-memory mcp # MCPサーバーを直接実行npx toon-memory status # インストール状態を確認npx toon-memory stats # メモリ統計を表示npx toon-memory export # メモリをJSONにエクスポートnpx toon-memory import <file> # JSONからメモリをインポートnpx toon-memory watch [opts] # オプション付き自動バックアップnpx toon-memory upgrade # 最新バージョンに更新npx toon-memory uninstall # 全エージェントから削除Initオプション
Section titled “Initオプション”| オプション | 説明 | デフォルト |
|---|---|---|
--agent <name> |
ノンインタラクティブ: 特定のエージェントを設定。複数の場合は繰り返す。 | インタラクティブ |
--scope <scope> |
localまたはglobal — エージェント設定の保存先 |
インタラクティブ |
Watchオプション
Section titled “Watchオプション”| オプション | 説明 | デフォルト |
|---|---|---|
[interval] |
バックアップ間隔(分) | 5 |
-c, --compress |
gzip圧縮を有効化 | オフ |
-l, --log [path] |
ファイルログを有効化 | オフ |
-m, --max-backups <n> |
保持する最大バックアップ数(0=無制限) | 10 |
$ npx toon-memory stats
🧠 toon-memory stats
📊 Memory Stats━━━━━━━━━━━━━━━━━━Total entries: 45├── decision: 12├── pattern: 18├── bug: 8└── knowledge: 7Last updated: 2026-07-10File size: 12.4 KBエクスポート
Section titled “エクスポート”$ npx toon-memory export
🧠 toon-memory export
Exported 45 entries to: /path/to/project/toon-memory-export.json$ npx toon-memory import backup.json
🧠 toon-memory import
Imported 3 new entriesSkipped 2 duplicates$ npx toon-memory watch 15 -c -m 20
🧠 toon-memory watch
Watching memory file every 15 minutes...Max backups: 20Compression: enabledLogging: disabledPress Ctrl+C to stop
📦 Backup #1 created: 2026-07-11T16-00-00-000Z📦 Backup #2 created: 2026-07-11T16-15-00-00-000Z^C✅ Watch stopped. 2 backups created.