- Python 77.6%
- Shell 14.9%
- Kotlin 5.9%
- Java 0.8%
- TLA 0.3%
- Other 0.5%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
|
All checks were successful
done-gate / test (3.13) (push) Successful in 5m6s
done-gate / test (3.9) (push) Successful in 17s
eval-gate / test (3.13) (push) Successful in 12s
eval-gate / test (3.9) (push) Successful in 11s
evidence / evidence (3.13) (push) Successful in 1m52s
evidence / evidence (3.9) (push) Successful in 1m48s
skills / check (3.13) (push) Successful in 35s
skills / check (3.9) (push) Successful in 35s
skills / kotlin-templates (push) Successful in 3m49s
* skills: add done-gate (Stop-hook completion gate, per-edit lint, detect.py, installer) - Stop hook runs a repo's real checks on unproven trees and blocks on non-zero exit; bounded budget, loud stand-down, no-progress early stop, advisory mode, ignore globs - PostToolUse hook feeds per-edit lint failures back; config lives outside the gated repo, repo-local .done-gate.yaml only for trusted repos - detect.py drafts checks from AGENTS.md/CLAUDE.md, scripts/*.sh and manifests; --trial times them; install.py registers the hooks idempotently - tests (53), mutation check tests/planted_bugs.py (207 hand-written mutants), golden pins, claims registry entry, workflow, README row and install line * done-gate: fix CI (pointer test, symlink mutant on Linux) - SKILL.md: describe the docs-named script example without a backticked scripts/foo.sh, which the shipped-skills pointer test requires to exist - test: lint resolves a file named through a symlink; the lint-symlink-unresolved mutant only died on macOS (/var is a symlink), not on Linux runners - regenerate evals/STATUS.md; update the claim quote --------- Co-authored-by: Nic St. Pegg <2584874+squarepegg@users.noreply.github.com> |
||
| .github/workflows | ||
| benchmarks/cryptographic | ||
| docs | ||
| evals | ||
| restate | ||
| scout | ||
| scripts | ||
| skills | ||
| snippets | ||
| .gitignore | ||
| README.md | ||
agent-toolkit
Personal collection of agent skills, small utilities and benchmarks.
Skills
| Path | What |
|---|---|
skills/adversarial-sdlc |
Spec → tests → design → build → adversarial attack → deterministic gate. Produces code that survived review and states residual risk. Has its own README.md (models, gate, Docker and optional Kubernetes backends), docs/specs/ and tests/. |
skills/dst |
Deterministic simulation testing: seeded ops, virtual clock, fault injection, seed sweeps, model-vs-real conformance. Kotlin engine plus a Python sketch. |
skills/doubt |
Doubt-driven development: materialize a fresh-context reviewer biased to disprove before a non-trivial decision stands. |
skills/evidence-gated |
Evidence-gated decisions: criteria, computed checks, blind screen, deterministic verdict. |
skills/correctness-first |
Correctness-first design: before code, write invariants, what is enforced by construction, down vs gray-failure signals; design an invariant-checking workload (ops + skewed inputs + concurrent checker + faults, bank-test template) and hand it to dst / spec-first. |
skills/property-tests |
Property tests from examples: the dumbest implementation that passes your tests, then round-trip / invariant / idempotence / oracle / metamorphic properties. |
skills/tests-as-data |
Tests as data for agent-written code: tables, scenario DSLs, golden/approval tests and evals as small human-readable files run by a frozen runner; red-first TDD, determinism rules, and scripts/guard.py, which fails a diff that touches test data or the runner in a task that should not. Tests: tests/test_tests_as_data.py. |
skills/spec-first |
Interview the user into a checkable spec (code first, one decision at a time, defaults marked assumed), then verify the change with a fresh reviewer that sees only spec + diff + raw output; scripts decide PASS / FAIL / NOT CHECKED. Tests: tests/test_spec_first.py, tests/planted_bugs.py; live evals: evals/run_evals.py. |
skills/code-review |
Risk-triage a change into tiers T0-T3 with deterministic rules (impact, boundary, detectability, recovery), then two-axis review with a finder/verifier split, evidence-gated findings, union of repeated runs and a pass-count gate. Scripts, planted-defect corpus and a mutation check. |
skills/done-gate |
Make "done" require proof in Claude Code: a Stop hook runs the repo's real checks on unproven trees and blocks on any non-zero exit; a PostToolUse hook feeds per-edit lint failures back; bounded block budget, loud stand-down on no progress, advisory mode, ignore globs, trusted-config rule. detect.py drafts a repo's checks from AGENTS.md/CLAUDE.md, scripts/*.sh and manifests (--trial times them); install.py registers the hooks. Tests: tests/test_done_gate.py, tests/test_detect.py; mutation check: tests/planted_bugs.py. |
skills/regen |
Six Phoenix-style skills for mature code: implementation-memory audit, eval tiering, deletion test, architecture constraints, decision capture, compaction pass. Link the ones you use. |
Each skill is a directory with a SKILL.md, and optionally roles/, scripts/, templates/,
reference/ and examples/.
Install
# pi / Agent Skills hosts
ln -s "$PWD/skills/adversarial-sdlc" ~/.agents/skills/adversarial-sdlc
ln -s "$PWD/skills/dst" ~/.agents/skills/deterministic-simulation-testing
ln -s "$PWD/skills/doubt" ~/.agents/skills/doubt-driven-development
ln -s "$PWD/skills/evidence-gated" ~/.agents/skills/evidence-gated-decisions
ln -s "$PWD/skills/spec-first" ~/.agents/skills/spec-first
ln -s "$PWD/skills/correctness-first" ~/.agents/skills/correctness-first-design
ln -s "$PWD/skills/property-tests" ~/.agents/skills/property-tests-from-examples
ln -s "$PWD/skills/tests-as-data" ~/.agents/skills/tests-as-data
ln -s "$PWD/skills/code-review" ~/.agents/skills/code-review
ln -s "$PWD/skills/done-gate" ~/.agents/skills/done-gate
# Claude Code: link each skill into ~/.claude/skills instead (spec-first finds `pi` or `claude` itself for its reviewer)
skills/adversarial-sdlc needs pi (or another CLI via SDLC_RUNNER_<role>), Python 3.9+, Docker or
macOS sandbox-exec, and for the Kotlin defaults JDK 21 and Gradle. Model gateway: SDLC_GATEWAY_URL
(see the skill's README). Unit tests: python3 skills/adversarial-sdlc/tests/<name>_unit_test.py;
some need ast-grep on PATH.
skills/code-review needs only Python 3.9+: python3 skills/code-review/tests/<name>_unit_test.py, then python3 skills/code-review/tests/planted_bugs.py (mutation check) (CI runs both).
skills/regen needs Python 3.9+ and git: python3 skills/regen/tests/test_<name>.py (script fixtures, structure, hygiene, probe graders; CI runs all). Its Kotlin examples are compiled and run against stub classes by bash skills/regen/tests/run_kotlin.sh (JDK 21; the @Disabled flagged-rule example compiles only). Each sub-skill has evals/probes.json and an evals/candidates/regen-<sub>.json; live A/B: python3 scripts/skill_ab.py regen/<sub> (costs tokens).
skills/dst free gates (CI runs all): skills/dst/tests/test_probes.py (probe graders both ways, every expect group answerable from the skill), test_python_template.py, test_seed_sweep.py, and scripts/check_skills.py pins, budget and forbid list from skills/dst/tests/golden.json. The Kotlin templates are compiled and run (engine self-tests, skeleton sweep, mutant catches) by bash skills/dst/tests/run_kotlin.sh (JDK 21, downloads Gradle and dependencies; the @Tag("docker") conformance test is compiled but not run). The live probe A/B for the new dst text is evals/candidates/dst-skill.json (label the PR eval).
skills/tests-as-data needs only Python 3.9+ (and git for guard.py --base): python3 skills/tests-as-data/tests/test_tests_as_data.py (CI runs it).
skills/done-gate needs Python 3.9+, git and pyyaml: python3 skills/done-gate/tests/test_done_gate.py, python3 skills/done-gate/tests/test_detect.py, then python3 skills/done-gate/tests/planted_bugs.py (207 hand-written mutants, each must be caught; CI runs all three). Hooks are installed with python3 skills/done-gate/scripts/install.py.
skills/spec-first needs only Python 3.9+, git and bash: python3 skills/spec-first/tests/test_spec_first.py, then
python3 skills/spec-first/tests/planted_bugs.py (CI runs both); evals/run_evals.py drives a live pi session and costs tokens.
Checks and evals (all skills)
Is each skill worth loading? See evals/README.md and the generated evals/STATUS.md. In short: advice witnesses
(free, CI) prove the checkable advice is correct (ignoring it misses a planted bug, following it catches it, the fixed
code passes); outcome tasks (laptop, committed ledger) measure whether an agent does the work better with the skill than
without it or with a same-length control. CI never calls a model.
python3 scripts/check_skills.py: deterministic, stdlib only, run in CI. It checks frontmatter, unique names, a README install line for each skill, no private strings, and, whereskills/<dir>/tests/golden.jsonexists: pinned text, a size budget, and hand-offs to other skills (each one must exist and still be named in the SKILL.md).--self-testplants one bug per check in a temp copy and fails if any survives.python3 scripts/skill_ab.py <dir> [--samples 3]: smoke test only (costs tokens): does the skill's text reach the model? Keyword recall is not evidence of value; that is whatevals/outcome/measures. It answersskills/<dir>/evals/probes.jsonin freshpisessions, once with only that skill loaded and once with none, and grades with fixed substring groups, never a model. Results go toresults/(gitignored). Measured deltas are in each skill'sevals/README.md.--with-path DIRloads another skill in thewitharm (same probes);--out FILEsets the results file.python3 scripts/split_skill.py split|check <skill_dir> <out_dir>: progressive disclosure for a long SKILL.md. Keeps the core sections, moves the rest toreference/sections/with one pointer line each;checkproves the split is lossless.skills/doubtis built this way (A/B-proven, see below).evals/harness-ab/: pre-registered live A/B of two ideas from arXiv 2609.00006 (load less up front; rules as a lint script). Tooling tests run in CI (python3 evals/harness-ab/test_harness_ab.py); the live run costs tokens. Verdicts:evals/harness-ab/RESULTS.md; rejected changes:evals/negative-results.md.
Adopting something new: candidate -> eval -> deterministic gate
| Workflow | When | What | Model calls |
|---|---|---|---|
evidence.yml |
push/PR | advice witnesses, claims registry, outcome graders + ledger verdicts, evals/STATUS.md current (see evals/README.md) |
none |
skills.yml, eval-gate.yml, skill-suites.yml |
push/PR | skill checks; evals/test_gate.py (verdicts, registration, properties, skill_ab -> gate through evals/fake_pi.py); scout/test_scout.py; the adversarial-sdlc and evidence-gated suites |
none |
eval.yml |
PR touching evals/candidates/, or by hand |
each added/changed evals/candidates/<id>.json: evals/gate.py on its committed evals/candidates/results/<id>.json (produced on a laptop by evals/run_candidate.py) |
none |
scout.yml |
Mondays | scout/scout.py: GitHub, HN, arXiv (scout/sources.json), minus anything already seen, ranked by keywords + stars gained per week (from the star snapshot hidden in the previous issue) ; papers listed separately from Semantic Scholar searches (last 6 months, most cited first, at least 10 citations), as a scout issue. Optional secret S2_API_KEY avoids the shared rate limit |
none |
triage.yml |
after scout.yml, or by hand |
scout/triage.py: a model nominates each new scout item A_use / B_adopt_ideas / C_discard (strict JSON schema, then fixed guardrails: A needs a GitHub repo, confidence >= 0.6 and an overlapping skill with probes), appends it to evals/triage/<date>.jsonl and opens one PR via scripts/triage_pr.sh; an A also drafts evals/candidates/_draft-<id>.json. It never adopts: only evals/gate.py can. Needs EVAL_MODEL, ANTHROPIC_API_KEY and "Allow Actions to create PRs"; skips without them |
tokens (capped by --max-cost) |
- Copy
evals/candidates/_template.jsonto<id>.json: source, a one-sentence claim, the skill whose probes test it, an optional outside skill pinned to a full commit sha (fetch+with_path), samples, thresholds. - Commit it before running. The gate refuses a candidate file that differs from HEAD, probes that changed since the run, and an unpinned model.
- Run
evals/run_candidate.pyon a laptop, commitevals/candidates/results/<id>.json, and open a PR (eval.ymlgates it). Verdicts:ADOPT(exit 0);CEILING,NO_DELTA,REGRESSION,TOO_COSTLY,INCONCLUSIVE(exit 1). Probes marked"split": "heldout"must not regress and are never tuned against. - Not adopted: paste the printed line into
evals/negative-results.mdand drop the change.
Local: EVAL_PI_ARGS='["--model","provider/id"]' python3 evals/run_candidate.py evals/candidates/dst-skill.json, then
python3 evals/gate.py evals/candidates/dst-skill.json evals/candidates/results/dst-skill.json.
Snippets
| Path | What |
|---|---|
snippets/board_to_pdf.py |
Drive a real browser, log in once, print a canvas app (Miro) board to PDF. |
snippets/copy_board.py |
Copy board items through the REST API when native export is disabled. |
snippets/run.sh |
One-shot venv + Playwright wrapper for board_to_pdf.py. |
snippets/grafana-okta-export.cjs |
Guided SSO login → read-only export of one Grafana org via its provisioning API → logout. |
No browser profiles, cookies, exports or board PDFs are stored here.
Restate
| Path | What |
|---|---|
restate/register-kafka-subscriptions.sh |
Idempotent Kafka→service subscription registration through the admin API; checks first, treats 409 as success, waits for admin readiness. |
docs/restate-operations.md |
Invocation triage, timeout settings, subscription ordering, and the metadata data-loss failure mode with recovery options. |
Benchmarks
benchmarks/cryptographic is a JMH harness comparing BLAKE3 and BouncyCastle digests, with a
collision benchmark. Build with the Gradle wrapper; results are not committed.
See also
Companion repo: agent-knowledge-map, a map of everything your coding agents know, checked against the code and scored by evals.