@chrono-meta/fh-gate 1.4.39 → 1.4.40

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chrono-meta/fh-gate",
3
- "version": "1.4.39",
3
+ "version": "1.4.40",
4
4
  "description": "FH runtime adapters — run FH governance, skills, and agents via Claude or Codex with machine-parseable gates.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -88,7 +88,11 @@ All 3 → Proceed in order: Step 0-B (token injection) → Step 0 (environment c
88
88
 
89
89
  **Mode D detected (FH developer/researcher)**: Guide companion-store setup before Step 1. **Ask the backend first** — the store is a role (durable private home for artifacts), not a fixed `*-be` git repo: Obsidian vault / gbrain-ingest / `*-be` git repo (default) all qualify. Do not assume the repo path.
90
90
 
91
- > **Detail**: See `SKILL_detail.md §Mode-D-Companion-Setup` — backend-branching question (Obsidian / gbrain / *-be git default), remote-backed and local-only setup commands, cross-backend invariants read when Mode D is detected.
91
+ **Set the store up as a queryable WIKI, not an empty folder** the store earns its value when the agent can *read it well*, so the scaffold includes: an `INDEX.md` wiki-home (**the `CATALOG.md` read-first pattern applied to the store** named INDEX to avoid two CATALOG.md across the public + private repos; section map + **read-time-derived** pointers, never hand-maintained placeholders that rot) · session-start read wiring the AI **idempotently adds** to `CLAUDE.local.md` (grep-guarded against duplication: read INDEX → open result/signal files newer than the session card, not only handoffs) · the Raw/Wiki/Conversation ingest axis (`sync_push_protocols.md`). The git `*-be` form is the **default within the no-existing-store branch** (it stays an ask-first choice — see the backend question; SKILL.md does not override the detail file's neutral ordering), recommended *there* because for a non-visual user *observability is the agent querying the wiki* (INDEX + session-start read) — git-versioned, agent-native (grep/Read), no cloud egress; FH's answer to its weak Observability layer. Obsidian (graph-view = the visual observability surface) and cloud are equal options when the user already runs one. **Salience caveat**: the session-start read is prose in `CLAUDE.local.md` (no SessionStart hook) — on a weak tier it may silently not fire; accepted, revisit if a target-tier sim measures a miss.
92
+
93
+ **Beyond Mode D (not forced)**: a non-developer user who accumulates their own context into FH and keeps no separate local store benefits too — but since accumulation is unobservable at *first* install, surface this offer only on a **re-run where FH-written artifacts already exist** (e.g. non-empty `tracks/*/session_*.md`), not preemptively at first setup. A user with a local store, or with no FH artifacts, is not prompted.
94
+
95
+ > **Detail**: See `SKILL_detail.md §Mode-D-Companion-Setup` — backend-branching question (Obsidian / gbrain / *-be git default), the queryable-wiki scaffold (INDEX.md + session-start wiring), remote-backed and local-only setup commands, cross-backend invariants — read when Mode D is detected.
92
96
 
93
97
  ### Step 0-B. Git Token Pre-injection (when repo creation/fork/push included)
94
98
 
@@ -61,6 +61,51 @@ Invariant across ALL backends:
61
61
  · handoff/ files bridge cloud session → local without exposing content
62
62
  ```
63
63
 
64
+ **Queryable-wiki scaffold (all backends — the store is a wiki, not a dump):** after BE_DIR is set,
65
+ scaffold so the agent can *read the store well* (this is the recommended form's Observability answer —
66
+ the agent queries the wiki, vs a visual graph). `INDEX.md` here is the **`CATALOG.md` read-first pattern
67
+ applied to the store** (same semantics; named INDEX, not CATALOG, only to avoid two `CATALOG.md` across
68
+ the public mirror + the private store):
69
+
70
+ ```bash
71
+ # 1. INDEX.md — wiki home (read FIRST at session start). The section MAP is static (low rot);
72
+ # the volatile "latest" pointers are DERIVED at read time, never hand-maintained (a stale
73
+ # "latest" mis-routes the very read it exists to guide — worse than none).
74
+ cat > "$BE_DIR/INDEX.md" <<'IDX'
75
+ # <store> — Wiki Home (READ ME FIRST at session start)
76
+ > Read this store AS a wiki (relevance-query the right section), not pull + file-dump.
77
+ ## How to read at session start
78
+ 1. This INDEX first → pick the section for the session intent.
79
+ 2. DERIVE the latest pointers live (do NOT trust a hand-written "latest" line):
80
+ ls -t paper-signals/ handoff/ digests/ 2>/dev/null | head
81
+ then open anything newer than the session card (card=pointer, store commit=truth).
82
+ ## Sections (static map)
83
+ | Section | Holds | Read when |
84
+ |---|---|---|
85
+ | paper-signals/ | completed results + research signals | any measurement (check for a prior result first) |
86
+ | handoff/ | cross-machine/session bridges (entry points, run recipes) | resuming work started elsewhere |
87
+ | digests/ | frontier digests (cadence source) | cadence/frontier scan |
88
+ | (add your sections) | | |
89
+ IDX
90
+
91
+ # 2. session-start read wiring → IDEMPOTENT append to the user's CLAUDE.local.md (grep-guarded
92
+ # so a re-run never duplicates it; this is a REAL write, not a note):
93
+ WIRING="At session start: read \$BE_DIR/INDEX.md first; then ls -t paper-signals/ handoff/ digests/ and open anything newer than the session card (card=pointer, store commit=truth) — not only handoffs."
94
+ grep -qF "read \$BE_DIR/INDEX.md first" "$HUB_DIR/CLAUDE.local.md" 2>/dev/null \
95
+ || printf '\n## Companion-store session-start read\n%s\n' "$WIRING" >> "$HUB_DIR/CLAUDE.local.md"
96
+ ```
97
+
98
+ - **Raw / Wiki / Conversation ingest axis** (`sync_push_protocols.md`): classify each artifact by
99
+ processing stage — Raw (unprocessed capture) → stays raw; Wiki (distilled + `[[linked]]`) → the
100
+ compounding layer; Conversation (dialogue/decision log). The Raw→Wiki distill is where linking earns
101
+ its keep. Mention it so the store accumulates as a wiki, not a heap.
102
+ - **Backend note**: for an **Obsidian** backend the graph view is the *visual* observability surface
103
+ (free for that backend); for the recommended **git `*-be`** form, observability is the agent querying
104
+ INDEX + sections (no visualization needed). gbrain ingests the same markdown.
105
+ - **Salience caveat**: the CLAUDE.local.md session-start read is prose (no SessionStart hook) — on a weak
106
+ tier it may silently not fire. Accepted limitation (mirrors `operational_adaptation.md §Guards`);
107
+ revisit if a target-tier sim measures a miss.
108
+
64
109
 
65
110
  ---
66
111