sync: auto-sync from GURU-5070 at 2026-06-08 07:55:26
Author: Mike Swanson Machine: GURU-5070 Timestamp: 2026-06-08 07:55:26
This commit is contained in:
@@ -68,25 +68,26 @@ When in doubt, include MORE detail — future sessions search these logs to reco
|
||||
|
||||
---
|
||||
|
||||
## Phase 3 — Wiki Compile (before sync)
|
||||
## Phase 3 — Wiki: DECOUPLED (do NOT recompile inline)
|
||||
|
||||
Fold what you just worked on into the wiki article so it ships in the **same commit** as the session log. This runs before sync and **re-synthesizes** the article (via a **Sonnet subagent** — `model: "sonnet"`, not Ollama), so new findings/patterns actually land — not just dynamic fields.
|
||||
Wiki synthesis is **decoupled from `/save`** (harness v1.2.0+, Task 2). Running a full
|
||||
Sonnet recompile inline on every save, on every machine, caused concurrent-recompile
|
||||
rebase conflicts — and once committed unresolved conflict markers into a wiki article.
|
||||
So **`/save` no longer touches the wiki**: it writes the session log and syncs, nothing
|
||||
more. Do NOT recompile the wiki here, and never block/delay the sync on wiki work.
|
||||
|
||||
1. Derive the slug from the session-log path written in Phase 2:
|
||||
- `clients/<slug>/session-logs/...` → client `<slug>`
|
||||
- `projects/<project>/session-logs/...` → project article slug (e.g. `guru-rmm`, `guru-connect`)
|
||||
- Root `session-logs/...` → **skip this phase entirely** (no single article is implied)
|
||||
To refresh the wiki for this session's work, run `/wiki-compile` **separately** — it is
|
||||
now **serialized** (per-article coord lock) and **staged** (writes a proposed update to
|
||||
`.claude/wiki_staging/` for review before it touches the live article).
|
||||
|
||||
2. Run the `/wiki-compile` generation for that target, writing the article + updating `wiki/index.md`, but **stop before its commit/push step** — `sync.sh` (Phase 4) commits everything together in one commit:
|
||||
- **Article exists** → **full recompile** (`/wiki-compile <type>:<slug> --full`): the Sonnet subagent re-synthesizes, **preserving Patterns and History verbatim** (unless the new session log shows an item resolved) and refreshing everything else, absorbing this session's work. Clients also refresh live Syncro fields (hours, tickets).
|
||||
- **No article yet** → **seed** (full synthesis) to create it.
|
||||
- The main agent reviews the subagent's draft before writing — verify IPs/paths; never invent vault paths (use `(verify)`); keep billing fields Syncro-authoritative.
|
||||
After the sync completes, derive the slug from the session-log path (Phase 2) and emit
|
||||
the exact command for the operator to run when ready:
|
||||
- `clients/<slug>/session-logs/...` → `[INFO] Wiki decoupled — run: /wiki-compile client:<slug> --full (serialized + staged)`
|
||||
- `projects/<project>/session-logs/...` → `[INFO] Wiki decoupled — run: /wiki-compile project:<slug> --full (serialized + staged)`
|
||||
- Root `session-logs/...` → no single article implied; emit nothing.
|
||||
|
||||
3. **Softfail (critical) — a wiki failure must NEVER block the save:**
|
||||
- If the synthesis subagent fails or is unavailable, fall back to a surgical **refresh** (bump `last_compiled` + `sources`; refresh client Syncro fields) so the article still records the session, and emit `[WARN] wiki refreshed, not recompiled; run /wiki-compile --full later`.
|
||||
- Any other failure: log it and continue to sync.
|
||||
|
||||
The article + `wiki/index.md` are committed alongside the session log by `sync.sh` (Phase 4).
|
||||
The session log + `sync.sh` are the durable record; the wiki is refreshed deliberately,
|
||||
not on every save.
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user