feat(hooks): H1 recommendation-discipline reminder (recommendation-gate D6) - #117
Merged
Conversation
…ap (D6 → ship H1) Implements the recommendation-gate D6 decision (maintainer, 2026-05-21): ship H1 (turn-start reminder), reject H2 (67% FP rate = cry-wolf, erodes compliance per the #97 finding), defer H10 (verdict-as-tool-call) to a separate research R-phase. H1 = one-line addition to the existing UserPromptSubmit hook (reuse, not a new hook): the session-bootstrap digest now injects a recommendation-discipline checklist before each turn. It is a context reminder, NOT structural enforcement — honest about being instruction-compliance-dependent (0% FP, 0 build cost, no theatre claim). Evidence base: recommendation-gate-iterative round-3 dry-run + round-5 §5.1 (branch research/recommendation-gate-iterative). Prior-art: skipped — reuses existing hook (SSOT #20, Claude Code hooks API, ADOPT); no new capability or dependency, single-line context-injection addition.
artyhoo
added a commit
that referenced
this pull request
May 21, 2026
…13.36 to closed Records the maintainer D6 decision (2026-05-21) as §13.39: H1 turn-start reminder shipped (#117), H2 keyword-scanner rejected (67% FP cry-wolf per #97), H10 verdict-as-tool-call deferred to a research R-phase (kickoff scaffolded; ARMED). Cross-refs §13.34 (kept separate per round-5 §5.3). Adding §13.39 pushed open-questions.md over the 500-line pre-commit budget, so the already-RESOLVED §13.36 (TDD-for-Skills → shipped as principle 15 this session) is migrated to closed-questions.md per the append-only archive convention, anchor preserved. Net: open-questions back under budget (496 lines). Prior-art: skipped — tracker entries recording existing decisions + archive migration, no new capability or dependency.
5 tasks
artyhoo
added a commit
that referenced
this pull request
May 21, 2026
…13.36 to closed (#118) Records the maintainer D6 decision (2026-05-21) as §13.39: H1 turn-start reminder shipped (#117), H2 keyword-scanner rejected (67% FP cry-wolf per #97), H10 verdict-as-tool-call deferred to a research R-phase (kickoff scaffolded; ARMED). Cross-refs §13.34 (kept separate per round-5 §5.3). Adding §13.39 pushed open-questions.md over the 500-line pre-commit budget, so the already-RESOLVED §13.36 (TDD-for-Skills → shipped as principle 15 this session) is migrated to closed-questions.md per the append-only archive convention, anchor preserved. Net: open-questions back under budget (496 lines). Prior-art: skipped — tracker entries recording existing decisions + archive migration, no new capability or dependency.
This was referenced May 21, 2026
6 tasks
artyhoo
added a commit
that referenced
this pull request
Jun 14, 2026
#521 Stage P (#526) universalization-fix-s3 Stage P implements the REFERENCE half of the HYBRID verdict (SSOT #117): an opt-in --wire-ci flag (or interactive [y/N], default No) that, when yq is present, idempotently appends the missing rule-enforcement gates (check:globs / arch:check / audit:docs / check:lintstaged) into the consumer's kept .github/workflows/*.yml job, re-detects, and suppresses the WARN on success (merge-then-no-warn). The BUILD half (broadened WARN + paste-block) shipped via #522/#525; the default path stays non-destructive (writes nothing). yq is used-if-present, never installed/pinned by us (companion-install-principle.md §1; BFR §1.1 shipped-axis — integrate, never hard-depend); absent/declined → falls through to the unchanged WARN + paste-block. - install.sh §6c: --wire-ci flag + detect-first yq auto-wire; job/workflow detection via yq; idempotent unique_by(.run) append; bash-3.2-safe array expansion under set -u. Preserves the #525 check:globs shadowed-package Note. - tests/install-sh/s3-wire-ci.test.sh (wired into audit-self.yml): paired-negative — NEG (load-bearing): default install leaves the workflow byte-identical (opt-in proven); POS (yq arm — CI-verified, GH runners ship yq, local prints SKIP): appends all 4, suppresses WARN, idempotent re-run, valid job path; comment-preservation is an OBSERVATION (yq best-effort), not a flaky gate. - prior-art-evaluations.md: SSOT #117 (HYBRID); 11-build-first-reuse-default VERDICTS extended with HYBRID per its line-47 "extend VERDICTS" instruction. Prior-art: prior-art-evaluations.md#117 (HYBRID — REFERENCE mikefarah/yq opt-in --wire-ci auto-wirer + BUILD the zero-dep broadened WARN/paste-block; no new package.json dependency, yq detect-first/never-installed; Stage P of universalization-fix-s3, GH #521).
Merged
4 tasks
artyhoo
added a commit
that referenced
this pull request
Jun 16, 2026
Both docs narrated the pre-#528 buggy dedup key `unique_by(.run)` as final state; the shipped --wire-ci (install.sh:830) uses `unique_by(.run // .uses // .name // .)` per #528 (uses:-only steps have null .run → unique_by(.run) collapsed+deleted them; regression-tested by tests/install-sh/s3-wire-ci.test.sh). Append-only correction notes (not row/summary rewrites) per the prior-art-evaluations.md §3 step-3 convention + the Rename-note precedent; both artifacts stay closed/append-only.
artyhoo
added a commit
that referenced
this pull request
Jun 16, 2026
The note cited install.sh:830 (the line on the old fix/audit-self branch); on the staging-based branch #544 shifted it to :880. Line numbers drift — cite the file + the greppable `unique_by(.run // .uses // .name // .)` expression instead (§1.11 verify-against-source-of-truth).
artyhoo
added a commit
that referenced
this pull request
Jun 16, 2026
…528 doc correction notes (#546) * test(audit-self): real-depcruise ground-truth arm in gh-534 — closes "text present ≠ rule fires" for R3 (GH #534) Arm D installs real dependency-cruiser@16 + typescript@5, plants a packages/*→apps/* import, and asserts depcruise FAILS on no-package-to-app (rc≠0 + rule name). Paired- negative CASE B: legal apps/*→packages/* passes, with a cruised-deps guard against a vacuous 0-module pass. Mirrors gh-535 real-eslint Arm 2; skips gracefully if install fails. The prior config-shape grep + regex arms only proved the rule TEXT/PATTERN ships — never that real depcruise FIRES. Falsification-checked: same import against a rule-less config does NOT trip (load-bearing, not tautology). Pins: @17-latest hard-pins an unpublished acorn-walk (uninstallable) and TS 6 breaks bare-dir scan, so @16 + TS5 is the stable engine. Not a capability commit (test for existing capability; no new dep, no new file ≥80 LOC). * docs: #528 unique_by correction notes (SSOT #117 + univ-fix-s3 done.md) Both docs narrated the pre-#528 buggy dedup key `unique_by(.run)` as final state; the shipped --wire-ci (install.sh:830) uses `unique_by(.run // .uses // .name // .)` per #528 (uses:-only steps have null .run → unique_by(.run) collapsed+deleted them; regression-tested by tests/install-sh/s3-wire-ci.test.sh). Append-only correction notes (not row/summary rewrites) per the prior-art-evaluations.md §3 step-3 convention + the Rename-note precedent; both artifacts stay closed/append-only. * docs: drop drift-prone line ref in #117 correction note The note cited install.sh:830 (the line on the old fix/audit-self branch); on the staging-based branch #544 shifted it to :880. Line numbers drift — cite the file + the greppable `unique_by(.run // .uses // .name // .)` expression instead (§1.11 verify-against-source-of-truth).
5 tasks
artyhoo
added a commit
that referenced
this pull request
Jun 16, 2026
#582) Two CI fixes for the I-phase harvest PR #582: - principle 11 F2: register `ADAPT+generative` in the VERDICTS set (SSOT #115's #552-flip verdict) per the test's own line-47 extend-VERDICTS instruction — same pattern as the HYBRID composite (#117). The base verdict stays ADAPT; the generator is the generative-automation residue. - format:check: run Prettier on `agents/manual-rule-liveness-prober.md` (the aif agent's two-source wiring edit was not Prettier-formatted).
artyhoo
added a commit
that referenced
this pull request
Jun 16, 2026
… isolation (I-phase, #552 Option A) (#582) * feat(scenario-generator): pressure-scenario generator + reject-gate + isolation (I-phase, #552 Option A) Pilot generator for Track 2 of #552 (maintainer flipped to Option A 2026-06-16). Input = rule policy text; output = a VALIDATED pressure-scenario. - §6.3 reject-gate: static-gate.ts + mandatory Pass-1 RED validation; refuses to emit on a non-failing baseline - isolation (R-phase §5.6 / W2): subprocess from /tmp, fresh process, no ambient rule auto-load; T-PSG-A verbatim contamination proof in isolation.md §3 + CWD-inside-repo abort guard - §6.1 on-demand CLI; §6.2 store to .ai-factory/generated-scenarios.json; prober wired two-source (generated first, manifest fallback) - SSOT #115 verdict upgraded to ADAPT+generative Autonomous aif build (task 61c6c7a0), harvested selectively — out-of-scope worktree changes (another umbrella's kickoff, package-lock churn, worktree junk) excluded. Prior-art: prior-art-evaluations.md#115 (ADAPT+generative — the generator is the dispatchable automation residue of SSOT #115; the R-phase BFR sweep confirmed no upstream tool generates+validates pressure-scenarios, so BUILD of the automation residue is warranted). * fix(ci): register ADAPT+generative verdict + Prettier-clean the prober (#582) Two CI fixes for the I-phase harvest PR #582: - principle 11 F2: register `ADAPT+generative` in the VERDICTS set (SSOT #115's #552-flip verdict) per the test's own line-47 extend-VERDICTS instruction — same pattern as the HYBRID composite (#117). The base verdict stays ADAPT; the generator is the generative-automation residue. - format:check: run Prettier on `agents/manual-rule-liveness-prober.md` (the aif agent's two-source wiring edit was not Prettier-formatted).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Что сделано
Реализует решение D6 (recommendation-gate §5, maintainer 2026-05-21):
inject-session-bootstrap.shdigest). Контекст-reminder, НЕ enforcement (честно: 0% FP, 0 build, без theatre-претензии).Переиспользует существующий хук, не плодит новый (BFR; SSOT #20 hooks API).
Как проверить
bash inject-session-bootstrap.sh | grep -c 'Recommendation discipline (H1)'→ 1, exit 0bash -nOKНе §1.7-bearing:
.claude/hooks/вне discipline-self-check path-фильтра. Не capability commit (1-строчное context-injection в существующий хук). Decision-источник: research/recommendation-gate-iterative round-5 §5.1.