feat(sdd,agents): SDD-003 spec-gate + AI-019 model-tier policy#60
Merged
Conversation
Bundle of two logically-distinct changes plus a small ghostty config tweak.
User-elected bundle (against atomic-PR ideal) — conscious deviation, not scope creep.
SDD-003 (Tier 4+5 of the SDD enforcement stack)
- scripts/check-spec-gate.sh: LOC threshold (>=50) + spec-folder presence
check, basename-aware lockfile exclusion (npm/pnpm/go), `skip-sdd` label +
rationale escape hatch, dependabot bypass.
- .github/workflows/spec-gate.yml: pull_request trigger, env-var pattern
(no `${{}}` in run: blocks).
- .github/pull_request_template.md: SDD checklist + skip-rationale header.
- .pre-commit-config.yaml + scripts/install-precommit.sh --with-sdd-gate:
opt-in pre-push hook for local pre-flight.
- tests/check-spec-gate.bats: 16 cases. tests/install-precommit.bats: +4 cases.
AI-019 (cross-agent model-tier policy)
- AGENTS.md: new "Model Selection (Task-Aware)" section between Standing
Orders and Competence Retention Protocol. Top / Mid / Low tiers, trigger
heuristics ("propose, don't force"), per-agent overlay pointers.
- ai/claude/CLAUDE.md, ai/gemini/GEMINI.md, ai/copilot/copilot-instructions.md,
ai/opencode/opencode.jsonc: ~6-line Model Tier subsection each with literal
model IDs (Claude empirical; OpenCode empirical; Gemini + Copilot marked TBD
pending validation).
- tests/opencode.bats: CLAUDE.md threshold bumped 70->80 with inline reason.
terminal/ghostty/config: bell-features=no-system, window-vsync=true (user-authored
session tweaks, bundled at user request).
Specs at specs/SDD-003-ci-spec-gate/ and specs/AI-019-model-tier-policy/.
AUDIT-004 architecture map landed separately in the vault via Hive auto-commit.
Tests: bats 645/645 green; shellcheck --severity=error clean; opencode.jsonc
structurally valid (top-level keys + 5 MCP servers intact); JSON workflow valid.
This was referenced May 20, 2026
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.
Summary
Two logically-distinct changes bundled by user decision (against atomic-PR ideal — conscious deviation, not scope creep) plus a small ghostty config tweak the user authored mid-session.
AGENTS.mdwith per-agent overlay pointers carrying the literal model IDs (Top / Mid / Low tiers, "propose-don't-force" trigger heuristics).terminal/ghostty/configgainsbell-features=no-system+window-vsync=true(user-authored).SDD checklist
SDD-003-ci-spec-gate,AI-019-model-tier-policy,AUDIT-004-architecture-map)specs/SDD-003-ci-spec-gate/andspecs/AI-019-model-tier-policy/proposal.mdfilled for both (Why / What / Acceptance criteria / Risks)tasks.mdin TDD order for bothverification.mdfilled for both with evidence + test outputsfeatures.json(SDD-003) tracks 13 features inpendingstate pre-mergeSDD skip rationale
Test plan
bats tests/*.bats→ 645/645 pass (16 new SDD-003 cases + 4 new install-precommit cases)shellcheck --severity=error scripts/*.sh setup-linux.shcleanpython3JSONC validation onai/opencode/opencode.jsonc(top-level keys + 5 MCP servers intact)python3 -c "import yaml; yaml.safe_load(...)"on.github/workflows/spec-gate.ymlcleanspecs/<feature-id>/folders → expected to PASS the spec-gate (case B)Notable decisions
origin/main; pre-commit would falsely fail intermediate WIP commits during red-green-refactor.//comments instead of_modelTierCommentJSON key — the file already uses//extensively; adding the model-tier block as comments is diff-friendly and avoids polluting the parsed JSON namespace.tests/opencode.bats(model-tier addition is intentional cross-agent consistency, not slippage).Out of scope (for future PRs)
verification.md; ADR-010 is the natural sibling)Companion vault artifact
30-architecture/dotfiles-architecture-map.md(AUDIT-004) landed in the vault via Hive auto-commit ahead of this PR. Two Mermaid diagrams (setup-time + runtime data flow) + 23-row "where does X live" reference table — used as baseline for the queued AUDIT-001/002/003.