generated from coulomb/repo-seed
Implement registration UX wishlist W1–W6 (260224)
W1: Document user-scope MCP config location in ~/.claude/CLAUDE.md —
adds verification and re-registration commands, warns against
settings.json (saves ~12K tokens per registration session).
W2: scripts/register_project.sh + make register-project —
5-step automation: API health → topic lookup → MCP check →
CLAUDE.md from template → progress event.
W3: state-hub/scripts/project_claude_md.template —
parameterised CLAUDE.md with {PROJECT_NAME}/{DOMAIN}/{TOPIC_ID}
placeholders; used by register_project.sh.
W4: Add custodian_topic_id + domain to all 6 canon project charters —
lets agents grep for topic IDs without touching the API.
W5: state-hub/mcp_server/TOOLS.md — compact 30-line tool reference
card; replaces reading the full server.py (~350 lines).
W6: Switch .mcp.json to absolute path + PYTHONPATH env so cwd is not
required; add scripts/patch_mcp_cwd.py for post-registration fix.
Update ~/.claude.json to match (cwd kept for belt-and-suspenders).
W7 (SessionStart hook) deferred: no SessionStart hook type in Claude
Code; PreToolUse with empty matcher fires before every tool call.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
32
scripts/project_claude_md.template
Normal file
32
scripts/project_claude_md.template
Normal file
@@ -0,0 +1,32 @@
|
||||
# {PROJECT_NAME} — Claude Code Instructions
|
||||
|
||||
## Custodian State Hub Integration
|
||||
|
||||
This project is tracked as the **{DOMAIN}** domain in the Custodian State Hub.
|
||||
Hub topic ID: `{TOPIC_ID}`
|
||||
|
||||
The State Hub runs locally at http://127.0.0.1:8000. The MCP server (`state-hub`)
|
||||
exposes tools for reading and writing state without touching the API directly.
|
||||
|
||||
### Session Protocol
|
||||
|
||||
**At the start of every session:**
|
||||
1. Call `get_state_summary()` — orients you to active workstreams, blocking decisions,
|
||||
and recent progress. If it fails, the API is likely offline:
|
||||
```
|
||||
cd ~/the-custodian/state-hub && make api
|
||||
```
|
||||
2. Review any `blocking_decisions` entries for this project before starting work.
|
||||
|
||||
**During work:**
|
||||
- Use `create_task()` / `update_task_status()` to track concrete deliverables.
|
||||
- Use `record_decision()` for any decision that affects direction or dependencies.
|
||||
- Use `add_progress_event()` for notable events (milestones, blockers, insights).
|
||||
|
||||
**At the end of every session:**
|
||||
- Call `add_progress_event()` with a summary of what was accomplished or decided.
|
||||
Include `topic_id: {TOPIC_ID}` and the relevant `workstream_id`.
|
||||
|
||||
### Quick Reference
|
||||
|
||||
See `~/the-custodian/state-hub/mcp_server/TOOLS.md` for a compact tool reference.
|
||||
Reference in New Issue
Block a user