agentleFS
allemaarallemaar/open-skills/skills/prime-expand/SKILL.md

prime-expand

Skill15 starsChanged 34 days agoApache-2.0View on GitHub

Expand a vague gap into concrete questions + named source candidates via a delegated sub-agent — caller sees only the proposed pair for confirm/edit/refuse, never the expansion reasoning. Trigger /prime-expand, "expand on this", or auto-fire on handoff receipt with a thin brief. (Not for ambient "I need to know X" phrasing — that would collide with /investigate.) Single sub-agent, single turn, ≤3 candidate-source spot-checks only. Pairs with /prime-fetch (single noisy tool call) and /prime-sweep (large source-surface investigation).

The file

We split this skill into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈8

    Distinctive · estimate

    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. Very specific:

    If the seed is already a sharp question with named sources, do not run this skill — pass straight to /prime-fetch or /prime-sweep.

    line 49
  2. Distinctive:

    Only the proposed pair returns to the lead.

    line 83
  3. Distinctive:

    If the sub-agent cannot produce ≥1 question with ≥1 plausible source, its validation status explicit, it emits:

    line 93
  4. Distinctive:

    MUST delegate the expansion work to one sub-agent — the lead never reads sources itself.

    line 110
  5. Distinctive:

    MUST cap the sub-agent's reading to ≤3 candidate-source spot-checks of ≤200 lines each.

    line 111
  6. Distinctive:

    MUST emit only the proposed pair (or a refusal line) to the lead — sub-agent reasoning stays in the sub-agent's window.

    line 112
  7. Distinctive:

    MUST refuse with a one-line reason if the seed cannot be expanded into ≥1 concrete question + ≥1 plausible source.

    line 113
  8. Very specific:

    MUST NOT let the sub-agent run Grep, WebFetch, Bash, or any tool that produces large output — those belong to /prime-fetch or /prime-sweep.

    line 114
  9. Distinctive:

    MUST NOT allow the sub-agent to spawn further sub-agents (depth-1 cap).

    line 115
  10. Distinctive:

    MUST NOT require proof-of-work citations — this skill produces intent (a question + candidate sources), not factual findings.

    line 116

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “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

/prime-expand

Expand a vague gap statement into a concrete priming target — sharp question(s) + source candidates with explicit validation status — via a delegated sub-agent, so the expansion reasoning never enters the caller's context. The caller sees only the proposed pair and confirms, edits, or refuses.

Structured execution spec: protocol.yon. Read it for the canonical rules and step sequence; this file is explanation. The two must stay in sync — if you edit one, update the other and refresh the @STAMP date.

Caller Options. Before executing, run the Caller Options protocol (caller-options/SKILL.md): triage this invocation for material optionality across the venues and modes declared in front-matter; if one path clearly dominates, proceed silently; otherwise surface the options to the caller.

Family invariant — /prime-* skills delegate. Every /prime-* skill uses sub-agents so the caller's context stays clean. /prime-expand is the lightest member: one sub-agent, one turn, no deep reading.

Boundary

Use /prime-expand to turn a fuzzy "I should know more about X" into a sharp {questions[], sources[]} pair ready to feed downstream priming. Do not use it for actual investigation — that is /prime-fetch (single noisy tool call) or /prime-sweep (large source-surface, parallel sub-agents). Do not use it to gather facts for the user — that is /investigate.

Step 1 — Receive the seed gap

The seed can be a vague statement, a topic, or a worry. Examples:

  • "I need to know about auth"
  • "what about the cache layer?"
  • "expand on yesterday's bug"
  • "prime me before I touch the rate-limiter"

If the seed is already a sharp question with named sources, do not run this skill — pass straight to /prime-fetch or /prime-sweep.

Step 2 — Build the context snapshot

Assemble a short snapshot for the sub-agent only. This is the only context-bridge — the sub-agent must not see the caller's full conversation history.

  • CWD, project type (language/framework if known).
  • Last few files mentioned in this turn.
  • The caller's current task or objective if known.
  • Include only the bounded relevant caller conversation units needed to resolve a conversation pointer, never an unseen reference to the full history.

Step 3 — Brief and spawn the sub-agent

Before dispatch, bind the worker and total invocation to finite deadlines and resource limits, with a named monitoring owner, observable progress, a cancellation handle and terminal success/failure/timeout outcomes. Use native controls; include read-only scope and no-child instructions in research briefs. On failure or timeout, cancel owned work and report retained partial results and unchecked coverage. If these controls are unavailable, do not dispatch. Mandatory delegation cannot fall back to inline source gathering; report the missing capability and stop the dependent operation.

Spawn one sub-agent with a fresh context window. The brief contains:

  • The seed gap, verbatim.
  • The context snapshot from Step 2.
  • Light scan permissions: Glob and Read to validate candidate sources exist and look plausible (≤3 files, ≤200 lines each). No deep reading, no Grep, no WebFetch, no Bash.
  • Output contract requiring only the proposed pair (or a refusal line).

Step 4 — Sub-agent expands

The sub-agent works in its own window:

  1. Parses the seed for likely subject, scope, and missing specifics.
  2. Generates 1–3 concrete declarative questions implied by the seed.
  3. Proposes ≥1 source candidate per question (file path, URL, doc reference, the conversation above, the search-result dump in turn N).
  4. Spot-checks permitted local candidates (Glob / Read, within the existing caps), labeling those actually checked.
  5. Distinguishes remote URLs, unsupplied conversation units and inaccessible candidates as unverified; do not discard a plausible remote source solely because Glob cannot validate it. Discard only evidenced irrelevant or nonexistent sources.

Step 5 — Sub-agent emits the proposed pair

Only the proposed pair returns to the lead. The sub-agent's working/reasoning stays in its own window.

Seed: <original input verbatim>
Expanded:
  Q1: <concrete declarative question>
  Q2: <optional second question if seed implies more than one>
  Sources: [<source 1>, <source 2>, ...]

If the sub-agent cannot produce ≥1 question with ≥1 plausible source, its validation status explicit, it emits:

Seed: <original input verbatim>
Refused: cannot expand — <one-line reason>

Step 6 — Surface for confirm / edit / refuse

The lead presents the proposed pair to the caller (or user) and waits for one of three responses:

  • Confirm — emit {questions[], sources[]} preserving every confirmed question and its source associations; if a downstream call needs one question, explicitly select or combine the confirmed objective first to the caller for direct use, or chain into /prime-fetch / /prime-sweep.
  • Edit — caller revises questions or sources; lead re-emits the revised pair.
  • Refuse — caller proceeds without priming; skill exits.

Rules

  • MUST delegate the expansion work to one sub-agent — the lead never reads sources itself.
  • MUST cap the sub-agent's reading to ≤3 candidate-source spot-checks of ≤200 lines each.
  • MUST emit only the proposed pair (or a refusal line) to the lead — sub-agent reasoning stays in the sub-agent's window.
  • MUST refuse with a one-line reason if the seed cannot be expanded into ≥1 concrete question + ≥1 plausible source.
  • MUST NOT let the sub-agent run Grep, WebFetch, Bash, or any tool that produces large output — those belong to /prime-fetch or /prime-sweep.
  • MUST NOT allow the sub-agent to spawn further sub-agents (depth-1 cap).
  • MUST NOT require proof-of-work citations — this skill produces intent (a question + candidate sources), not factual findings.

Next Steps

  • /prime-fetch — if the confirmed pair needs a single noisy data-fetch resolved (Grep, WebFetch, MCP).
  • /prime-sweep — if the confirmed pair's sources are large or numerous enough that direct reading would flood the caller's context.

Next skills. On completion, run the Next Skills protocol (next-skills/SKILL.md): surface the next-skills recommendations from front-matter for the caller to pick. Offer only — never auto-invoke.

Self-improvement. On completion, run the Self-Improvement Protocol (self-improve/SKILL.md): apply its signal taxonomy and threshold to this run; surface any surviving proposal for handler approval. Conservative — silent otherwise. Never auto-apply.

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.