agentleFS
fieldingfielding/skills/intent/SKILL.md

intent

Skill1 starsChanged 4 months agoMITView on GitHub

Capture the intent of a code change as plain, factual context: What it does, Why, what is in/out of Scope, and the Decisions reviewers shouldn't re-litigate. Stage 0 of the `gate` code pre-submission pipeline. Downstream stages (lint/test gate, state-space-minimization, mutation testing, conventions, review-crew, fold-findings) review the change against this stated purpose, and it becomes the PR body later. Use when the user says "establish intent", "capture the intent", "what is this change for", "/intent", or before running the gate pipeline on a fresh branch. Produces plain context, NOT voiced or scrubbed prose -- voice and AI-tell scrubbing happen later, at the open-PR stage. AI-written is fine here.

15 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use hud, ralplan and 4 more.

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.
  • ibahgatSkill

    hud

    Control omi visual HUD profile and keep status output readable in normal, compact, or hidden mode.

    Also in 3 projects that use this

  • ibahgatSkill

    ralplan

    Create a strict, quality-first execution plan with explicit gates and rollback-ready sequencing.

    Also in 3 projects that use this

  • nicepkgSkill

    team

    根据任务快速组建临时 AI Agent 团队协作。自动从 .claude/agents/ 中选择最合适的成员组队。

    Also in 3 projects that use this

  • sahinSkill

    execute

    Also in 3 projects that use this

  • NVIDIASkill

    research

    Before designing a feature, research how comparable libraries solve the problem, check best practices, known pitfalls, and upstream changes. Use when starting a new feature, investigating an unfamiliar area, or the user asks to research something.

    Also in 5 projects that use this

  • Microsoft AzureSkill

    verify

    End-to-end app testing pipeline for browser-based web apps on cloud browsers via Azure Playwright Workspaces: verify the live app, author tests for working flows, heal failing tests, then re-run with video and produce one consolidated report. Three phases (app verification, test authoring, test healing) plus a scoped final sanity run; each phase emits a sub-report. Use when asked to "verify my app", "make sure my app works and has good test coverage", "do a full QA pass", "add tests where I'm missing coverage", "fix failing tests and add new ones", "smoke test before deploy", "QA my deployment", or any combined verify-and-test ask. Requires Azure CLI (`az login`) and a Playwright Workspace resource ID — bootstraps configs on first invocation. Browser-based web apps with Playwright only — not for unit/API tests, native mobile/desktop, load/perf, or full accessibility audits.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 6 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 14 edited versions we read keep these.

  • 6

    Distinctive

    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
  1. Distinctive:

    This is not user-facing prose: Do NOT apply voice or scrub AI tells here.

    line 23
  2. Distinctive:

    Keep it plain, clear, factual.

    line 24
  3. Distinctive:

    Keep it tight. Every line should be something a reviewer can act on.

    line 47
  4. Distinctive:

    Use the vendored reader (self-contained -- no skill-distill dependency):

    line 59
  5. Very specific:

    When gate runs in a disposable worktree (treehouse or git worktree), the reader filters by *that* tree's cwd and finds only unrelated …

    line 76
  6. Distinctive:

    Read the transcript and summarize + disambiguate it into What / Why / Scope / Decisions.

    line 83
  7. Distinctive:

    If the diff makes the What obvious, state it -- don't ask.

    line 104
  8. Very specific:

    Before writing intent.md, apply a light secret-redact: strip obvious pasted secrets -- API keys, tokens, op:// references, …

    line 109

“Common” is measured: kept by at least 6 in 10 of the 14 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

Intent

Stage 0 of the gate pre-submission pipeline. Capture WHY a change was made as plain, factual context so every downstream stage can review the change against its stated purpose -- and so the human never has to re-explain it.

This is not user-facing prose. Do NOT apply voice or scrub AI tells here. Keep it plain, clear, factual. AI phrasing is fine. (Voicing/scrubbing happens later, at the open-PR stage.) The job here is accuracy and completeness, not style.

Output

A plain intent.md at a stable per-branch path so later stages can find it: /tmp/<branch>-intent.md (use the current git branch --show-current; replace / in the branch name with -).

# Intent: <short title>
## What
<what the change does -- factual, from the diff + transcript>
## Why
<goal / motivation -- from the transcript, or asked if absent>
## Scope
- In: <what this change covers>
- Out: <deliberately deferred, each with a one-line rationale>
## Decisions
- <settled tradeoff/decision + why -- so reviewers don't re-litigate it>

Keep it tight. Every line should be something a reviewer can act on. No filler, no hedging, no "this PR aims to."

Capture (priority order)

1. PRIMARY -- the recent agent transcript(s) for THIS change

Whoever just wrote the code already expressed the WHY in conversation. Read the most recent relevant session(s) whose cwd matches the current repo, newest first. Claude Code is the primary / most recent tool; Codex and pi are also supported.

Use the vendored reader (self-contained -- no skill-distill dependency):

python3 {skill-dir}/scripts/read-recent-session.py            # newest matching session
python3 {skill-dir}/scripts/read-recent-session.py --list --count 5   # pick the right one
python3 {skill-dir}/scripts/read-recent-session.py --count 2 --max-chars 6000

Notes on the reader:

  • Matches sessions by the transcript's recorded cwd (inside the repo root), not the lossy encoded directory name.
  • Excludes Claude Code subagent sidechains by default (subagents/ transcripts are the agent talking to itself, not the human-stated WHY). Pass --include-subagents only if the top-level session is thin.
  • The current intent-capture session is itself the newest match -- skip it and use the session that actually contains the change discussion. --list makes this easy: read the timestamps/branches and choose the one for THIS change.
  • When gate runs in a disposable worktree (treehouse or git worktree), the reader filters by that tree's cwd and finds only unrelated sessions. The authoring session lives under the original checkout: run the reader there, or, when the current conversation is the authoring session, write from it directly and say so.
  • Already applies a light secret-redact pass on its output.

Read the transcript and summarize + disambiguate it into What / Why / Scope / Decisions. Pull Scope-Out and Decisions from moments where the user or agent explicitly deferred something or chose between options.

2. FALLBACK -- no usable transcript

Derive the What from the diff + commit messages + branch name:

git diff master...HEAD          # or the merge base
git log master..HEAD --oneline
git branch --show-current

Then ask the user a few targeted questions for only the non-inferable parts:

  • Why / the goal behind it
  • What is deliberately out of scope
  • Any key decisions a reviewer might otherwise second-guess

3. Never ask what the diff already shows

If the diff makes the What obvious, state it -- don't ask. Only ask about intent that isn't recoverable from code: motivation, deferred scope, and tradeoffs.

Redact step

Before writing intent.md, apply a light secret-redact: strip obvious pasted secrets -- API keys, tokens, op:// references, bearer/Authorization values, JWTs, KEY=/TOKEN=/SECRET= assignments -- so they never land in the file, even internally. The reader does this on its output; do the same for anything you add by hand. When unsure, redact.

How downstream stages use it

intent.md is the shared contract for the rest of gate:

  • lint/test gate, conventions -- sanity baseline; intent frames what "done" means for this change.
  • state-space-minimization, mutation testing -- check the change actually covers its stated Scope (and nothing creeps in from Scope-Out).
  • review-crew -- reviews the diff against the stated What/Why instead of guessing the goal; Decisions tell reviewers what's already settled.
  • fold-findings -- reconciles crew findings with the declared Scope/Decisions.
  • open-PR stage -- takes this plain intent.md and then voices + scrubs it into the user-facing PR body.

So: be accurate and complete here. Style is somebody else's stage.

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.