You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add executionModel feature and refactor CLI into modular commands (#150)
* Add executionModel feature and refactor CLI into modular commands
- Add executionModel config option to memory plugin for specifying AI provider/model
- Refactor monolithic CLI into modular commands: export, import, list, stats, cleanup
- Add model selector UI with connected providers and recent models
- Add showClear prop to Combobox component
- Update documentation and bump version to 0.0.10
* Update execution model placeholder text
* Update docs with new CLI commands and ocm-mem binary usage
* Bump version to v0.9.06
* Add executionModel field to default config
Copy file name to clipboardExpand all lines: docs/features/memory.md
+67-1Lines changed: 67 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,8 @@ The file is only created if it does not already exist. The config is validated o
61
61
"inlinePlanning": true,
62
62
"maxContextTokens": 4000,
63
63
"snapshotToKV": true
64
-
}
64
+
},
65
+
"executionModel": ""
65
66
}
66
67
```
67
68
@@ -105,6 +106,7 @@ Set `baseUrl` to point at any OpenAI-compatible self-hosted service (vLLM, Ollam
105
106
|`compaction.inlinePlanning`| Include planning state in compaction context |`true`|
106
107
|`compaction.maxContextTokens`| Max tokens for injected memory context |`4000`|
107
108
|`compaction.snapshotToKV`| Save pre-compaction snapshot for recovery |`true`|
109
+
|`executionModel`| Model override for plan execution sessions (`provider/model`). Falls back to OpenCode's default model. | — |
108
110
109
111
---
110
112
@@ -364,6 +366,8 @@ Create a new Code session and send an implementation plan as the first prompt. D
364
366
365
367
Saves planning state (objective, phases, findings) for the Architect session, creates a new session via the OpenCode API, then sends the plan as the first message to the Code agent. Returns the session ID and title. Only the Architect agent has access to this tool — it is excluded from Code and Memory agents.
366
368
369
+
The model used for the new Code session is determined by `executionModel` in the plugin config (format: `provider/model`, e.g. `anthropic/claude-sonnet-4-20250514`). If not set, OpenCode's default model resolution is used — typically the `model` field from `opencode.json`.
370
+
367
371
---
368
372
369
373
## Planning State
@@ -564,6 +568,68 @@ The cleanup function is idempotent — calling it multiple times is safe.
564
568
565
569
---
566
570
571
+
## CLI
572
+
573
+
The plugin includes the `ocm-mem` CLI for managing memories outside of OpenCode sessions. The CLI auto-detects the project ID from git and resolves the database path automatically.
574
+
575
+
```bash
576
+
ocm-mem <command> [options]
577
+
```
578
+
579
+
### Global Options
580
+
581
+
| Flag | Description |
582
+
|------|-------------|
583
+
|`--db-path <path>`| Path to memory database |
584
+
|`--project, -p <name>`| Project name or SHA (auto-detected from git) |
585
+
|`--dir, -d <path>`| Git repo path for project detection |
586
+
|`--help, -h`| Show help |
587
+
588
+
### Commands
589
+
590
+
| Command | Description |
591
+
|---------|-------------|
592
+
|`export`| Export memories to file (JSON or Markdown) |
593
+
|`import`| Import memories from file |
594
+
|`list`| List projects with memory and session state counts |
595
+
|`stats`| Show memory statistics for a project |
596
+
|`cleanup`| Delete memories or session states by criteria |
0 commit comments