analyze-task

analyze-task is a command for Claude Code from fockus/skill-memory-bank. It costs 44 tokens per session (1,030 once invoked), scanned A, original, MIT.

A command that classifies the current goal and changed files into one development route, such as research, bug fixing, or a code change.

In plain words
What is it for?
Use it to write the resolved route into `status.md`. It can select research, bugfix, code-change, or architecture work, while enforcing minimum requirements for higher-risk changes.
Why use it?
It helps choose an appropriate workflow automatically instead of making the user select a route manually.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: positional $N argument.

Good fit Use it to write the resolved route into status.md. It can select research, bugfix, code-change, or architecture work, while enforcing minimum requirements for higher-risk changes.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/fockus/skill-memory-bank/analyze-task
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/fockus/skill-memory-bank

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for analyze-task

README.md
[![agentmods](https://agentmods.dev/badge/commands/fockus/skill-memory-bank/analyze-task/github.svg)](https://agentmods.dev/commands/fockus/skill-memory-bank/analyze-task)
Your own site
<a href="https://agentmods.dev/commands/fockus/skill-memory-bank/analyze-task"><img src="https://agentmods.dev/badge/commands/fockus/skill-memory-bank/analyze-task/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for analyze-task

Your own site · 80×15
<a href="https://agentmods.dev/commands/fockus/skill-memory-bank/analyze-task"><img src="https://agentmods.dev/badge/commands/fockus/skill-memory-bank/analyze-task.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 44 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,030 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00044 $0.01030
Opus 5.5 $0.00018 $0.00412
Sonnet 5.5 $0.00009 $0.00206
Haiku 4.5 $0.00004 $0.00103

Measured 15d ago against content hash 7c52c60179c2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

analyze-task scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 15d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/analyze-task.md · 87 lines

How it starts

The opening of the file, as written. The whole thing — 87 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/mb analyze-task

Auto-route the current flow. This is the default Dynamic Flow entry point (REQ-DF-020): read the durable goal.md and the git diff --name-only scope, classify a single candidate route from the catalogue, then hand that candidate to scripts/mb-flow-route.sh, which applies the deterministic route-floor (REQ-DF-022) and writes the resolved route: into the <!-- mb-flow --> fence in status.md.

Auto-routing is the default. To bypass classification with a fixed route, use the explicit escape-hatch /mb flow <route> (see commands/flow.md). Both paths still apply the route-floor and the firewall — the override never wins below the floor (REQ-DF-025).

The route catalogue

Pick exactly ONE candidate (lowest route that genuinely fits the work):

  • research — investigation/spike; no production code change expected.
  • bugfix — reproduce → debug → patch a localized defect.
  • code-change — the dominant case: a feature/change inside existing seams (reuses the work.md loop, ADR-7). Default when unsure.
  • arch — touches contracts, domain rules, ports/interfaces, or cross-module structure. The route-floor can FORCE this regardless of your pick.
  • migration — schema/data/dependency migration with ordering risk.

What it does

  1. Resolve the active Memory Bank (scripts/_lib.sh::mb_resolve_path).

  2. Read .memory-bank/goal.md (end-state + ## Acceptance criteria) and the changed-file scope from git diff --name-only (plus --cached).

  3. Classify a candidate route from the catalogue above.

  4. Call the resolver — it applies the floor and writes the fence:

    SKILL_DIR="$(cd "$(dirname "$0")/.." && pwd)"   # memory-bank skill bundle root
    bash "$SKILL_DIR/scripts/mb-flow-route.sh" --candidate <your-pick>
    
  5. Report the resolved route from the JSON the resolver prints ({"candidate":...,"floor":...,"route":...,"floor_triggered":...,"reasons":[...]}). If floor_triggered is true, say so and name the reasons — the floor overrode your candidate on purpose.

Read the full file on GitHub · 87 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 15d ago Changed · +25 tokens per session 7c52c60179c2
  2. 1mo ago First seen · 87 lines · 19 tokens per session scan A a3d741ac14c2

Subscribe to this mod's changes

analyze-task is a command published in the GitHub repository fockus/skill-memory-bank (29 stars, last pushed 4d ago), licensed MIT. It adds 44 tokens to every session and 1,030 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.