v0.16 slice 2: gates via Agentic Dev contracts (agentic-dev#66) #2
All Vouch review confidence checks passed
Residual risk 0.21 = Change Risk (0.52) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.52 · 650 lines diff across 8 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.388
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #2"
general
weight: 0.35
szaher
v0.16 slice 2 (szaher/agentic-dev#66; tracking szaher/agentic-dev#33). AgentFlow consumes Agentic Dev's discovery and verification contracts (szaher/agentic-dev#69, merged as
725a7a4). Scope is limited to discovery and gates. Bootstrap blocks, doctor delegation, readiness/capability requirements, and worktree policy belong to later slices. Held for review before merge.Merge bar
detected_commandsand direct gate shell execution are gone.gates.pyhas nosubprocess/run_command. A structural test fails if any AgentFlow module inspectspackage.json,pyproject.toml,go.mod,Cargo.toml,Makefile, orpnpm-lock.yaml, regrowsdetected_commands/commands_for, or importsagentic_dev.config.gates[profile]becomes repeatedagentic verify run --command …arguments. AgentFlow never invokes a shell itself; it passes each command intact as one argument (test_custom_command_is_passed_as_single_agentic_argument). Agentic Dev's host backend then runs it withsh -lc, by design.RunState.run_start_commitcomes fromgit rev-parse --verify HEADin_make_state()before any stage runs, and isNonefor an unborn repo. It's in history. Tests cover a save/load round trip, old state files without the field still loading, and the unborn case.contracts,repo-inspection,verification-run) is validated against the schema the installedagenticships (agentic contracts schema NAME); an invalid response raises and fails closed.jsonschemais now AgentFlow's runtime dependency.install.shcreates a private venv for it, and the README no longer claims there are no runtime dependencies.no-checkswithmissing_kinds, executes nothing, and the gate fails. Agentic Dev'sstatusis authoritative:passedgoes toon_success;failedandno-checksgo toon_failure. A document withsuccess: truebut a status other thanpasseddoes not pass.tests/test_agentic_contract.pyruns the realagenticthat CI installs withpip install 'agentic-dev @ git+…@725a7a45…', never fromPYTHONPATH. It's mandatory in CI (AGENTFLOW_REQUIRE_AGENTIC=1).Design
agentflow/agentic.pyis the only route to Agentic Dev. It invokes the CLI with argv and has no fallback.- The first call is
agentic contracts --json. It requirescontracts@1,repo-inspection@1,verification-run@1and the featurescommands.canonical-discovery,repo-inspection.discovered-commands,verification.full-kind-filter,verification.explicit-commands, andverification.no-checks-status.- It requires
verification.change-awareonly when augmentation is requested, and never runsagentic --version.- It accepts exit 1 from
verify runas a result, but checks that the exit code agrees withstatus.-
fast: lint, test-
standard: lint, typecheck, test-
strict: build, lint, typecheck, testAgentic Dev decides whether each can be met, and runs every command of each kind or reports the missing ones.
agentflow doctorshows which required kinds have no command yet; this is informational only and never changes the requirement. There is no attempt to reproduce the old per-language detector; the differences are documented under "Migration from the built-in detector" in the README.agentic.verification-rundocument. The oldGateResultflattening is removed.implement.agentflow verify --include-changedpasses--include-changed --base <run_start_commit>, omitting the base when there's no start SHA. The stage-metadata opt-in from the first draft is removed; pattern configuration is #68.Tests (50; all pass locally against agentic-dev
725a7a4, none skipped)FakeAgentic, which, like Agentic Dev, returnsno-checksand runs nothing for any missing kind): every profile kind is sent unchanged; discovery never weakens the requirement (onlytestexists, sofastfails on missinglint); custom gates go via--command; empty custom gates fall back to the profile requirement; status is authoritative; the document is kept whole; augmentation passes the base.agenticexecutable that logs its argv): missing binary; an incompatible handshake failing before anyverify run;--versionnever called; a missingjsonschemareported as itself; schema-invalidverification-runandrepo-inspectiondocuments failing closed; exit/status agreement; the custom command passed as a single argument.verify --include-changedpasses the stored SHA, and plainverifydoesn't augment.agentic:- the handshake;
- a
make check-only repo failsfastwithmissing_kinds: ["lint"]andchecks_executed: 0, andmake checkis never run;- with every required kind present,
make test,npm run test, andmake lintall execute;- an explicit failing gate;
- change-aware augmentation from the run base;
- a docs-only repo failing
standardwith all three kinds missing.install.shand checks its private venv.Also in this PR
__pycache__/*.pycfiles that #1 committed by mistake, and adds a.gitignorecovering bytecode, build output, virtual environments, tool caches, and editor files.Packaging
Runtime compatibility is decided by contracts and features only. CI pins Agentic Dev to the #69 merge commit because
0.15.0on PyPI predates these contracts. When a release containing #69 is published, addagentic-dev>=<that release>todependenciesand drop the git pin.🤖 Generated with Claude Code