Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

prior-work-retrieval

БесплатноЗапускает вложенные скриптыНе проверен

Only for explicit prior-work/reuse/history requests, not status checks. Finds and verifies existing work before new production when reuse is plausible. Use…

daymadeот daymade★ 1 556 звёзд на GitHub

Об этом скилле

Prior Work Retrieval

Run this before substantial production only when the trigger above is present. Read-only current-state checks stay direct unless the user asks for history. Its job is not to generate another summary. Its job is to answer: what already exists, which source is current, what should be reused, and what remains genuinely new?

Not for: current-file inspection, ordinary bug fixes, mechanical verification, or a task merely because the final answer happens to be a report/summary. A mention of current/现有 tests, README, files, implementation, behavior, or validation is not by itself a prior-work request. Do not infer the trigger merely because new work might duplicate something — that risk alone does not make a request explicit.

Completion contract

A retrieval pass is complete only when all conditions below are true:

  1. The task's real business outcome is written as one sentence.
  2. Every relevant carrier declared in the manifest reports searched, manual_completed, or an explicit failure/coverage gap.
  3. Candidate claims are opened at their original path or record, not accepted from a search snippet alone.
  4. Each adopted item has a reuse or adapt decision and a reason tied to the current task. If nothing is adopted, the receipt carries a concrete no_reuse_reason.
  5. scripts/prior_work.py check accepts the receipt for this session.

retrieved is not verified; verified is not reused. Keep those states separate so “I searched” cannot impersonate “I used our best prior work.”

Workflow

1. Read the local operating context first

Before querying, read the current project's AGENTS.md/CLAUDE.md, navigation index, and any North Star/current-decision file they name. Historical material cannot override a newer explicit decision.

2. Validate the explicit source manifest

Treat the manifest as a source inventory, not authorization to read every listed directory. Bind each filesystem search to a concrete project directory authorized for the current task with retrieve --filesystem-scope <project-dir>. Repeat only for explicitly relevant projects or bounded asset directories. Never derive these arguments by copying every manifest root. Workspace, home and cross-project collection roots are not substitutes for a project scope; use an existing index to locate the project first. Validate the selected manifest:

Run the commands below from the actual installed Skill directory. When invoking them from a project directory, use the bundled scripts' absolute paths.

uv run --no-project python scripts/prior_work.py \
  --manifest <path> validate-manifest

The CLI's --manifest override applies only to that invocation. Hooks use PRIOR_WORK_MANIFEST inherited by their host, or ~/.config/daymade/prior-work/sources.json when unset. Keep CLI operations and hooks on the active requirement's required-source contract and recorded state; manifest paths may differ when that contract agrees and the hooks can read the requirement and receipt.

An export in a child shell does not change an already running parent host's environment. Complete that host's legitimate current contract. Bind the intended manifest for a future host before its hooks activate; do not replace required sources mid-task to make a receipt pass.

Place global options before the subcommand. The schema and carrier examples are in references/source-manifest.md.

3. Retrieve across declared carriers

For a follow-up on an already retrieved incident, check the existing session receipt before starting another full pass. A valid receipt permits reusing its verified originals while their scope, authority and inputs remain applicable; inspect only a decision-bearing gap or changed state. Answer a recurrence question from the old action/result and current identities, rather than substituting a new remedy for the explanation requested.

The hook strips supported machine envelopes before classifying the human request. It recognizes specific phrasing for current-code follow-ups and reuse of verified digests or cached results for the current task. Recognized current-task follow-ups leave the existing requirement untouched. An explicit historical request still re-arms retrieval, including a human request after a supported envelope has been stripped. Weak recall can reuse a valid receipt. If check reports an older prompt, complete the current requirement through this workflow. Preserve receipt identities and required sources. Scope reclassification applies only to a proven false-positive requirement. Distinguish an exact replay, a clarification using the same evidence, and a request for different historical work before proposing a trigger change. Trigger changes require the hook owner's real-history false-positive and recall calibration.

Write the user-world outcome separately from the proposed implementation. Then provide:

  • --outcome-term: 1–5 artifact/event/entity/date terms
Полный SKILL.md на GitHub

Установить prior-work-retrieval в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

evals/evals.jsonreferences/source-manifest.mdreferences/visual-result-reuse.mdscripts/prior-work-retrieval.shscripts/prior_work.pyscripts/prior_work_hook.pyscripts/surface_version.pyscripts/verify_artifact.py

FAQ

Что делает скилл prior-work-retrieval?

Only for explicit prior-work/reuse/history requests, not status checks. Finds and verifies existing work before new production when reuse is plausible. Use when the user explicitly references earlier work, existing code, history, or prior decisions, or says 以前做过, 已有代码, 别重复造轮子. Not for current tests, files, bug fixes, or mechanical verification. Produces a reuse/adapt/reject receipt; zero hits never prove absence.

Как установить скилл prior-work-retrieval?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл prior-work-retrieval запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить prior-work-retrieval с