feat(okf): enforce §3 okf_version shape, bump convention 0.1 -> 0.2
The 2026-07-23 reservation said enforcement waits until "the emitters have
migrated". Measured rather than assumed, and the emitter set turned out to be
TWO, not three:
okr @0059da7 okf_version: 0.1 + okf_layout: kb-layout-2026-06. Migrated.
linkedin-studio scaffold.ts:38 -> okf_version: 0.1. Never carried a layout
string; has no okf_layout and needs none.
ms-ai-architect NOT an emitter. Zero index.md in the repo; okf_version
appears in one planning doc. The status table already said
"designed, not built" -- only the word "emitters" implied it.
Swept the whole marketplace plus the sibling consumer repos: every live
okf_version value is 0.1. The flip is a no-op today and locks the invariant.
The gate checks SHAPE (/^\d+(\.\d+)*$/), never membership: the upstream value
set is Google's (spec §12), so a bundle targeting a newer version passes. A
membership check would be the convention claiming a set it says it does not own
-- the over-reach class this round has corrected three times. Presence stays
unenforced (reported, not failed) as a separate §3 MUST.
Convention bumped 0.1 -> 0.2 by this log's own criterion: the set of conforming
bundles changed (the spec explicitly said a layout string "conforms today", and
rollout rule 6 defines conformance as gate output). The §12 per-plugin re-check
is pre-measured as finding zero violations.
Also closes a parity blind spot found while landing this: check-okf-parity
compared the okf_version VALUE, which is identical exactly when two impls
disagree about whether it is acceptable -- a false "agree" on the axis the gate
exists to watch. The signature now carries a boolean shape verdict, with
red-marker-layout as the committed red proof. Its "diverge" expectation encodes
okr's lag (they still pure-echo) and flips to "agree" when they mirror it.
And a correction the round earned: portfolio-optimiser enumerated their own
bundle surface and it is four, not three. The dormant fourth
(reference_domain.py:49 -> package data at :70) has no flag form at all, so our
published claim that the re-measurement surfaced "one" unreported entry was
itself one-of-two. Sharpens the standing rule: a search shaped like one entry
type cannot see another; install-vs-fixture is one instance, not the class.
Suite 73 -> 78. coord: PO replied, okr + llm-ingestion-okf notified (the latter
under the standing promise to flag any okf-check.mjs change).
This commit is contained in:
parent
3dad1f51ce
commit
6a72b26985
9 changed files with 227 additions and 11 deletions
|
|
@ -324,6 +324,79 @@ protocol; 🟢 is reserved for the independent gate-verified step (operator veri
|
|||
the narrower one the grep actually proved — **no installation root anywhere in either `src/`**.
|
||||
Standing rule for the next round: ask for the enumeration, not the null result — a search shaped
|
||||
like an install path cannot see a fixture path. _(catalog session, on p-o-claude's correction.)_
|
||||
- **2026-07-25** — **The enumeration above was itself incomplete: two entries were unreported, not
|
||||
one.** portfolio-optimiser answered our published finding by enumerating their own surface, and the
|
||||
count is **four** (verified here against their tree @`9e149c6`, every site re-read):
|
||||
`run.py:679` (`--bundle-dir`, `default=None`), `run.py:249` (library param `run_project(bundle_dir=)`,
|
||||
default `None`), `simulation.py:48` `_default_bundle_dir()` (the fixture default we found), and
|
||||
**`reference_domain.py:49` `Project.bundle_dir`** — a per-project path in the packaged reference
|
||||
portfolio, threaded to `run_project` at `run.py:644` and resolved against **package data**
|
||||
(`reference_domain.py:70`, `files("portfolio_optimiser").joinpath(f"data/{rel}")`). The shipped
|
||||
`reference_projects.json` sets only `docs_dir`, so it is **dormant**: a capability with no value
|
||||
today, and the day it gets one it points into Python package data.
|
||||
- **What this corrects here:** the entry above says our re-measurement "surfaces **one** neither
|
||||
side had reported". It surfaced one **of two**. The claim implied a completeness the enumeration
|
||||
did not have — the same shape of over-reach as the null-result inference it was correcting.
|
||||
- **Why the dormant one is the interesting miss:** it has no flag form at all. It is a key in
|
||||
packaged JSON, so no search shaped like a CLI entry point — ours or theirs — could ever have seen
|
||||
it. That sharpens the standing rule: *a search shaped like one entry type cannot see another*, of
|
||||
which "an install-shaped search cannot see a fixture path" is one instance, not the general case.
|
||||
- **Classification unchanged, and re-verified against their anchors:** `shared_root.py:15`
|
||||
`ENV_VAR = "PORTFOLIO_SHARED_ROOT"`, `:17` `_DEFAULT = Path(__file__).resolve().parents[2]/"shared"`
|
||||
— default *and* override both point at a checked-out spec subtree, never a home directory. The
|
||||
env var exists so `shared/` can be extracted to its own repo without code change; re-pointing it
|
||||
re-points to another spec tree. `expanduser|Path.home|\.claude/` over `src/` still gives **0
|
||||
hits** @`9e149c6`. **One installation against three non-installations stands.** Their own
|
||||
sharper wording, adopted: not "caller-supplied with no default" but **no *installation* default** —
|
||||
a fixture default in the simulation entry, a dormant package-data path in the reference portfolio.
|
||||
_(catalog session, on portfolio-optimiser's unprompted enumeration.)_
|
||||
- **2026-07-25** — **STEG 4 completed: §3 `okf_version` is now ENFORCED on shape; convention version
|
||||
0.1 → 0.2.** The reservation added on 2026-07-23 ("enforcement waits until the emitters have
|
||||
migrated") had its condition measured, not assumed. **The emitter set is two, not three:**
|
||||
- **okr** @`0059da7` (v1.8.1) — migrated. `okf-index.mjs` emits `okf_version: 0.1` +
|
||||
`okf_layout: kb-layout-2026-06`, with a verbatim migration path for legacy roots.
|
||||
- **linkedin-studio** — `scripts/brain/src/scaffold.ts:38` emits `okf_version: 0.1`. It never
|
||||
carried a layout string, and has no `okf_layout` (0 hits) because it needs none.
|
||||
- **ms-ai-architect is not an emitter at all** — **zero `index.md` in the repo**; `okf_version`
|
||||
occurs in exactly one planning document. This log's own status table already said so (🔵
|
||||
"designed, not built"), but the reservation's phrase "the emitters" had been read as including
|
||||
it. Nothing to migrate, so it cannot gate enforcement.
|
||||
|
||||
Swept wider than the two named: every `okf_version` value across the marketplace **and** the
|
||||
sibling consumer repos is `0.1`. The only `kb-layout-2026-06` occurrences are okr's own
|
||||
migration-test inputs and prose in these docs. **No live emitter anywhere carries a layout
|
||||
string**, so the flip is a no-op against today's ecosystem and locks the invariant going forward.
|
||||
|
||||
**What the gate does and deliberately does not do.** `okf-check.mjs` rejects a value that is not
|
||||
version-shaped (`/^\d+(\.\d+)*$/`). It asserts **nothing about which upstream versions exist** —
|
||||
that value set is Google's (§12), so a bundle targeting a newer upstream version passes. This
|
||||
matters: a checker that validated *membership* would be the convention claiming ownership of a set
|
||||
§12 says it does not own — the same over-reach class this round corrected three times. **Presence
|
||||
stays unenforced** (absent → reported, not failed); that is a separate §3 MUST and a separate step.
|
||||
|
||||
**Convention version bumped 0.1 → 0.2**, by this log's own stated criterion. The 2026-07-23 entry
|
||||
declined a bump because "the set of conforming bundles is unchanged (a clarification, deliberately
|
||||
non-enforcing)". Here the set **does** change: the spec explicitly declared that an emitter
|
||||
carrying a layout string "conforms today", and rollout rule 6 defines conformance as gate output
|
||||
("verified, not asserted"). Per §12 the bump triggers a per-plugin re-check — which the sweep above
|
||||
has already pre-measured as finding **zero** violations. Side benefit: the convention version is no
|
||||
longer numerically confusable with upstream OKF v0.1.
|
||||
|
||||
**The parity gate was blind to this axis, and that is now fixed.** `check-okf-parity.mjs` compared
|
||||
the normalized tuple `{conceptCount, untyped, okfVersion}` — the `okf_version` **value**. But when
|
||||
two checkers disagree about whether a value is *acceptable*, the value is identical, so the axis
|
||||
read **agree**. A false green on exactly the drift the gate exists to catch. The signature now
|
||||
carries a boolean shape **verdict** (`okfVersionAccepted`), normalized as a verdict rather than a
|
||||
message so two enforcing impls agree even if they word rejection differently. New corpus fixture
|
||||
**`red-marker-layout`** (`expected: "diverge"`) is the red proof, and the CLI now prints
|
||||
`(accepted)`/`(REJECTED)` because on this axis both impls print the same `okf=` value.
|
||||
|
||||
**Known, deliberate divergence:** catalog now enforces; okr still pure-echoes (their `CHANGELOG.md`
|
||||
for 1.8.1: "verdiene valideres fortsatt ikke, siden spec §3 ennå ikke er håndhevende på form" — a
|
||||
statement that was true when written and is now stale). The `diverge` expectation **encodes okr's
|
||||
lag, not a design split**, and flips to `agree` when they mirror it. okr notified; the standing
|
||||
promise to notify llm-ingestion-okf on any `okf-check.mjs` change was honoured in the same round.
|
||||
Suite **73 → 78** across the six test files. _(catalog session.)_
|
||||
|
||||
## Distilled architecture notes (OKF round, 2026-07)
|
||||
|
||||
|
|
|
|||
|
|
@ -4,7 +4,10 @@ A cross-plugin convention for how each plugin stores the **user's own context**
|
|||
personal/organizational "second brain" / LLM-wiki — as a portable, interoperable markdown
|
||||
bundle, compatible with Google's Open Knowledge Format (OKF) v0.1.
|
||||
|
||||
> **Version 0.1 · 2026-06-29 · Cross-cutting catalog artifact, owned by no single plugin.**
|
||||
> **Version 0.2 · 2026-07-25 · Cross-cutting catalog artifact, owned by no single plugin.**
|
||||
> _(0.2 tightens the §3 floor: `okf_version` is now enforced on shape. Distinct from — and
|
||||
> deliberately no longer numerically confusable with — upstream Google OKF v0.1, which this
|
||||
> convention targets and does not version.)_
|
||||
> Reference design: linkedin-studio's `brain/`. Interop layer: Google OKF v0.1 (thin veneer).
|
||||
> Change log + per-plugin rollout status + coordination protocol: `log.md` (same directory).
|
||||
|
||||
|
|
@ -52,9 +55,12 @@ file path minus `.md`.
|
|||
children — **never a filesystem read**; **no frontmatter**, carries progressive-disclosure prose).
|
||||
- **MUST** — the bundle-root `index.md` carries an `okf_version` marker (the upstream OKF version the
|
||||
bundle targets, currently `0.1`). The value is the **upstream version alone**; a plugin's own layout
|
||||
revision belongs in the optional `okf_layout` marker (§12), never here. **Not yet enforced** — no
|
||||
checker validates the value's shape, so an emitter still carrying a layout string here conforms
|
||||
today. Enforcement waits until the emitters have migrated (`log.md`, STEG 4).
|
||||
revision belongs in the optional `okf_layout` marker (§12), never here. **Enforced on shape** — the
|
||||
gate rejects a value that is not version-shaped (`/^\d+(\.\d+)*$/`), which is what catches a layout
|
||||
snapshot sitting in this field. The check deliberately asserts **nothing about which upstream
|
||||
versions exist**: that value set is Google's (§12), so a bundle targeting a newer upstream version
|
||||
passes. **Presence is not enforced** — an absent marker is reported, not failed; that is a separate
|
||||
step, not this one.
|
||||
- **MUST (consumers)** — preserve unknown frontmatter keys, tolerate unknown `type` values, tolerate
|
||||
broken cross-links.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue