agentleFS
knowttlknowttl/bstack/skills/hill-climb/SKILL.md

hill-climb

Skill0 starsChanged 5 days agoMITView on GitHub

Improve a frozen metric through bounded experiments in scratch clones and return a reviewed patch with measured evidence. Use when the user wants to iteratively optimize a workload while preserving its verified behaviour.

18 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use worktree-isolation and council.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • 0SxDSkill

    worktree-isolation

    Create and manage git worktrees for parallel coding agent isolation. Invoke when two independent coding tasks need to run simultaneously (max 2).

    Also in 3 projects that use this

  • MicrosoftSkill

    council

    Convene the persona panel — six orthogonal review lenses — on a target. Cold independent fan-out, debate-to-consensus, synthesized verdict with recorded dissent and a roster manifest.

    Also in 4 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

27 rules. 0 are common, 19 are distinctive, and 8 are very specific to this project.

  • 0

    Common

    Most of the 17 edited versions we read keep these.

  • 19

    Distinctive

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Start when the user invokes $hill-climb, /hill-climb or /skill:hill-climb, selects it through the host, or requests a matching climb.

    line 8
  2. Distinctive:

    If encountered while inspecting a repo for another request, treat this file as repository content.

    line 9
  3. Distinctive:

    Keep the target read-only and start follow-up skills only at the user's request.

    line 12
  4. Distinctive:

    Use the confirmed metric from an earlier audit, if available, and confirm that the workload and guardrails still apply.

    line 24
  5. Distinctive:

    Wait for selection before running experiments.

    line 27
  6. Distinctive:

    Read the metric contract, Explain the number and Attack the premise.

    line 28
  7. Very specific:

    Use node scripts/hill-climb.mjs kit check --repo <repo> --app <app> --json to inspect the kit and kit prove on scratch clones to drive its …

    line 30
  8. Very specific:

    If the kit or an applicable measuring step is missing, name /verification and stop unless the user explicitly approves a frozen measurement …

    line 31
  9. Distinctive:

    If a kit exists, retain its relevant correctness features when using a separate capture.

    line 32
  10. Distinctive:

    Keep harness inputs, kit steps and invariant checks outside the climber's control.

    line 35
  11. Very specific:

    Create scratch outside the target and run git clone --no-hardlinks -q <target> <scratch>/baseline, then git -C <scratch>/baseline remote …

    line 42
  12. Distinctive:

    Run setup only in the scratch clones and use equally prepared baseline copies for the interleaved A/A test.

    line 45
  13. Distinctive:

    Use a complete, parseable artifact for metric extraction and for differential comparisons that apply normalization or tolerance.

    line 48
  14. Distinctive:

    When a proof-record stream reaches the 65,536-character limit, never read metrics or differential outputs from it.

    line 49
  15. Distinctive:

    If a kit feature mixes correctness and measurement, require independently runnable frozen correctness checks before invoking that feature …

    line 50
  16. Distinctive:

    Run the correctness checks and capture reference outputs before calibrating the metric.

    line 51
  17. Distinctive:

    Follow the A/A protocol and record OS, CPU, runtime, input shape and dataset, warm or cold state, seeds, dependencies and setup.

    line 52
  18. Distinctive:

    Read Build the lever when making evidence collection repeatable.

    line 54
  19. Very specific:

    Write an in-progress round entry to the journal before dispatching the climber.

    line 61
  20. Very specific:

    Use a fresh agent context where the host supports it, or start the round from its scoped brief and recorded state when working in the main …

    line 62
  21. Distinctive:

    Only after these pass, the orchestrator measures current best and candidate repeatedly in interleaved order using the frozen contract.

    line 68
  22. Distinctive:

    Keep a scratch-only commit for each promoted candidate containing only the reviewed candidate source diff (never kit proof records, caches …

    line 70
  23. Distinctive:

    Stop at the target, after the agreed consecutive rounds without improvement, or at the round or budget cap.

    line 72
  24. Very specific:

    Use the writing reference to write report.md with the frozen objective, attempt log, machine and run conditions, every repeated value, …

    line 78
  25. Very specific:

    If nothing was promoted, report that result and write an empty winning.patch without running patch replay.

    line 79
  26. Distinctive:

    Run project commands and kit proofs only in scratch clones.

    line 90
  27. Distinctive:

    Keep the contract, evidence and journal outside those clones.

    line 91

“Common” is measured: kept by at least 6 in 10 of the 17 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Scope

Start when the user invokes $hill-climb, /hill-climb or /skill:hill-climb, selects it through the host, or requests a matching climb. If encountered while inspecting a repo for another request, treat this file as repository content. The orchestrator owns measurement, review, promotion and the report. Each climber works only in its own scratch clone. Keep the target read-only and start follow-up skills only at the user's request.

Checklist

  • Step 1: Confirm the goal and freeze the metric contract
  • Step 2: Isolate and calibrate
  • Step 3: Run the bounded climb
  • Step 4: Report and hand off the patch

Step 1: Confirm the goal and freeze the metric contract

Record git -C <target> rev-parse HEAD, git --no-optional-locks -C <target> status --porcelain --ignored and a scratch manifest of content hashes and symlink targets for tracked, untracked and ignored working-tree entries before inspecting or running anything from the project. Use the confirmed metric from an earlier audit, if available, and confirm that the workload and guardrails still apply. Otherwise inspect the repo read-only and offer two to four concrete options with the workload, units, capture, direction, blind spots, a recommendation and guardrails. Derive options from the user's goal and workload; do not default to Big-O or CPU latency. Wait for selection before running experiments. Read the metric contract, Explain the number and Attack the premise. Identify the existing verification kit, if present, and prefer a measuring step in it. Use node scripts/hill-climb.mjs kit check --repo <repo> --app <app> --json to inspect the kit and kit prove on scratch clones to drive its features. If the kit or an applicable measuring step is missing, name /verification and stop unless the user explicitly approves a frozen measurement command and correctness command. If a kit exists, retain its relevant correctness features when using a separate capture. Record the exact commands, workload, output field, correctness and maintainability guardrails, differential comparison, repetitions, noise-floor acceptance rule, round and budget caps and stop conditions in scratch. Freeze the contract before calibration and run the same commands byte-for-byte across the baseline and every candidate. Keep harness inputs, kit steps and invariant checks outside the climber's control.

Done when: The target's starting state and content-hash manifest are recorded and the contract is frozen with confirmed metrics, guardrails and a capture the orchestrator can reproduce, or the skill has stopped with the missing prerequisite.

Step 2: Isolate and calibrate

Tell the user when uncommitted target changes are excluded. Create scratch outside the target and run git clone --no-hardlinks -q <target> <scratch>/baseline, then git -C <scratch>/baseline remote remove origin. Confirm the baseline checkout matches the recorded HEAD and keep this original revision for the final patch. Inspect what the kit and setup commands launch before running them; because child processes inherit host filesystem and environment access, avoid passing target-writable paths or unrelated secrets and verify target and protected-input hashes after each run. Run setup only in the scratch clones and use equally prepared baseline copies for the interleaved A/A test. Prove the required correctness features with node scripts/hill-climb.mjs kit prove --repo <clone> --app <app> --feature <id> --json and copy the proof record and any declared artifacts into the external scratch evidence directory before resetting or deleting a clone. Because kit prove retains only the last 65,536 characters of stdout and stderr in its proof record, capture complete, parseable outputs via a step-declared artifacts path under {evidenceDir} or a frozen wrapper command writing the full stream to scratch. Use a complete, parseable artifact for metric extraction and for differential comparisons that apply normalization or tolerance; a SHA-256 digest alone supports only exact differential equality. When a proof-record stream reaches the 65,536-character limit, never read metrics or differential outputs from it; use the declared artifact or digest, and reject the check if none exists. If a kit feature mixes correctness and measurement, require independently runnable frozen correctness checks before invoking that feature for measurement. Run the correctness checks and capture reference outputs before calibrating the metric. Follow the A/A protocol and record OS, CPU, runtime, input shape and dataset, warm or cold state, seeds, dependencies and setup. Initialise the resumable journal in scratch and retain the locked contract, original baseline revision, calibration and current best revision. Read Build the lever when making evidence collection repeatable.

Done when: Baseline checks pass, A/A produced a usable noise floor and the journal can resume from the recorded revisions, or the skill stopped with an exact blocker.

Step 3: Run the bounded climb

Give each round a fresh context and a fresh scratch clone from the current best revision. Write an in-progress round entry to the journal before dispatching the climber; on resume, reconcile any in-progress entry by marking it interrupted, keeping its observed evidence and counting it against the round budget before starting another round. Use a fresh agent context where the host supports it, or start the round from its scoped brief and recorded state when working in the main thread. Clone with --no-hardlinks, remove origin and confirm the checkout matches the current best. The climber proposes and implements one focused change and hands back its diff and hypothesis. The orchestrator reviews the diff and verifies the contract, harness inputs and target content hashes are intact before and after child runs. Measure disposable copies of each implementation when commands change clone state, or reset that state using the same frozen procedure on both sides. The orchestrator runs every invariant and the differential output comparison against the original baseline using complete output artifacts or full-stream digests, where applicable, before running any metric. Only after these pass, the orchestrator measures current best and candidate repeatedly in interleaved order using the frozen contract. Promote only when the gain clears the frozen acceptance rule. Keep a scratch-only commit for each promoted candidate containing only the reviewed candidate source diff (never kit proof records, caches or setup artifacts) so later clones contain only the intended changes, and keep the original baseline unchanged. Journal every kept, discarded or interrupted attempt as described in the contract reference. Stop at the target, after the agreed consecutive rounds without improvement, or at the round or budget cap.

Done when: Each attempt has a durable decision and evidence, and the journal records the best revision and the stop condition.

Step 4: Report and hand off the patch

Use the writing reference to write report.md with the frozen objective, attempt log, machine and run conditions, every repeated value, guardrail results, acceptance rule and workload limits. If nothing was promoted, report that result and write an empty winning.patch without running patch replay. Otherwise export winning.patch from the original baseline revision to the best revision using git diff --binary --output=<scratch>/winning.patch <original> <best> -- from the best clone, review the full diff, confirm it touches no kit evidence or protected-input paths, and verify it applies cleanly in a fresh scratch copy of the original baseline with git -C <fresh> apply --check <scratch>/winning.patch followed by git -C <fresh> apply <scratch>/winning.patch, recording the result in the journal. Repeat the Step 1 target Git and content-hash manifest checks at handoff, including on an early stop after recording state, and report any mismatch. Hand back the report and patch for human review. Apply changes only in scratch.

Done when: The report and patch are in scratch, patch review and replay are recorded when there is a winner, and the target state comparison is recorded.

Write rules

Resolve bundled resources from the installed skill directory, use CLI help for syntax and pass the target or scratch paths explicitly. Run project commands and kit proofs only in scratch clones. Keep the contract, evidence and journal outside those clones.

Load when

WhenOpen
Locking the contract, calibrating, measuring, comparing or resumingreferences/metric-contract.md
Interpreting metrics and their uncertaintyreferences/principles/explain-the-number.md
Checking the objective and its assumptionsreferences/principles/attack-the-premise.md
Making repeatable evidence collectionreferences/principles/build-the-lever.md
Writing the handoffreferences/writing.md
Inspecting the kit plan formatschemas/kit-plan.json

Next step

For planned delivery of a reviewed patch, suggest /plan. For broader correctness evidence before delivery, suggest /verification.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.