wicked-garden-platform-gate-benchmark-rebaseline
Skill9 starsChanged 7 months agoMITView on GitHub
Re-baseline procedure for the AC-11 gate-result benchmark lane (`tests/crew/test_gate_result_benchmark.py`). The benchmark enforces a 2× p95 SLO on `gate-result.json` ingestion. When a deliberate perf change lands on main (validator hardening, cache tuning, schema expansion), the baseline needs updating. Never re-baseline to silence a regression.
In this repository142 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .claude/CLAUDE.mdCLAUDE.md
- plugin-json-schemaSkill
- readme-style-guideSkill
- releaseSkill
- scaffoldSkill
- wicked-garden-agentic-agentic-patternsSkill
- wicked-garden-agentic-architectSkill
- wicked-garden-agentic-context-engineeringSkill
- wicked-garden-agentic-frameworksSkill
- wicked-garden-agentic-performance-analystSkill
- wicked-garden-agentic-review-methodologySkill
- wicked-garden-agentic-safety-reviewerSkill
- wicked-garden-agenticSkill
- wicked-garden-agentic-trust-and-safetySkill
- wicked-garden-appsSkill
- wicked-garden-archetypeSkill
- wicked-garden-build-guideSkill
- wicked-garden-classifySkill
- wicked-garden-coreSkill
- wicked-garden-data-engineerSkill
- wicked-garden-dataSkill
- wicked-garden-deliberateSkill
- wicked-garden-demoSkill
- wicked-garden-domain-coverageSkill
- wicked-garden-domain-extractorSkill
- wicked-garden-domain-modelerSkill
- wicked-garden-domainSkill
- wicked-garden-draftSkill
- wicked-garden-editor-scaffoldSkill
- wicked-garden-engineering-api-documentarianSkill
- wicked-garden-engineering-architectureSkill
- wicked-garden-engineering-backendSkill
- wicked-garden-engineering-debuggingSkill
- wicked-garden-engineering-docsSkill
- wicked-garden-engineering-frontendSkill
- wicked-garden-engineering-integrationSkill
- wicked-garden-engineering-large-scale-migrationSkill
- wicked-garden-engineering-migration-engineerSkill
- wicked-garden-engineering-patchSkill
- wicked-garden-engineeringSkill
- wicked-garden-engineering-solution-architectSkill
- wicked-garden-engineering-system-designSkill
- wicked-garden-engineering-unit-test-qualitySkill
- wicked-garden-governed-workerSkill
- wicked-garden-groundSkill
- wicked-garden-jam-brainstorm-facilitatorSkill
- wicked-garden-jam-councilSkill
- wicked-garden-jamSkill
- wicked-garden-learnSkill
- wicked-garden-mcp-scaffoldSkill
- wicked-garden-mcpSkill
- wicked-garden-mem-captureSkill
- wicked-garden-mem-ingestSkill
- wicked-garden-memSkill
- wicked-garden-personaSkill
- wicked-garden-platform-auditSkill
- wicked-garden-platform-compliance-officerSkill
- wicked-garden-platform-complianceSkill
- wicked-garden-platform-errorsSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 33
Do not re-baseline to silence a regression: If the benchmark fails on a PR that didn't intend perf work, treat it as a real regression and …
- Very specific: line 45
Missing-baseline behavior: if benchmark_baseline.json is deleted or malformed, the test soft-skips with a directive to record one.
- Distinctive: line 87
If the benchmark lane is broken or disabled on main:
- Very specific: line 102
All flags auto-expire at WG_GATE_RESULT_STRICT_AFTER.
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Gate-Result Benchmark Re-baseline
Operational procedure for updating tests/crew/benchmark_baseline.json after a legitimate perf change on main.
When to re-baseline
Re-baseline only when a deliberate perf change lands on main. Examples:
- Validator hardening (added / removed gate-result schema checks)
- Cache eviction tuning (changes to gate-result ingestion memoization)
- Schema expansion (new required fields in
gate-result.json) - Sanitizer pattern changes (
scripts/qe/content_sanitizer.py)
Do not re-baseline to silence a regression. If the benchmark fails on a PR that didn't intend perf work, treat it as a real regression and find the cause.
How the lane works
- Workflow:
.github/workflows/benchmark.yml - Trigger: PRs touching
scripts/crew/phase_manager.py, the gate-result schema/sanitizer (scripts/qe/content_sanitizer.py), or the benchmark test/baseline themselves. Other PRs skip the lane to keep default CI cost flat. - Test:
tests/crew/test_gate_result_benchmark.py::test_load_gate_result_p95_within_2x_baseline - Marker:
benchmark— opt-in. Localuv run pytestdeselects it (seepyproject.tomladdopts = "-m 'not benchmark'"). - Explicit invocation:
uv run pytest -m benchmark - Fixtures: 50 deterministic
gate-result.jsonfiles cycling through 1 KB / 4 KB / 16 KB / 60 KB (bounded byMAX_SUMMARY_BYTES). Each round clears the memoization cache so the full validate + sanitize + cache-insert path is measured. Cache-hit timing is not part of the SLO. - Baseline:
tests/crew/benchmark_baseline.json—p95_nsin nanoseconds. - Assertion:
p95_current ≤ slo_multiplier × p95_baseline(defaultslo_multiplier = 2.0). The workflow comments the delta on every triggered PR. - Missing-baseline behavior: if
benchmark_baseline.jsonis deleted or malformed, the test soft-skips with a directive to record one. The SLO is not enforced until a valid baseline is present — so a re-baseline PR can merge without a circular dependency.
Re-baseline procedure
Check out the target main commit.
git checkout main && git pullRun the benchmark three times. The SLO is against p95, and CI noise varies — taking the highest of three local runs adds margin.
uv run pytest -m benchmark tests/crew/test_gate_result_benchmark.py -s uv run pytest -m benchmark tests/crew/test_gate_result_benchmark.py -s uv run pytest -m benchmark tests/crew/test_gate_result_benchmark.py -s- Record the highest
p95_currentreading from the three runs. Update
tests/crew/benchmark_baseline.json:Field New value p95_nsThe highest p95_currentfrom step 3, rounded uprecorded_onToday's date ( YYYY-MM-DD)recorded_from_commitShort SHA of the target main commit slo_multiplierLeave at 2.0unless the AC-11 contract changesrebaseline_procedureLeave at wicked-garden:platform:gate-benchmark-rebaselineCommit the baseline update in a dedicated PR. Title convention:
chore(benchmark): re-baseline AC-11 after {change-summary}- The benchmark workflow runs on the PR and must pass (p95 should be well under 2× the new baseline since you just measured it).
Pre-flip dependency (semantic-gate condition)
Strict mode for gate-result ingestion (WG_GATE_RESULT_STRICT_AFTER, default 2026-06-18) requires the AC-11 benchmark lane to be active in CI. Rationale: once strict-mode activates, a silent 2×+ perf regression would push every approve_phase call over the SLO without a guard.
If the benchmark lane is broken or disabled on main:
- Before the flip date: push
WG_GATE_RESULT_STRICT_AFTERout (env var or default-constant update). Do not let strict-mode activate without benchmark enforcement. - After the flip date: fix the benchmark lane before touching the ingestion path.
Env-var rollback (preferred over revert)
For production rollback of a specific ingestion check, prefer env-var soft-disable over git-revert:
| Variable | Effect |
WG_GATE_RESULT_SCHEMA_VALIDATION=off | Skip schema validator |
WG_GATE_RESULT_CONTENT_SANITIZATION=off | Skip content sanitizer |
WG_GATE_RESULT_DISPATCH_CHECK=off | Skip dispatch-log orphan check |
All flags auto-expire at WG_GATE_RESULT_STRICT_AFTER.
References
- Test:
tests/crew/test_gate_result_benchmark.py - Baseline:
tests/crew/benchmark_baseline.json - Workflow:
.github/workflows/benchmark.yml - Ingestion path:
scripts/crew/phase_manager.py(gate-result load + memoization) - Sanitizer:
scripts/qe/content_sanitizer.py
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

