bump-version
Collect current git changes, infer the next version number, update HARNESS_VERSION in src/harness.py, and prepend a changelog entry to CHANGELOG.md. Triggers on: bump version, version bump, collect changes and version, release version, new version, up version.
- License 许可
- MIT
- 最近更新
- 2026-06-12
- Stars
- ★ 4
- Forks
- 0
01 前言 Front Matter
- name
- bump-version
- description
- Collect current git changes, infer the next version number, update HARNESS_VERSION in src/harness.py, and prepend a changelog entry to CHANGELOG.md. Triggers on: bump version, version bump, collect changes and version, release version, new version, up version.
03 SKILL.md 正文
Bump the hyp-harness version based on the current uncommitted changes.
Steps
0. Clean up junk files
Before anything else, remove known artifacts and stray files:
# Build/test artifacts — always safe to delete
rm -f .coverage
rm -rf dashboard/test-results/
rm -rf __pycache__ src/__pycache__ tests/__pycache__
# Scratch files
find . -maxdepth 3 -name 'working*.md' -not -path './runs/*' -delete
# Root-level stray test files (belong in tests/ — if outside, they're scratch)
find . -maxdepth 1 -name 'test_*.py' -delete
Then check for files that need a judgment call — list them and ask the user before deleting:
git status --short | grep '^??'
Known-good untracked files — include in commit without asking:
pyproject.toml— pytest config ([tool.pytest.ini_options]), always keeptests/test_*.py,tests/fixtures/— test suite, always keepdashboard/e2e/,dashboard/playwright.config.js— e2e harness, always keeptools/*.py— harness tooling, always keep.claude/skills/*/SKILL.md— canonical local skills, always keep.agents/skills/*/SKILL.md— symlinks to canonical local skills, always keep
Flag only truly ambiguous patterns (ask user before committing):
- Any
*.mdnot inruns/,docs/,tests/,.claude/skills/, or.agents/skills/— might be scratch - Any root-level
.pyoutsidesrc/,tests/,tools/— likely stray
Also check staged deletions — include them in the commit:
git status --short | grep '^D '
These are already-deleted files (e.g. removed quality module files) that need git add -u to stage properly.
1. Collect changes
git diff HEAD --stat
git diff HEAD
Read the diff carefully. Note every file changed and what was added/removed.
2. Determine current version
grep 'HARNESS_VERSION' src/harness.py
The value is the current version (e.g. "v4.3"). The next version is:
- minor bump (X.Y → X.Y+1): default for any new features, fixes, or refactors
- major bump (X.Y → X+1.0): only when the architecture changes significantly (new worker backend, new pipeline stage, breaking config format change)
3. Summarize changes into a changelog entry
Write a concise changelog block following the existing style in CHANGELOG.md:
### v<NEXT> — <TODAY_DATE>
- **<Feature/Fix name>** (`<file.py>`): <one sentence description>
- Sub-bullet for each distinct change in that file if needed
- **<Next feature>** ...
Rules:
- Group changes by logical feature, not by file
- Bold the feature name, then file in backticks
- Keep bullet text factual and specific — what changed and why (1-2 sentences max)
- Deleted files: note what was removed and why
- Test files: mention only if they cover a new public contract
- Use today's date in
YYYY-MM-DDformat
4. Update files
src/harness.py — update HARNESS_VERSION:
HARNESS_VERSION = "v<NEXT>"
CHANGELOG.md — prepend the new entry immediately after the # Changelog heading (before the existing top entry). Do not modify any existing entries. (CLAUDE.md's ## Changelog section just links here.)
4b. Sync descriptive sections in CLAUDE.md
CLAUDE.md has two kinds of content: append-only changelog, and current-state descriptions that must mirror the actual code. After writing the changelog entry, check each section below whose corresponding source files appear in the diff. For each affected section: read the actual current source, then rewrite only the stale parts.
| Changed file(s) | CLAUDE.md section to check |
|---|---|
src/harness.py, src/postproc.py |
### Post-processor pipeline — fixer count + numbered list must match PostProcessor class exactly |
src/harness.py |
## Architecture (pipeline flow), ### Evaluator-optimizer |
src/evaluator.py |
### Evaluator-optimizer — rubric names, retry logic, READER_STYLES list |
src/synthesis.py |
## Architecture synthesis step, any synthesis retry description |
src/harness.py env vars |
## Env vars (harness tuning) table — add/remove/change defaults |
dashboard/src/ |
### Dashboard (\dashboard/`)` — tabs, routes, features |
src/render*.py |
## Architecture render step description |
src/harness.py DEFAULT_WRAPPER / RETRY_WRAPPER |
## Kimi tool environment notes on FetchURL, steps |
src/harness.py progress.log events |
## Architecture progress.log API line |
How to update each section:
- Read the relevant source file(s) to get the ground truth
- Read the current CLAUDE.md section
- Edit only the lines that are now wrong — preserve surrounding prose style
- Do not expand sections beyond what the diff touched — if a section is correct, leave it
Critical: ### Post-processor pipeline fixer list
This is the most commonly stale section. The numbered list must exactly match the fixers in PostProcessor (in src/postproc.py or harness.py). Steps:
grep -n '_fix_\|_inject_\|_autonumber_\|_wrap_\|_stream_\|_fence_' src/postproc.py | grep 'def '
Count the fixers, update the header count ("21 safety-net fixers"), and add/remove numbered entries to match.
5. Sync check — find stale version refs
After updating the two canonical files, scan for any other hardcoded version strings that are older than <NEXT>:
grep -rn 'v[0-9]\+\.[0-9]\+' src/ --include='*.py' | grep -v 'HARNESS_VERSION\|\.pyc'
For each hit, classify:
| Pattern | Action |
|---|---|
HARNESS_VERSION = "vX.Y" in any run copy (runs/poc-*/harness.py) |
Skip — run copies are frozen snapshots, never update |
# mirrors harness.py vX.Y or # Prompt wrappers (mirrors …) in src/ |
Update the comment to v<NEXT> if the surrounding code was changed in this diff; leave it if untouched |
Extracted from harness.py vX.Y in module docstring |
Leave as-is — records extraction point, not current version |
Any other hardcoded version in src/*.py, dashboard/, CLAUDE.md intro |
Update if it's meant to track current version |
Dashboard files (dashboard/src/) read HARNESS_VERSION dynamically — no static sync needed.
5b. Self-update this skill
Read .claude/skills/bump-version/SKILL.md (this file) and check if the diff introduces anything that makes its instructions stale. Update the skill if any of these changed:
| What changed in diff | What to update in SKILL.md |
|---|---|
| New junk file pattern (e.g. new artifact dir, new scratch file type) | Add rm / find -delete line to step 0 |
| New "review before committing" file pattern | Add to the Flag list in step 0 |
New file added to src/ that carries version refs |
Add row to sync table in step 5 |
| New CLAUDE.md section added | Add row to mapping table in step 4b |
New env var added to harness.py |
No change needed — step 4b already covers env vars table |
HARNESS_VERSION moved to a different file |
Update step 2 grep and step 4 edit instruction |
| Commit message convention changed | Update step 8 format string |
Edit only the lines that are now wrong. Do not rewrite the whole skill.
grep 'HARNESS_VERSION' src/harness.py
grep -B 1 -A 3 '^### v' CHANGELOG.md | head -8
Confirm the version matches and the new entry is at the top of the changelog.
7. Report
Print a summary:
Bumped v<PREV> → v<NEXT>: <N> files changed — <headline of what changed>
Synced: <list of files updated beyond harness.py + CLAUDE.md, or "none">
Skipped (historical): <list of stale refs intentionally left, or "none">
8. Commit and push
Stage all changes — modified tracked files plus any deletions from step 0:
git add -u # stages all modifications + deletions to tracked files
git add src/ dashboard/ CLAUDE.md CHANGELOG.md # catches any untracked files in these dirs that should be included
# Do NOT use git add . — avoids pulling in confirmed-junk untracked files
Commit with message format release: vX.Y — <headline>:
git commit -m "release: v<NEXT> — <one-line headline of main change>"
Then push:
git push
Report the commit hash and confirm push succeeded.
Version bump heuristics
| Change type | Bump |
|---|---|
| New evaluator/rubric, new retry loop, new pipeline stage | minor |
| Bug fix, fixer added, verify check added, dashboard UI | minor |
| Refactor / cleanup / test only | minor |
| New worker backend, new CLI, breaking problem.yaml format | major |
| Docs / CLAUDE.md only | skip (no bump needed) |
File locations
| File | What to update |
|---|---|
src/harness.py |
HARNESS_VERSION = "vX.Y" constant (canonical) |
CHANGELOG.md |
prepend new entry at top |
src/*.py inline comments |
Only if code around them changed in this diff |
runs/poc-*/harness.py |
Never — frozen run copies |
dashboard/src/ |
Never — reads version dynamically at runtime |
Skill file locations
Canonical skill: .claude/skills/bump-version/SKILL.md — edit this file.
Symlink: .agents/skills/bump-version/SKILL.md → canonical.
Khi step 5b detect skill cần update: chỉ edit .claude/skills/bump-version/SKILL.md.
04 同仓库更多 Skills
pretty-mermaid
Render beautiful Mermaid diagrams as SVG or ASCII art using the beautiful-mermaid library. Supports 15+ themes, 5 diagram types (flowchart, sequence, state, class, ER), and ultra-fast rendering. Use this skill when: 1. User asks to "render a mermaid diagram" or provides .mmd files 2. User requests "create a flowchart/sequence diagram/state diagram" 3. User wants to "apply a theme" or "beautify a diagram" 4. User needs to "batch process multiple diagrams" 5. User mentions "ASCII diagram" or "terminal-friendly diagram" 6. User wants to visualize architecture, workflows, or data models
hyp-harness
Multi-model fan-out harness: given a problem.yaml spec, fans out N parallel workers (kimi CLI or Claude Code CLI) each writing one research task as markdown, runs evaluator-optimizer quality gate, synthesizes all outputs into a final report, renders to dark-theme HTML. Triggers on: harness, kimi harness, claude harness, run harness, fan-out tasks, poc harness, long running task, parallel research, parallel workers, deep research.
hyp-harness
暂无简介
bump-version
暂无简介