Skip to content
Closed

. #12

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions agent-plugin/skills/go/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions agent-plugin/skills/go/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
3 changes: 3 additions & 0 deletions agent-plugin/skills/go/references/orchestration.md
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,9 @@ the user's answer — it never silently hangs, fires-and-forgets, or proceeds on
user; they return their escalation through their structured result, and the orchestrator relays it
to the user synchronously.)

When passing a user decision to a later implementer or reviewer, include the question, options
shown, and the user's answer verbatim. A summary of the selection can lose the stated rationale.

**Detection ≠ diagnosis.** Spotting that something broke is not the same as correctly
attributing *why*. A confident but wrong cause-attribution is possible — verify it against the
actual commands and output (not a self-report or a shallow grep) before acting destructively or
Expand Down
8 changes: 5 additions & 3 deletions agent-plugin/skills/migration/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions agent-plugin/skills/migration/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
8 changes: 5 additions & 3 deletions antigravity/skills/go/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions antigravity/skills/go/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
3 changes: 3 additions & 0 deletions antigravity/skills/go/references/orchestration.md
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,9 @@ the user's answer — it never silently hangs, fires-and-forgets, or proceeds on
user; they return their escalation through their structured result, and the orchestrator relays it
to the user synchronously.)

When passing a user decision to a later implementer or reviewer, include the question, options
shown, and the user's answer verbatim. A summary of the selection can lose the stated rationale.

**Detection ≠ diagnosis.** Spotting that something broke is not the same as correctly
attributing *why*. A confident but wrong cause-attribution is possible — verify it against the
actual commands and output (not a self-report or a shallow grep) before acting destructively or
Expand Down
8 changes: 5 additions & 3 deletions antigravity/skills/migration/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions antigravity/skills/migration/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
45 changes: 45 additions & 0 deletions ci/fixtures/decision-record-source-fidelity.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
[
{
"name": "choice_without_reason",
"question": "Which database should we use?",
"options": ["SQLite", "PostgreSQL"],
"answer": "SQLite.",
"other_recorded_reasoning": null,
"expected": "Record SQLite as chosen and PostgreSQL as not chosen, with no reason given. The reviewer accepts the missing rationale as meeting the ADR quality floor.",
"reject": "PostgreSQL was rejected because it is too complex to operate.",
"required_contract": {
"harness-format.md": [
"If the user chose without giving a reason and no source records one, write \"no reason given\" in the user's language",
"this meets the floor",
"Never invent a rationale"
],
"harness-review.md": [
"An unsupported rationale is a blocking hallucination",
"An explicit \"no reason given\" when no source records one meets the ADR quality floor",
"do not treat it as a hollow section or infer a reason"
]
}
},
{
"name": "choice_with_stated_reason",
"question": "Which database should we use?",
"options": ["SQLite", "PostgreSQL"],
"answer": "SQLite, because the deployment must work offline without a separate database service.",
"other_recorded_reasoning": null,
"expected": "Preserve the offline deployment and no separate service rationale. Pass the question, options, and exact answer to the reviewer, who accepts this supported rationale.",
"reject": "Passing only 'The user chose SQLite' and then flagging the recorded offline deployment rationale as invented.",
"required_contract": {
"harness-format.md": [
"rejection reasons supported by the user's words, source material, or recorded design reasoning",
"If the user gave a reason, preserve it faithfully"
],
"harness-review.md": [
"User decisions must reach the reviewer verbatim: the question, options shown, and answer",
"When the user gave a reason, check against their actual words, not a summary of their selection"
],
"orchestration.md": [
"include the question, options shown, and the user's answer verbatim"
]
}
}
]
21 changes: 21 additions & 0 deletions ci/verify.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,26 @@ def validate_licenses(root: Path) -> None:
print(f"OK license copies ({len(copies)})")


def validate_decision_record_source_fidelity(root: Path) -> None:
# Static prompt-contract regressions, not model executions. The paired transcripts and
# expected/rejected behavior in the fixture can also be used for a future behavioral eval.
fixture = root / "ci/fixtures/decision-record-source-fidelity.json"
cases = json.loads(fixture.read_text(encoding="utf-8"))
failures: list[str] = []
for case in cases:
for filename, clauses in case["required_contract"].items():
skills = ("go",) if filename == "orchestration.md" else ("go", "migration")
for skill in skills:
relative = Path("src/skills") / skill / "references" / filename
text = " ".join((root / relative).read_text(encoding="utf-8").split())
for clause in clauses:
if clause not in text:
failures.append(f"{case['name']}: {relative}: missing {clause!r}")
if failures:
raise VerificationError("decision-record source-fidelity contract:\n" + "\n".join(failures))
print(f"OK decision-record source-fidelity contracts ({len(cases)} paired cases; static)")


def verify(root: Path, tag: str | None = None) -> None:
required = [
"CHANGELOG.md",
Expand Down Expand Up @@ -354,6 +374,7 @@ def verify(root: Path, tag: str | None = None) -> None:
validate_antigravity_package(root)
validate_codex_invocation(root)
validate_licenses(root)
validate_decision_record_source_fidelity(root)
validate_reproducible_build(root)


Expand Down
8 changes: 5 additions & 3 deletions claude/skills/go/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions claude/skills/go/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
3 changes: 3 additions & 0 deletions claude/skills/go/references/orchestration.md
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,9 @@ the user's answer — it never silently hangs, fires-and-forgets, or proceeds on
user; they return their escalation through their structured result, and the orchestrator relays it
to the user synchronously.)

When passing a user decision to a later implementer or reviewer, include the question, options
shown, and the user's answer verbatim. A summary of the selection can lose the stated rationale.

**Detection ≠ diagnosis.** Spotting that something broke is not the same as correctly
attributing *why*. A confident but wrong cause-attribution is possible — verify it against the
actual commands and output (not a self-report or a shallow grep) before acting destructively or
Expand Down
8 changes: 5 additions & 3 deletions claude/skills/migration/references/harness-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,13 @@ of information, not a stack or domain — if the project has none of that kind,
an obvious one. Test: "could another team in the same situation have chosen differently?" — if so,
it's a record.
- **Each decision**: context (why the decision was needed); decision (what was chosen); alternatives
(what was not chosen, and concretely why); consequences (the constraints/effects this imposes on
(what was not chosen, and why as recorded); consequences (the constraints/effects this imposes on
future work, including what it made impossible).
- **Quality floor**: context states the concrete situation that forced the decision; alternatives
give specific rejection reasons, not "considered but rejected"; consequences include what is now
impossible.
give specific rejection reasons supported by the user's words, source material, or recorded
design reasoning; consequences include what is now impossible. If the user chose without giving
a reason and no source records one, write "no reason given" in the user's language — this meets
the floor. Never invent a rationale. If the user gave a reason, preserve it faithfully.

### tracking/findings.md — unresolved problems
- **Criterion**: only problems not resolved on the spot. A problem fixed in place is not recorded.
Expand Down
6 changes: 6 additions & 0 deletions claude/skills/migration/references/harness-review.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ that reads as generic boilerplate, restates what code shows, or fills a section

Cross-check the harness against the code, **both directions**:

For decision rationale, also cross-check the user's words, source material, and recorded design
reasoning. User decisions must reach the reviewer verbatim: the question, options shown, and answer.
An unsupported rationale is a blocking hallucination. An explicit "no reason given" when no source
records one meets the ADR quality floor; do not treat it as a hollow section or infer a reason.
When the user gave a reason, check against their actual words, not a summary of their selection.

- **Omission** — an intent / constraint / mechanism that the code **cannot derive on its own** is
missing from the docs. This is the real omission. *Code-derivable facts being absent is not an
omission* — by the non-derivability principle, the harness deliberately omits them.
Expand Down
Loading
Loading