Phase 4: Emit Council Checkpoint (auto)
Purpose. When this skill runs inside an Aura Companion Council pair, this phase tells the observer half "the orchestrator just finished implementing — here is the file list, please review the implementation." The observer wakes within ~1 second of the checkpoint POST and emits its review to <workspace>/.council/reviews/council-implement-<provider>-observer.md. Without this step the council loop never closes — the observer remains in "Awaiting first checkpoint" forever.
Skip this phase entirely if any of these are true:
http://localhost:3456/api/sessionsdoes not respond (you are not inside the Aura Companion UI).- No session in the response matches the current workspace + orchestrator role.
- The
POST .../council/checkpointreturns 409 — that response IS the silent-skip signal.
Steps
Probe the API. Run
curl -fsS http://localhost:3456/api/sessions. Non-zero exit or empty → skip the entire phase.Discover the orchestrator session id. Filter the response array for the entry matching ALL of:
state == "connected"cwd == <current workspace cwd>(the cwd you implemented under)sessionGroupRole == "orchestrator"- newest
createdAtif more than one match
Zero matches → silent skip. One match → capture
sessionId(=ORCH_SID) andsessionGroupId(=GROUP_ID).Compute next sequence. List
<workspace>/.council/checkpoints/*.json. Read each file'ssequencefield.next_sequence = max(...) + 1, or0if the directory is empty or absent.Build CheckpointPayload.
{ "schema_version": 1, "checkpoint_id": "council-implement-<seq>-<8-hex-random>", "phase": "council-implement", "sequence": <next_sequence>, "session_group_id": "<GROUP_ID>", "emitted_at": "<UTC ISO 8601 T-form, no fractional seconds>", "artifact_paths": [<workspace-relative paths to every file in the "Ready for Review" list of the implementation log>] }artifact_pathsis the list of modified/created files from the implementation log's "Ready for Review" section — these are exactly the files the observer needs to read to review the implementation. Cap at 50 paths (schema limitMAX_ARTIFACT_PATHS); if you exceeded that count, list the top-50 most-changed and add a NOTE to the log that observer cannot see the rest this cycle.POST. Use the Bash tool:
curl -fsS -X POST \ "http://localhost:3456/api/sessions/$ORCH_SID/council/checkpoint" \ -H "Content-Type: application/json" \ -d "$PAYLOAD"Expected 200 with
{"ok": true, "written": "...", ...}.On non-200:
- 409 ("Session is not part of an active council group"): silent skip, not an error.
- 400 / 403 / 500: surface the raw response body to the user, do not retry.
Do not wait for the observer's review. The 200 response IS the success signal for this phase; the observer's review lands asynchronously in the Aura UI's ObserverPanel.