upstream-refresh
Use when grim's upstream knowledge may be stale — a harness shipped or changed a capability, watchlist rows past six months, vendor changelogs since the last check, a deep re-verify of one harness (claude, codex, copilot…), spec or forge claims, or expired research.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-14
- Stars
- ★ 15
- Forks
- 1
01 前言 Front Matter
- name
- upstream-refresh
- triggers
- [ "upstream refresh", "upstream freshness", "re-verify upstream", "harness capability sweep", "vendor changelog check", "stale watchlist rows" ]
- description
- Use when grim's upstream knowledge may be stale — a harness shipped or changed a capability, watchlist rows past six months, vendor changelogs since the last check, a deep re-verify of one harness (claude, codex, copilot…), spec or forge claims, or expired research.
- argument-hint
- [<harness>] [--domain <domain>] [--force] [--focus "<text>"]
- user-invocable
- true
- disable-model-invocation
- false
02 资源文件 4
- 参考文档references/deep-pass.md15.5 KB
- 参考文档references/domains.md20.8 KB
- 参考文档references/researcher-brief.md5.5 KB
- 脚本scripts/upstream_stale.py14.4 KB
03 SKILL.md 正文
/upstream-refresh — keep grim's upstream facts current
Re-checks the dated upstream claims grim depends on — harness capabilities,
metadata keys, settings keys, config paths and env vars, specs, forge APIs,
the product landscape, research expiry. The settings-keys check covers each
row of a harness's settings_fields() (src/install/vendor_<harness>.rs):
the key still exists with the value type and merge class grim gives it, and
each named limit holds (.agents/upstream-watchlist.md › Settings keys watchlist). Check ledger:
.agents/upstream-checks.md; per-domain
registry: references/domains.md. Design record:
harness-capability-freshness.md.
Modes
/upstream-refresh [<harness>] [--domain <domain>] [--force] [--focus "<text>"]
| Invocation | Targets | Depth |
|---|---|---|
/upstream-refresh |
every non-noop ledger row |
per ladder, never deep |
/upstream-refresh <harness> |
that harness row | deep (the only way to get one) |
--domain vendors |
the 18 harness rows |
per ladder, never deep |
--domain <catalog|specs|forge|landscape|research> |
that one domain row |
per ladder |
--force |
as selected | a noop becomes sweep |
--focus "<surface>" |
every harness row, or only the named harness | that surface only, ladder ignored |
Validate first. The positional token must be a harness name from the
ledger (claude, opencode, copilot, codex, cursor, kiro, junie,
gemini, zed, amp, antigravity, cline, droid, goose, warp,
openclaw, kilo, qoder); --domain must be vendors or a domain row
name. Anything else → stop before any edit, print the valid names. An
unknown token is never read as a focus.
Depth ladder
Never compute ages by hand:
python3 .claude/skills/upstream-refresh/scripts/upstream_stale.py ladder \
[--name <harness>] [--domain <domain>] [--force]
It prints <target> <noop|feed|sweep|deep> <reason> per target. Exit 2 →
relay its stderr and stop. 0 days → noop; 1–2 days → feed (read the
change feed from the cursor); older or never checked → sweep; a named
harness → deep. A reason ending deep due → name that harness in the
report as due for /upstream-refresh <harness>. Every target
noop → print every target checked today — no-op (use --force), edit
nothing. task upstream:stale (the script's report) is the overview.
Default run
Dead simple, one sitting (1–2 hours):
- Preflight. Not on
main; honorhex-state.md. Read the ledger and domains.md. - Pick every non-
nooptarget from the ladder. - Fan out — everything at once. One sonnet update-check subagent per
target: every Tier 1 and Tier 2 harness and every domain in the pick,
spawned together, no tier ordering, none waiting on another. Each is
briefed from
researcher-brief.md with its depth
(
feed→ Feed procedure;sweep→ every ledger row and code stamp the target owns).catalogis confirm-only andresearchfollows its dating rule (domains.md). A silent subagent is retried once, then its row stays unchanged with a note. - Collect. Findings into
## Claims; drop any without a URL and a verbatim quote (list it under## Friction). - Write class (a) fixes (Routing): ledger dates with evidence, doc and
matrix date fixes. Update each completed target's ledger row —
Last check= today,Depth,Feed cursor(the feed's newest tag),Notes. A target that did not complete keeps its row and stays stale. - Report code-driving findings (renderer, metadata, validation) in the
run report and the artifact's
## Routing— they do not block the run. - Refine and commit (Refinement, Commits).
No per-target opus gate, no per-target verify, no ordering of research — only the ledger writes and code changes after collection serialize.
Landing a code change (only when this run implements one): one batched
opus verifier re-fetches the sources of every code-driving claim and signs
off or refutes in ## Verifier sign-off — refuted claims do not land. Then
implement per Routing (b) with tests and run one task verify before the
final commit.
Deep pass (named harness only): the default run plus deep-pass.md — full surface inventory (settings keys included) and the sandboxed live CLI check, with its credential-free settings check.
Feed procedure (feed rung)
- Feed and cursor come from domains.md and the ledger row.
- GitHub feed — the paginated Releases API, never
releases.atom:gh api --paginate repos/<o>/<r>/releases --jq '.[] | [.tag_name, .prerelease] | @tsv', filtered by the tag stream domains.md names; entries above the cursor are new. Page feed (changelog) — headings above the cursor are new. - Cursor not in the fetched window → escalate to
sweep, record friction. Feed unreachable → keep the cursor, note it, go on. - Relevant entries touch a surface grim renders or documents (skills, rules, agents, MCP, hooks, frontmatter keys, settings keys, config paths, env vars); others are skipped. Advance the cursor to the newest tag, heading or version seen.
Routing
| Class | What | How it lands |
|---|---|---|
| (a) | Ledger dates, docs text, matrix rows | Fixed directly, chore: or docs: commit |
| (b) | Additive renderer or metadata support | One commit: renderer + docs page + parity test + watchlist row, with tests |
| (c) | Compatibility; config-path or install-layout moves; new vendors; class-3 requests | Issue draft — never code |
| (c) security | Any security-relevant finding | (c) security — <file:line> · <class> in ## Routing only — no draft, no detail |
(b) rules (Principle 9, docs/src/content/docs/stability.md): additive
only; a self-heal test re-materializes an artifact installed before the
change and asserts grim status reports state == "installed". Both
src/install/client_target.rs parity tests must pass — red → revert and
draft an issue, never weaken the test. A docs-page change triggers the
catalog drift review (catalog/README.md). Hooks
(PR #98) are findings only.
Issues. gh issue create only under an issue-creation grant; otherwise
an issue draft (title, body, labels) under ## Issue drafts, listed in the
final report. Security findings are never drafted as issues.
Evidence
Every changed or newly dated ledger row carries verified YYYY-MM-DD, a
primary-source URL, and the vendor version when known. Each target writes
.agents/research/research_upstream_<target>_<YYYYMMDD>.md,
**Expires:** = today + 6 months:
# Research: upstream refresh — <target> (<depth>)
## Metadata
**Date:** <YYYY-MM-DD> · **Domain:** <domain> · **Depth:** <ladder line>
**Triggered by:** /upstream-refresh <args>
**Expires:** <today + 6 months, YYYY-MM-DD>
## Claims <!-- researcher-brief.md output table -->
## Verifier sign-off <!-- only when code lands; else "none required" -->
## Live CLI check <!-- deep only: command · pass|fail|skip · reason -->
## Routing <!-- claim → a|b|c → commit or draft; security: (c) security — <file:line> · <class> -->
## Issue drafts <!-- or "none" -->
## Friction <!-- dropped claims, feed escalations, retries -->
## Skill changes <!-- summary + commit, or "none" -->
Refinement
Friction with this skill is fixed in the same run: record it under
## Friction, fix .claude/skills/upstream-refresh/** in its own
chore(skills): commit, and append one line to the discussion's
## Hand-off record:
- <date> · <target> · <depth> · skill: <change summary | no change> · artifact: <path>.
Friction with any other skill or rule goes to the retro inbox only
(hex-state.md).
Commits
- Conventional Commits with
--signoffon the current branch — nevermain, never pushed.chore:for ledger, research and skill commits;feat:/fix:/docs:for renderer and docs changes. - A pure ledger/doc run gates on
task claude:verify(plustask docs:checkwhen a docs page changed); if the commit hook still demands a freshtask verify, run it once for the whole run. A run that lands code runscargo fmtand onetask verifybefore its final commit.
04 同仓库更多 Skills
rca
Use when a bug ticket, GitHub issue or error report needs a root cause analysis before code is touched — "is this a bug", "why does this fail". Read-only. Gives a verdict (bug or not-a-bug kind), file:line evidence, ruled-out hypotheses, other affected sites, fix direction and size. A ticket, not a diff (hex-review).
fix
Use when a bug ticket or GitHub issue should go from report to an approved fix plan — "plan a fix", "fix this issue". Root-causes it via rca, then plans in plan mode with the failing regression test first. Routes to hex-plan instead when the fix is large or moves an interface contract.
p9-skill
Principle 9 differential fixture skill (v2).
p9-member
Bundle member skill for the Principle 9 fixture (v2).
p9-hookish
Hook-free skill carrying an ignored hook.toml (v2).
p9-skill
Principle 9 differential fixture skill (v1).