C6. `docs/consumption-contract.md` now says what the pre-pass emits:
- SS 2.5 point 2: sub-questions are written in the bundle's terms and given to
the pre-pass in ONE run where it takes several;
- SS 8's example is `okf-consumption/2` as shipped: `withheld` is the
`{total, by_rule, nearest, complete}` mapping, `coverage` carries
`absent_terms` and `weak`, an excerpt carries `text`, `text_sha256`,
`passage` and `own_title`; point 1 closes the identity on `withheld.total`;
- point 7 keeps the falsified verdicts on record and states the one reading
carried since v1.1, `weak`, with its rule: a word held in no form, or
nothing delivered -- whether a word exists at all, which does not move with
question style or corpus size the way the two shares did;
- point 8 the passage (`{start, end, of}`, `text_sha256` over the passage,
`sha256` still the file's), point 9 several sub-questions in one run (one
cut, `questions`, `subquestions`, per-sub-question coverage), point 10 a
title inherited from the heading above, with `own_title`;
- SS 10 names this library's default ranking (BM25) and `--ranking fusion`.
`okf check` holds the two new forms a reader acts on: `passage_malformed`
(not whole numbers with 0 <= start < end <= of) and `subquestions_unindexed`
(not distinct indices into `questions`, or indices in a payload listing none).
17 -> 19 rules; the two tests that pin the published count move with it.
Each rule is held against a real payload (0 findings) and against that
payload broken six ways.
Editing the contract moved the SS 7.4 known-positive, measured once after the
edit: 19 837 -> 23 672 encoded, 19 358 -> 23 092 raw, delta 479 -> 580. The
example payload and `skills/okf-consume` are regenerated by the published
recipe and `okf check` reports 19 rules, 0 findings on them.
Suite on a clean tree after `git add`: 2443 passed, 2 skipped, 4 xfailed.
ruff, ruff format, mypy --strict clean.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
126 lines
3.8 KiB
JSON
126 lines
3.8 KiB
JSON
{
|
|
"contract": "okf-consumption/2",
|
|
"bundle": {
|
|
"bundle_id": "b-golden-segmented-okf-v0-2",
|
|
"ref": "sha256-tree:cce7a02c769793cdb6e3afda45c955461b57373deab13a986d8bf7843d6e436f"
|
|
},
|
|
"budget": {
|
|
"unit": "utf-8 bytes of emitted JSON",
|
|
"instrument": "okf_consume.measure (len of the ensure_ascii=False JSON encoding, utf-8)",
|
|
"limit": 120000,
|
|
"spent": 2289,
|
|
"known_positive": {
|
|
"case": "docs/consumption-contract.md, encoded as a JSON string",
|
|
"expected": 23672,
|
|
"measured": 23672,
|
|
"raw_bytes": 23092,
|
|
"encoding_delta": 580
|
|
}
|
|
},
|
|
"denominators": {
|
|
"considered": 3,
|
|
"withheld": 0,
|
|
"delivered": 3
|
|
},
|
|
"question": "Hva sier veiledningen om krav?",
|
|
"coverage": {
|
|
"question_terms": [
|
|
"hva",
|
|
"sier",
|
|
"veiledningen",
|
|
"krav"
|
|
],
|
|
"unanswered_in_bundle": [
|
|
"hva",
|
|
"sier"
|
|
],
|
|
"unanswered_in_payload": [
|
|
"hva",
|
|
"sier"
|
|
],
|
|
"absent_terms": [],
|
|
"weak": false
|
|
},
|
|
"excerpts": [
|
|
{
|
|
"bundle_id": "b-golden-segmented-okf-v0-2",
|
|
"concept_id": "veiledning",
|
|
"sha256": "8f1f4d940887b96b39496d0aceb7a4fa212553510165917427e4f7e9efb98b03",
|
|
"adjudication": "proposed",
|
|
"trust_tier": "unverified",
|
|
"bundle_id_inherited": false,
|
|
"title": "Veiledning for eksempelbundel",
|
|
"sources": [
|
|
{
|
|
"resource": "veiledning.md",
|
|
"title": "veiledning.md"
|
|
}
|
|
],
|
|
"source_file": "veiledning.md",
|
|
"source_sha256": "6906ec0acbcfc246e825bda9863c716eb5611b465020e8204eeb448c32343f7d",
|
|
"source_lines": "[1, 4]",
|
|
"source_offset": "[0, 94]",
|
|
"text_sha256": "82d67ff01367a1a56532130e077956048004ac047e6062eae2143d96704c4a92",
|
|
"text": "\n# Veiledning for eksempelbundel\n\nDenne teksten er syntetisk og finnes kun for a pinne bytes.",
|
|
"rank": 1
|
|
},
|
|
{
|
|
"bundle_id": "b-golden-segmented-okf-v0-2",
|
|
"concept_id": "krav/1-1/foerste-krav",
|
|
"sha256": "84145512284a8bbc1a8905c73d0de3f0e0cb7081cf517f778fe88a610d2b4f62",
|
|
"adjudication": "proposed",
|
|
"trust_tier": "unverified",
|
|
"bundle_id_inherited": false,
|
|
"title": "Foerste krav",
|
|
"sources": [
|
|
{
|
|
"resource": "veiledning.md",
|
|
"title": "veiledning.md"
|
|
}
|
|
],
|
|
"source_file": "veiledning.md",
|
|
"source_sha256": "6906ec0acbcfc246e825bda9863c716eb5611b465020e8204eeb448c32343f7d",
|
|
"source_lines": "[5, 8]",
|
|
"source_offset": "[94, 176]",
|
|
"parent": {
|
|
"concept_id": "veiledning",
|
|
"title": "Veiledning for eksempelbundel"
|
|
},
|
|
"text_sha256": "08447c690087834883a78fb9f40d474c68b2526ed57d0dafe01c4868db3c04f0",
|
|
"text": "\n## 1.1 Foerste krav\n\nEt krav som beskriver den foerste betingelsen i eksempelet.",
|
|
"rank": 2
|
|
},
|
|
{
|
|
"bundle_id": "b-golden-segmented-okf-v0-2",
|
|
"concept_id": "krav/1-2/andre-krav",
|
|
"sha256": "4f8a869aa4e898ec1a30595951b3e198e09091d76c41078a52e821000eb9e22c",
|
|
"adjudication": "proposed",
|
|
"trust_tier": "unverified",
|
|
"bundle_id_inherited": false,
|
|
"title": "Andre krav",
|
|
"sources": [
|
|
{
|
|
"resource": "veiledning.md",
|
|
"title": "veiledning.md"
|
|
}
|
|
],
|
|
"source_file": "veiledning.md",
|
|
"source_sha256": "6906ec0acbcfc246e825bda9863c716eb5611b465020e8204eeb448c32343f7d",
|
|
"source_lines": "[9, 11]",
|
|
"source_offset": "[176, 253]",
|
|
"parent": {
|
|
"concept_id": "veiledning",
|
|
"title": "Veiledning for eksempelbundel"
|
|
},
|
|
"text_sha256": "4c181e1debb141d3cb1a7bd47249fdac1c0b2c5db1b47cf255ef8f04f83ec840",
|
|
"text": "\n## 1.2 Andre krav\n\nEt krav som beskriver den andre betingelsen i eksempelet.",
|
|
"rank": 3
|
|
}
|
|
],
|
|
"withheld": {
|
|
"total": 0,
|
|
"by_rule": {},
|
|
"nearest": [],
|
|
"complete": true
|
|
}
|
|
}
|