Normalize agent instructions and workplan frontmatter (STATE-WP-0067)
Some checks are pending
Build and Deploy / build-push-deploy (push) Waiting to run

- Align agent files with on-disk workplan prefixes (infer from workplan ids)
- Set workplan domain to registered domain_slug; add topic_slug where applicable
- Repair frontmatter delimiter formatting; migrate legacy task status literals
- Regenerate AGENTS.md, CLAUDE.md, and .claude/rules from State Hub templates
This commit is contained in:
2026-06-22 23:16:25 +02:00
parent e93145966f
commit f27e1551c9
27 changed files with 62 additions and 45 deletions

View File

@@ -1,11 +1,11 @@
## First Session Protocol
Triggered when `get_domain_summary("custodian")` shows **no workstreams**.
Triggered when `get_domain_summary("infotech")` shows **no workstreams**.
The project is registered but work has not yet been structured.
**Step 1 — Read, don't write**
- `~/the-custodian/canon/projects/custodian/project_charter_v0.1.md` — purpose, scope
- `~/the-custodian/canon/projects/custodian/roadmap_v0.1.md` — planned phases
- `~/the-custodian/canon/projects/infotech/project_charter_v0.1.md` — purpose, scope
- `~/the-custodian/canon/projects/infotech/roadmap_v0.1.md` — planned phases
- Scan repo root: README, directory structure, existing code or docs
**Step 2 — Survey in-progress work**
@@ -17,7 +17,7 @@ roadmap phase. **Wait for approval before creating.**
**Step 4 — Create workplan file first, then DB record (ADR-001)**
```
workplans/inter-hub-WP-NNNN-<slug>.md ← write this first
workplans/IHUB-WP-NNNN-<slug>.md ← write this first
```
Then register in the hub:
```
@@ -28,7 +28,7 @@ create_task(workstream_id="<id>", title="...", priority="high|medium|low")
**Step 5 — Record the setup**
```
add_progress_event(
summary="First session: structured custodian into N workstreams, M tasks",
summary="First session: structured infotech into N workstreams, M tasks",
event_type="milestone",
topic_id="cee7bedf-2b48-46ef-8601-006474f2ad7a",
detail={"workstreams": [...], "tasks_created": M}

View File

@@ -1,5 +1,5 @@
**Purpose:** Governed, observable interaction substrate for hub-based AI-enabled software systems (IHF specification and reference implementation).
**Domain:** custodian
**Domain:** infotech
**Repo slug:** inter-hub
**Topic ID:** cee7bedf-2b48-46ef-8601-006474f2ad7a

View File

@@ -1,6 +1,7 @@
## Session Protocol
State Hub: http://127.0.0.1:8000
Dev Hub (State Hub API): http://127.0.0.1:8000
MCP server name in `~/.claude.json`: `dev-hub`
**Step 1 — Orient**
@@ -10,7 +11,7 @@ cat .custodian-brief.md
```
Then call the MCP tool for richer cross-domain context when MCP tools are exposed:
```
get_domain_summary("custodian")
get_domain_summary("infotech")
```
If MCP tools are unavailable in the current agent session, use the REST API:
```bash
@@ -39,11 +40,11 @@ curl -s -X PATCH "http://127.0.0.1:8000/messages/<id>/read" \
ls workplans/
```
For each file with `status: ready`, `active`, or `blocked`, note pending
`todo`/`in_progress` tasks.
`wait`/`todo`/`progress` tasks.
**Step 4 — Present brief**
1. **Active workstreams** for `custodian` — title, task counts, blocking decisions
1. **Active workstreams** for `infotech` — title, task counts, blocking decisions
2. **Pending tasks** from `workplans/` + any `[repo:inter-hub]` hub tasks
3. **Goal guidance** — if `goal_guidance` in summary:
- `needs_workplan`: surface as top action — *"Repo goal '{title}' has no workplan yet"*

View File

@@ -1,7 +1,7 @@
## Workplan Convention (ADR-001)
File location: `workplans/inter-hub-WP-NNNN-<slug>.md`
ID prefix: `INTER-WP`
File location: `workplans/IHUB-WP-NNNN-<slug>.md`
ID prefix: `IHUB-WP-`
Work items originate as files in this repo **before** being registered in the hub.
@@ -12,7 +12,7 @@ repo state, and `finished` when implementation is complete. `stalled` and
`needs_review` are derived health labels, not stored statuses.
Closed workplans may be moved to `workplans/archived/` with a completion-date
prefix: `YYMMDD-inter-hub-WP-NNNN-<slug>.md`. The frontmatter id remains
prefix: `YYMMDD-IHUB-WP-NNNN-<slug>.md`. The frontmatter id remains
unchanged; the prefix is only for quick visual reference.
Small opportunistic tasks discovered during another session use **Ad Hoc Tasks**:
@@ -25,4 +25,16 @@ Ecosystem todos from other agents arrive as `[repo:inter-hub]` hub tasks —
visible at session start. Pick one up by creating the workplan file, then registering
the workstream.
Task blocks use this shape:
```task
id: IHUB-WP-NNNN-T01
status: wait | todo | progress | done | cancel
priority: high | medium | low
state_hub_task_id: "<uuid>" # written by fix-consistency — do not edit
```
Status progression is `todo``progress``done`; use `wait` for waiting or
blocked work and `cancel` for stopped work.
<!-- Ralph Loop rules and HEUREKA sequence: ~/.claude/CLAUDE.md — do not duplicate here -->

View File

@@ -4,10 +4,10 @@
**Purpose:** Governed, observable interaction substrate for hub-based AI-enabled software systems (IHF specification and reference implementation).
**Domain:** custodian
**Domain:** infotech
**Repo slug:** inter-hub
**Topic ID:** `cee7bedf-2b48-46ef-8601-006474f2ad7a`
**Workplan prefix:** `INTER-WP-`
**Workplan prefix:** `IHUB-WP-`
---
@@ -63,8 +63,8 @@ Omit `workstream_id` / `task_id` when not applicable.
```bash
curl -s -X PATCH "http://127.0.0.1:8000/tasks/<task_id>" \
-H "Content-Type: application/json" \
-d '{"status": "in_progress"}'
# values: todo | in_progress | done | blocked
-d '{"status": "progress"}'
# values: wait | todo | progress | done | cancel
```
### Flag a task for human review
@@ -83,7 +83,7 @@ curl -s -X PATCH "http://127.0.0.1:8000/tasks/<task_id>" \
1. `cat .custodian-brief.md` — domain goal and open workstreams (offline-safe)
2. Check inbox: `GET /messages/?to_agent=inter-hub&unread_only=true`; mark read
3. Scan workplans: `ls workplans/` — note `status: ready`, `active`, or `blocked` files and open tasks
4. Check blocked tasks: `GET /tasks/?needs_human=true`
4. Check human-needed tasks: `GET /tasks/?needs_human=true`
**During work:**
- Update task statuses in workplan files as tasks progress
@@ -151,6 +151,11 @@ every repo's agent instructions because it is high-frequency, high-risk, and eas
get wrong.
**Canon:** `~/ops-warden/wiki/CredentialRouting.md` · catalog `~/ops-warden/registry/routing/catalog.yaml`
<!-- REPO-AGENTS-EXTENSIONS -->
<!-- Append repo-specific agent instructions below this marker.
The state-hub template sync preserves content after this line. -->
---
## Workplan Convention (ADR-001)
@@ -176,7 +181,7 @@ anything needing analysis, design, approval, dependencies, or multiple phases.
id: INTER-WP-NNNN
type: workplan
title: "..."
domain: custodian
domain: infotech
repo: inter-hub
status: proposed | ready | active | blocked | backlog | finished | archived
owner: codex
@@ -198,7 +203,7 @@ derived health labels, not frontmatter statuses.
` ` `task
id: INTER-WP-NNNN-T01
status: todo | in_progress | done | blocked
status: wait | todo | progress | done | cancel
priority: high | medium | low
state_hub_task_id: "<uuid>" # written by fix-consistency — do not edit
` ` `
@@ -206,7 +211,7 @@ state_hub_task_id: "<uuid>" # written by fix-consistency — do not edit
Task description text.
```
Status progression: `todo` → `in_progress` → `done` (or `blocked`)
Status progression: `todo` → `progress` → `done`; use `wait` for waiting/blocked work and `cancel` for stopped work.
To create a new workplan:
1. Write the file following the format above

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0001
type: workplan
title: "IHF Phase 1 — Minimal Interaction Core"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0002
type: workplan
title: "IHF Phase 2 — Structured Feedback and Triage"
domain: custodian
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0003
type: workplan
title: "IHF Phase 3 — Governance and Decision Linkage"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0004
type: workplan
title: "IHF Phase 4 — Outcome Observation and Antifragility Loop"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0005
type: workplan
title: "IHF Phase 5 — Agent-Assisted Distillation and Suggestion"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0006
type: workplan
title: "IHF Phase 6 — Cross-Framework UI Adaptation Layer"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0007
type: workplan
title: "IHF Phase 7 — Advanced Observability and Operational Integration"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0008
type: workplan
title: "IHF Phase 8 — Federated Hub Maturity"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0009
type: workplan
title: "IHF GAAF Compliance Foundation — Type Registries, Extension Manifests, and Architectural Contracts"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0010
type: workplan
title: "IHF Phase 9 — External API Surface and Consumer SDKs"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0011
type: workplan
title: "IHF Phase 10 — Hub Registry and Widget Marketplace"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0012
type: workplan
title: "IHF Phase 11 — Advanced AI Federation"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0013
type: workplan
title: "IHF Phase 12 — Platform Memory and Continuous Learning"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0014
type: workplan
title: "Pre-flight: Close Deployment Gaps"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0015
type: workplan
title: "Local Deployment — Intro and Tutorial Web UI"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian
@@ -11,8 +11,7 @@ created: "2026-04-03"
updated: "2026-04-03"
state_hub_sync: done
state_hub_workstream_id: "946d50b8-441c-4c0a-b1a0-2a4fb3340d16"
depends_on: IHUB-WP-0014
---
depends_on: IHUB-WP-0014---
# IHUB-WP-0015 — Local Deployment: Intro and Tutorial Web UI

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0016
type: workplan
title: "Build Infrastructure: Incremental Compilation and Autonomous Error-Fix Loop"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0017
type: workplan
title: "Autonomous Error-Fix Loop: Reach Clean Build"
domain: inter_hub
domain: infotech
repo: inter-hub
status: done
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0018
type: workplan
title: "Railiance01 Deployment — Production Operations Scaffold"
domain: inter_hub
domain: infotech
repo: inter-hub
status: finished
owner: custodian

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0019
type: workplan
title: "VSM Hub Bootstrap API Hardening"
domain: inter_hub
domain: infotech
repo: inter-hub
status: finished
owner: codex

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0020
type: workplan
title: "Personal Dashboard Framework"
domain: inter_hub
domain: infotech
repo: inter-hub
status: finished
owner: tegwick

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0021
type: workplan
title: "Personal Dashboard Implementation"
domain: inter_hub
domain: infotech
repo: inter-hub
status: ready
owner: codex

View File

@@ -2,7 +2,7 @@
id: IHUB-WP-0022
type: workplan
title: "Ops Hub Evidence Intake for Activity Core"
domain: inter_hub
domain: infotech
repo: inter-hub
status: active
owner: codex