Skip to content

Commit e89452f

Browse files
ychampionOmX
andcommitted
Make Goal Capsules discoverable as Edgebase-native commands
Add the branded /edgebase-goal surface across Claude Code, Codex, MCP prompts, setup diagnostics, and docs while preserving /goal as a compatibility alias. Also add an installed-version CLI check and make Codex setup skip user-owned unmarked skills instead of aborting. Constraint: Public OSS setup needs pasteable agent onboarding, clear branded commands, and config preservation without committing project-local agent files. Rejected: Keep only /goal as the explicit command | too generic for discovery and harder to associate with Edgebase after setup. Confidence: high Scope-risk: moderate Directive: Keep /goal compatibility unless a future major release intentionally migrates existing users. Tested: python3 -m compileall -q src tests; python3 -m unittest -v; git diff --check; static script scan for assets/docs; temporary venv install, setup, doctor, slash-skill file checks, hook preflight smoke, and edgebase --version. Not-tested: Interactive slash-command rendering inside live Claude Code or Codex after client restart. Co-authored-by: OmX <omx@oh-my-codex.dev>
1 parent 18dd25d commit e89452f

16 files changed

Lines changed: 408 additions & 84 deletions

‎CHANGELOG.md‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
## Unreleased
44

5+
## 0.1.6 - 2026-05-26
6+
7+
### Added
8+
9+
- Branded `/edgebase-goal <goal>` project skills for Claude Code and Codex, plus an `edgebase-goal` MCP prompt for clients that expose prompt menus.
10+
- Doctor checks and setup coverage for the new branded Goal Capsule command.
11+
- `edgebase --version` for quick installed-version checks.
12+
13+
### Changed
14+
15+
- `/goal <goal>` remains installed as a compatibility alias, while docs now lead with `/edgebase-goal` to make the command easier to associate with Edgebase.
16+
- Codex setup now skips unmarked existing project skills instead of aborting setup, matching the existing Claude Code preservation behavior.
17+
518
## 0.1.5 - 2026-05-26
619

720
### Added

‎README.md‎

Lines changed: 30 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ Its flagship feature is **Goal Capsules**: short, executable briefs that tell Co
2828
- Runs locally with no Docker, cloud service, graph database, or API key.
2929
- Preserves provenance for every edge: path, line, extractor, confidence, commit, and freshness.
3030

31-
```bash
32-
python3 -m edgebase goal "Add passwordless login support without breaking existing OAuth"
31+
```text
32+
/edgebase-goal "Add passwordless login support without breaking existing OAuth"
3333
```
3434

3535
```text
@@ -65,7 +65,7 @@ Patch contract:
6565
The final PR must include changed files, rationale, tests run, regression evidence, and unresolved assumptions.
6666
```
6767

68-
Goal Capsules are backed by the local graph index, git state, inferred tests, provenance, and working-tree freshness. They are recorded automatically by supported hooks, exposed as `/goal ...` when a manual command is useful, and called through CLI/MCP before write tools run. The same agent-facing paths also refresh optional local graph artifacts at `.edgebase/graphs/latest.html`, `.json`, and `.dot`; agents surface the paths without dumping raw graph data into context.
68+
Goal Capsules are backed by the local graph index, git state, inferred tests, provenance, and working-tree freshness. They are recorded automatically by supported hooks, exposed as `/edgebase-goal ...` when a manual command is useful, and called through CLI/MCP before write tools run. `/goal ...` remains installed as a shorter compatibility alias. The same agent-facing paths also refresh optional local graph artifacts at `.edgebase/graphs/latest.html`, `.json`, and `.dot`; agents surface the paths without dumping raw graph data into context.
6969

7070
Edgebase also keeps `AGENTS.md` small, indexes the repository into a rebuildable SQLite graph, and exposes MCP tools that agents can use before editing:
7171

@@ -130,7 +130,7 @@ Rules:
130130
- Do not add generated architecture summaries to AGENTS.md.
131131
- Do not remove existing agent config.
132132
- Do not commit unless I explicitly ask.
133-
- Explain that Edgebase is on by default after setup, can be disabled with `python3 -m edgebase disable --scope both`, and can be bypassed for one emergency session with `EDGEBASE_PREFLIGHT=off`.
133+
- Explain that Edgebase is on by default after setup, can be disabled with `edgebase disable --scope both`, and can be bypassed for one emergency session with `EDGEBASE_PREFLIGHT=off`.
134134
```
135135

136136
If you are setting up a remote repository, change the target line:
@@ -151,7 +151,7 @@ python3 -m edgebase setup --scope both
151151
python3 -m edgebase doctor --scope both
152152
```
153153

154-
Edgebase is enabled by default after setup. Turn it off with `python3 -m edgebase disable --scope both`.
154+
Edgebase is enabled by default after setup. Turn it off with `edgebase disable --scope both`.
155155

156156
To bypass only the edit gate for one emergency session without removing MCP config:
157157

@@ -168,8 +168,8 @@ EDGEBASE_PREFLIGHT=off
168168
| Edgebase cache/artifacts | `.edgebase/index.sqlite3`, `.edgebase/graphs/latest.*` | none | Rebuildable local graph cache plus optional visual artifacts, ignored by git |
169169
| Git ignore | `.git/info/exclude` | none | Locally ignores `.edgebase/` without changing committed ignore files |
170170
| Agent instructions | `AGENTS.md` marker block | none | Tells agents to use Edgebase automatically for broad exploration/editing |
171-
| Claude Code | `.mcp.json`, `.claude/settings.json`, `.claude/skills/edgebase/SKILL.md`, `.claude/skills/goal/SKILL.md` | none by default | MCP server, automatic Goal Capsules, PreToolUse stale-capsule blocking, SessionStart/PostToolUse/PreCompact/SessionEnd hooks, `/edgebase` and `/goal` skills |
172-
| Codex | `.codex/config.toml`, `.codex/hooks.json`, `.agents/skills/edgebase/SKILL.md`, `.agents/skills/goal/SKILL.md` | `~/.codex/config.toml` | MCP server entry, project hook config, project skills, AGENTS.md routing |
171+
| Claude Code | `.mcp.json`, `.claude/settings.json`, `.claude/skills/edgebase/SKILL.md`, `.claude/skills/edgebase-goal/SKILL.md`, `.claude/skills/goal/SKILL.md` | none by default | MCP server, automatic Goal Capsules, PreToolUse stale-capsule blocking, SessionStart/PostToolUse/PreCompact/SessionEnd hooks, `/edgebase`, `/edgebase-goal`, and `/goal` skills |
172+
| Codex | `.codex/config.toml`, `.codex/hooks.json`, `.agents/skills/edgebase/SKILL.md`, `.agents/skills/edgebase-goal/SKILL.md`, `.agents/skills/goal/SKILL.md` | `~/.codex/config.toml` | MCP server entry, project hook config, project skills, AGENTS.md routing |
173173
| Cursor | `.cursor/mcp.json` | `~/.cursor/mcp.json` | MCP server entry |
174174
| Gemini CLI | `.gemini/settings.json` | `~/.gemini/settings.json` | MCP server entry |
175175
| OpenCode | `.opencode.json` | `~/.opencode.json` | Enabled local MCP server |
@@ -184,24 +184,31 @@ Setup uses the Python interpreter that ran setup, with `-m edgebase`, instead of
184184

185185
Most users do not run Edgebase manually after setup.
186186

187-
- Claude Code: `UserPromptSubmit` records and injects a Goal Capsule before planning. `PreToolUse` blocks Write/Edit/MultiEdit if no fresh capsule exists. `PostToolUse` refreshes the graph after edits. `PreCompact` saves a checkpoint, and `SessionEnd` saves a Patch Passport. Project skills `/edgebase <task>` and `/goal <goal>` are installed as explicit commands.
188-
- Codex: setup writes MCP config, project `.codex/hooks.json`, `[features] hooks = true`, `.agents/skills/edgebase`, `.agents/skills/goal`, and the `AGENTS.md` marker. Codex uses MCP plus project skills by default; when trusted hook support is active, the same preflight gate records capsules, blocks stale edits, refreshes after edits, checkpoints before compaction, and saves a Patch Passport on stop.
187+
- Claude Code: `UserPromptSubmit` records and injects a Goal Capsule before planning. `PreToolUse` blocks Write/Edit/MultiEdit if no fresh capsule exists. `PostToolUse` refreshes the graph after edits. `PreCompact` saves a checkpoint, and `SessionEnd` saves a Patch Passport. Project skills `/edgebase <task>` and `/edgebase-goal <goal>` are installed as explicit commands; `/goal <goal>` remains as a compatibility alias.
188+
- Codex: setup writes MCP config, project `.codex/hooks.json`, `[features] hooks = true`, `.agents/skills/edgebase`, `.agents/skills/edgebase-goal`, `.agents/skills/goal`, and the `AGENTS.md` marker. Codex uses MCP plus project skills by default; when trusted hook support is active, the same preflight gate records capsules, blocks stale edits, refreshes after edits, checkpoints before compaction, and saves a Patch Passport on stop.
189189
- Cursor, Gemini CLI, OpenCode, and Windsurf: Edgebase installs MCP config and a marker-bounded `AGENTS.md` instruction telling agents to use `edgebase_context` or `edgebase_goal` automatically before broad code exploration or edits. Those MCP calls update `.edgebase/graphs/latest.*` and return the artifact paths.
190-
- Any client: the MCP prompts named `edgebase` and `goal` are available for clients that expose MCP prompts or slash-command-style prompt menus.
190+
- Any client: the MCP prompts named `edgebase`, `edgebase-goal`, and `goal` are available for clients that expose MCP prompts or slash-command-style prompt menus.
191191

192-
Useful manual commands:
192+
Useful explicit slash commands inside supported agent REPLs/apps:
193+
194+
```text
195+
/edgebase "change the auth login flow"
196+
/edgebase-goal "add passwordless login without breaking OAuth"
197+
```
198+
199+
Shell fallback and verification commands:
193200

194201
```bash
195-
python3 -m edgebase context "change the auth login flow" --budget 1200
196-
python3 -m edgebase goal "add passwordless login without breaking OAuth" --budget 1200
197-
python3 -m edgebase passport "add passwordless login without breaking OAuth" --test "python3 -m unittest -v: pass"
198-
python3 -m edgebase preflight status
199-
python3 -m edgebase checkpoint "handoff after auth refactor"
200-
python3 -m edgebase resume
201-
python3 -m edgebase index --changed
202-
python3 -m edgebase stats
203-
python3 -m edgebase doctor --scope both
204-
python3 -m edgebase disable --scope both
202+
edgebase context "change the auth login flow" --budget 1200
203+
edgebase goal "add passwordless login without breaking OAuth" --budget 1200
204+
edgebase passport "add passwordless login without breaking OAuth" --test "python3 -m unittest -v: pass"
205+
edgebase preflight status
206+
edgebase checkpoint "handoff after auth refactor"
207+
edgebase resume
208+
edgebase index --changed
209+
edgebase stats
210+
edgebase doctor --scope both
211+
edgebase disable --scope both
205212
```
206213

207214
## What It Indexes
@@ -219,7 +226,7 @@ Dynamic-language call graphs are confidence-scored. Low-confidence call edges ar
219226

220227
| Agent | Status | Notes |
221228
| --- | --- | --- |
222-
| Claude Code | Supported | Project `.mcp.json`; automatic UserPromptSubmit Goal Capsule; PreToolUse stale-capsule block; async PostToolUse refresh; PreCompact checkpoint; SessionEnd Patch Passport; `/edgebase` and `/goal` project skills |
229+
| Claude Code | Supported | Project `.mcp.json`; automatic UserPromptSubmit Goal Capsule; PreToolUse stale-capsule block; async PostToolUse refresh; PreCompact checkpoint; SessionEnd Patch Passport; `/edgebase`, `/edgebase-goal`, and `/goal` project skills |
223230
| Codex | Supported | Project `.codex/config.toml`, `.codex/hooks.json`, `.agents/skills`; global `~/.codex/config.toml` MCP entry for CLI discovery; verify with `codex mcp list` and `edgebase doctor` |
224231
| Cursor | Supported | Project and global `mcp.json`; Cursor says Composer Agent automatically uses relevant MCP tools |
225232
| Gemini CLI | Supported | Project and global `settings.json` with `mcpServers` |
@@ -257,7 +264,7 @@ Automation layers:
257264
This is not a separate graph UI or a new agent control surface; visualization is kept as a local artifact attached to the existing agent context flow.
258265

259266
See [Architecture](docs/ARCHITECTURE.md) and [Validation](docs/VALIDATION.md).
260-
The latest release audit is documented in [Release Audit](docs/RELEASE_AUDIT_0.1.5.md).
267+
The latest release audit is documented in [Release Audit](docs/RELEASE_AUDIT_0.1.6.md).
261268

262269
## Benchmarks
263270

‎docs/AGENT_CLIENTS.md‎

Lines changed: 30 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,19 @@ Rules:
3939
- Do not add generated architecture summaries to AGENTS.md.
4040
- Do not remove existing agent config.
4141
- Do not commit unless I explicitly ask.
42-
- Explain that Edgebase is on by default after setup, can be disabled with `python3 -m edgebase disable --scope both`, and can be bypassed for one emergency session with `EDGEBASE_PREFLIGHT=off`.
42+
- Explain that Edgebase is on by default after setup, can be disabled with `edgebase disable --scope both`, and can be bypassed for one emergency session with `EDGEBASE_PREFLIGHT=off`.
4343
```
4444

4545
For a remote repository, replace the target line with `Repository target: https://github.com/OWNER/REPO`.
4646

47-
Default state after setup: **on** for selected agents. The manual fallback commands are:
47+
Default state after setup: **on** for selected agents. In Claude Code, Codex, and clients that expose MCP prompts as slash commands, use:
48+
49+
```text
50+
/edgebase "implement password reset"
51+
/edgebase-goal "implement password reset without regressing login"
52+
```
53+
54+
The shell fallback commands are:
4855

4956
```bash
5057
python3 -m pip install --user --upgrade git+https://github.com/ychampion/edgebase.git
@@ -55,7 +62,7 @@ python3 -m edgebase doctor --scope both
5562
Turn it off with:
5663

5764
```bash
58-
python3 -m edgebase disable --scope both
65+
edgebase disable --scope both
5966
```
6067

6168
See [Universal Agent Install Prompt](UNIVERSAL_AGENT_PROMPT.md) for a standalone copy/paste prompt.
@@ -71,11 +78,13 @@ Setup writes or updates only local configuration files:
7178
- `.mcp.json`: Claude Code project MCP server.
7279
- `.claude/settings.json`: Claude Code SessionStart, UserPromptSubmit, PreToolUse, async PostToolUse, PreCompact, and SessionEnd hooks.
7380
- `.claude/skills/edgebase/SKILL.md`: Claude Code project skill exposed as `/edgebase <task>`.
74-
- `.claude/skills/goal/SKILL.md`: Claude Code project skill exposed as `/goal <goal>`.
81+
- `.claude/skills/edgebase-goal/SKILL.md`: Claude Code project skill exposed as `/edgebase-goal <goal>`.
82+
- `.claude/skills/goal/SKILL.md`: Claude Code compatibility skill exposed as `/goal <goal>`.
7583
- `.codex/config.toml` and/or `~/.codex/config.toml`: Codex MCP server plus project `[features] hooks = true`.
7684
- `.codex/hooks.json`: Codex project hook commands for the preflight gate.
7785
- `.agents/skills/edgebase/SKILL.md`: Codex project skill exposed as `/edgebase <task>` where project skills are enabled.
78-
- `.agents/skills/goal/SKILL.md`: Codex project skill exposed as `/goal <goal>`.
86+
- `.agents/skills/edgebase-goal/SKILL.md`: Codex project skill exposed as `/edgebase-goal <goal>` where project skills are enabled.
87+
- `.agents/skills/goal/SKILL.md`: Codex compatibility skill exposed as `/goal <goal>`.
7988
- `.cursor/mcp.json` and/or `~/.cursor/mcp.json`: Cursor MCP server.
8089
- `.gemini/settings.json` and/or `~/.gemini/settings.json`: Gemini CLI MCP server.
8190
- `.opencode.json` and/or `~/.opencode.json`: OpenCode local MCP server.
@@ -109,14 +118,15 @@ It also writes `.claude/settings.json` hooks:
109118
- `PreCompact`: saves `.edgebase/checkpoints/latest.md` before compaction.
110119
- `SessionEnd`: saves `.edgebase/passports/latest.md` and `.json` at session end.
111120

112-
It also writes a project skill:
121+
It also writes project skills:
113122

114123
```text
115124
/edgebase <task>
125+
/edgebase-goal <goal>
116126
/goal <goal>
117127
```
118128

119-
Use `/edgebase` when you want a compact read set. Use `/goal` when you want an executable Goal Capsule with blast radius, protected areas, required checks, and a patch contract. Normal coding prompts do not need the phrase "Use edgebase_context"; the prompt hook records and supplies the Goal Capsule automatically when the prompt looks like implementation, debugging, review, or investigation work.
129+
Use `/edgebase` when you want a compact read set. Use `/edgebase-goal` when you want an executable Goal Capsule with blast radius, protected areas, required checks, and a patch contract. `/goal` is kept as a shorter compatibility alias. Normal coding prompts do not need the phrase "Use edgebase_context"; the prompt hook records and supplies the Goal Capsule automatically when the prompt looks like implementation, debugging, review, or investigation work.
120130

121131
Hook and MCP responses may include `.edgebase/graphs/latest.*` paths. Treat them as local visual aids for relationship inspection; do not paste raw graph JSON or DOT back into agent context.
122132

@@ -162,6 +172,7 @@ And project skills:
162172

163173
```text
164174
/edgebase <task>
175+
/edgebase-goal <goal>
165176
/goal <goal>
166177
```
167178

@@ -170,7 +181,7 @@ Useful check:
170181
```bash
171182
codex mcp list
172183
codex mcp get edgebase
173-
python3 -m edgebase doctor --agents codex --scope project
184+
edgebase doctor --agents codex --scope project
174185
```
175186

176187
The currently verified Codex CLI path reads `~/.codex/config.toml`, so the frictionless install command uses `--scope both`. Edgebase also writes `.codex/config.toml`, `.codex/hooks.json`, and `.agents/skills/*` for project-local workflows. When Codex trusts project hooks, the hook path gives the same preflight behavior as Claude Code: Goal Capsule before planning, edit block if stale, refresh after edit, checkpoint before compaction, and Patch Passport on stop.
@@ -239,35 +250,35 @@ Project scope is skipped for Windsurf because Windsurf's documented config path
239250
When MCP is unavailable:
240251

241252
```bash
242-
python3 -m edgebase context "implement password reset" --changed-file src/auth.py --budget 1200
243-
python3 -m edgebase goal "implement password reset without regressing login" --changed-file src/auth.py --budget 1200
244-
python3 -m edgebase passport "implement password reset without regressing login" --test "python3 -m unittest -v: pass"
245-
python3 -m edgebase preflight status
246-
python3 -m edgebase preflight refresh "implement password reset without regressing login"
247-
python3 -m edgebase checkpoint "handoff after password reset"
248-
python3 -m edgebase resume
253+
edgebase context "implement password reset" --changed-file src/auth.py --budget 1200
254+
edgebase goal "implement password reset without regressing login" --changed-file src/auth.py --budget 1200
255+
edgebase passport "implement password reset without regressing login" --test "python3 -m unittest -v: pass"
256+
edgebase preflight status
257+
edgebase preflight refresh "implement password reset without regressing login"
258+
edgebase checkpoint "handoff after password reset"
259+
edgebase resume
249260
```
250261

251-
MCP clients that expose prompts can also use the MCP prompts named `edgebase` and `goal`, which return the same source-backed capsule surfaces in prompt form.
262+
MCP clients that expose prompts can also use the MCP prompts named `edgebase`, `edgebase-goal`, and `goal`, which return the same source-backed capsule surfaces in prompt form.
252263

253264
MCP and hook paths refresh `.edgebase/graphs/latest.html`, `.json`, and `.dot` automatically. Open or inspect those local artifacts only when a visual file relationship view helps the task.
254265

255266
Refresh:
256267

257268
```bash
258-
python3 -m edgebase index --changed
269+
edgebase index --changed
259270
```
260271

261272
Disable:
262273

263274
```bash
264-
python3 -m edgebase disable --scope both
275+
edgebase disable --scope both
265276
```
266277

267278
Re-enable:
268279

269280
```bash
270-
python3 -m edgebase setup --scope both
281+
edgebase setup --scope both
271282
```
272283

273284
## Compatibility References

‎docs/ARCHITECTURE.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,11 @@ Claude Code has documented prompt and tool hooks, so Edgebase provides:
132132
- `PreCompact`: context checkpoint before compaction.
133133
- `SessionEnd`: Patch Passport at session end.
134134
- project skill `/edgebase <task>` for explicit manual refresh.
135-
- project skill `/goal <goal>` for explicit Goal Capsules.
135+
- project skill `/edgebase-goal <goal>` for explicit Goal Capsules, with `/goal <goal>` as a compatibility alias.
136136

137-
Codex setup is MCP plus project-scoped hooks and skills. Edgebase writes `.codex/config.toml`, `[features] hooks = true`, `.codex/hooks.json`, `.agents/skills/edgebase`, and `.agents/skills/goal`. When project hooks are trusted, Codex receives the same preflight gate: prompt-time capsule, stale edit block, post-edit refresh, pre-compact checkpoint, and stop-time Patch Passport.
137+
Codex setup is MCP plus project-scoped hooks and skills. Edgebase writes `.codex/config.toml`, `[features] hooks = true`, `.codex/hooks.json`, `.agents/skills/edgebase`, `.agents/skills/edgebase-goal`, and `.agents/skills/goal`. When project hooks are trusted, Codex receives the same preflight gate: prompt-time capsule, stale edit block, post-edit refresh, pre-compact checkpoint, and stop-time Patch Passport.
138138

139-
Cursor, Gemini CLI, OpenCode, and Windsurf are MCP-first. For those clients, setup writes MCP config and an `AGENTS.md` marker that instructs the agent to route broad structural context through Edgebase automatically. Edgebase also exposes MCP prompts named `edgebase` and `goal` for clients that surface prompt menus.
139+
Cursor, Gemini CLI, OpenCode, and Windsurf are MCP-first. For those clients, setup writes MCP config and an `AGENTS.md` marker that instructs the agent to route broad structural context through Edgebase automatically. Edgebase also exposes MCP prompts named `edgebase`, `edgebase-goal`, and `goal` for clients that surface prompt menus.
140140

141141
MCP tool and prompt responses also refresh graph artifacts and return the local artifact paths when rendering succeeds. Rendering failures are non-fatal; Edgebase must still return the context or Goal Capsule.
142142

0 commit comments

Comments
 (0)