No slash command · from aimi-engineering
Generates tasks.json files from feature descriptions through research, spec analysis, and story decomposition. Outputs structured task files ready for autonomous execution.
Ships in aimi-engineering. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Generate .aimi/tasks/YYYY-MM-DD-[feature]-tasks.json directly from a feature description. No intermediate markdown plan.
Take a feature description through research, spec analysis, and story decomposition. Output a tasks.json file ready for autonomous execution.
Every tasks.json field this skill writes is a plugin-owned artifact under .aimi/tasks/, so per the artifact-language rule (commands/references/user-communication.md) it is written in English.
Filename convention:
project values — multi-repo): one file per project, .aimi/tasks/YYYY-MM-DD-[feature-name]-<project-slug>-tasks.jsonproject values — single-repo/monorepo): .aimi/tasks/YYYY-MM-DD-[feature-name]-frontend-tasks.json and .aimi/tasks/YYYY-MM-DD-[feature-name]-backend-tasks.json.aimi/tasks/YYYY-MM-DD-[feature-name]-frontend-tasks.json.aimi/tasks/YYYY-MM-DD-[feature-name]-tasks.jsonThe full-stack names above are derived inside
story-mergeand returned on its stdout — read them from that return value, never re-derive them by concatenating the output base. See theimplementationScopeis"full-stack"steps in Phase 4 below.
Key fields:
schemaVersion("3.3"),metadata{title,type,branchName,createdAt,planPath(null),researchDepth(optional),maxConcurrency(20),frontendOnly(optional),splitGroup(optional:{project,index,total,siblings[]} — PROJECT-axis split files only),smellWarnings[](optional),backendSpec(optional:{endpoints[{method,path,description}],dataModels[{name,fields}],businessRules[string],businessContext(string)})},userStories[]{id(US-NNN),title(≤200),description(≤500),acceptanceCriteria(each≤5000),priority,status("pending"),dependsOn([]),notes,project(optional),wave(computed),tasks[](optional,max50,each≤5000chars),implementation(optional),verification(optional),gate(optional)}
Notes: planPath is always null (this skill generates tasks.json directly). All stories initialize with status: "pending". dependsOn is a string array of story IDs. maxConcurrency defaults to 20.
| Type | Use When |
|---|---|
feat | New feature |
ref | Refactoring |
bug | Bug fix |
chore | Maintenance task |
Execute these phases in order.
Check .aimi/brainstorms/ for a matching brainstorm (semantic match, within 14 days). If found, use as context and skip questions. If multiple match, ask user. If none, ask refinement questions via AskUserQuestion until the idea is clear.
When the loaded brainstorm carries a phases: frontmatter block (2+ sanitized phase entries — see commands/brainstorm.md "phases frontmatter rules"), materialize .aimi/tasks/<feature-slug>/roadmap.json via the aimi-cli.sh roadmap-init verb before continuing — never write it with the Write tool. Sanitize every field and re-derive each phase's phase-<id>[.<n>]-<slug> directory segment from the (sanitized) name, never trusting the frontmatter's own slug; fall back to the bare phase-<id> form with a warning if the derived segment fails ^phase-[0-9]+(\.[0-9]+)?(-[a-z0-9][a-z0-9-]*)?$. First run creates the file; a re-run against an existing roadmap.json calls roadmap-init --sync to append only phases missing by numeric id, leaving existing status/claim/branch fields byte-for-byte untouched. Absent phases: frontmatter (the common case): skip entirely — no folder created, no roadmap.json written, flow identical to today. Full field-sanitization, directory-validation, and idempotency/additive-sync rules: pipeline-phases.md.
Runs regardless of whether a brainstorm loaded this session, so a later /aimi:plan (or /aimi:plan --phase <N>) re-invocation can continue an already-materialized roadmap — auto-selecting and expanding exactly one pending phase per invocation, leaving every other phase outline-only. No roadmap.json → completely unaffected. Full rules: commands/plan.md "Rolling-Wave Phase Selection".
After the brainstorm check, determine the implementation scope:
Auto-detect default from brainstorm context (if a brainstorm was found):
frontend-only, mocked data, or prototype → default to option 1backend, API, schema, or full-stack → default to option 2Ask the user via AskUserQuestion:
What type of implementation? (1) frontend prototype with mocked data (2) full-stack implementation (frontend + backend)
Present the auto-detected default if one was determined.
Store the result as implementationScope: "frontend-only" | "full-stack" for use in Phase 4 metadata.
When no brainstorm supplied a phases: cut and no roadmap is already being continued from Rolling-Wave Phase Selection above, classify the feature description into scope contexts using the same shared reference /aimi:brainstorm's roadmap-definition gate applies — commands/references/scope-contexts.md — so a feature gets the same phase cut regardless of which command runs the classification. Zero or one scope context: fall straight through unchanged, no gate. Two or more: gated phase-cut proposal, materialized via the same roadmap-init path Roadmap Materialization above uses, then handed off to Rolling-Wave Phase Selection for phase-1-only expansion. Full gate mechanics: commands/plan.md "Scope-Context Classification (Inline Fallback)".
Follow the Resolve Agent Models section of commands/references/cli-path-resolution.md to populate AGENT_MODELS and AGENT_EFFORTS (JSON maps of category→model and category→effort). Re-read $AIMI_CLI from cache in the same Bash call. When resolution fails, treat every category as "inherit" and continue.
Prepare research directory:
mkdir -p .aimi/research
Derive topic slug from the feature description: lowercase, replace spaces/special chars with hyphens, remove consecutive hyphens, truncate to 50 chars, remove trailing hyphens. Store as topicSlug.
Generate run discriminator: Generate a single timestamp for this run (prevents same-day re-runs from overwriting prior research files):
RUN_TS=$(date +%H%M%S)
Store RUN_TS and use it in all research agent prompts for this run.
Auto-scan for git repos: Before launching research agents, scan immediate child directories for .git/ directories to discover sub-projects:
for dir in */; do
case "$dir" in .worktrees/|node_modules/|.aimi/|vendor/) continue;; esac
[ -d "$dir/.git" ] && echo "$dir"
done
List discovered repos with their relative paths from the .aimi/ parent.
Run these agents in parallel:
Task subagent_type="aimi-engineering:research:aimi-codebase-researcher"
[model: <AGENT_MODELS.research when not "inherit">]
[effort: <AGENT_EFFORTS.research when not "inherit">]
prompt: "[feature description + brainstorm context + discovered repos]
topicSlug: [topicSlug]
outputPath: .aimi/research/YYYY-MM-DD-[topicSlug]-[RUN_TS]-codebase.md"
Task subagent_type="aimi-engineering:research:aimi-learnings-researcher"
[model: <AGENT_MODELS.research when not "inherit">]
[effort: <AGENT_EFFORTS.research when not "inherit">]
prompt: "[feature description]
topicSlug: [topicSlug]
outputPath: .aimi/research/YYYY-MM-DD-[topicSlug]-[RUN_TS]-learnings.md"
Compute researchDepth and store in metadata: skip (internal + strong patterns), quick (solid patterns, minor uncertainty), standard (default), deep (security, payments, new tech, high uncertainty).
Only if Phase 1.5 decides external research is needed:
Task subagent_type="aimi-engineering:research:aimi-best-practices-researcher"
[model: <AGENT_MODELS.research when not "inherit">]
[effort: <AGENT_EFFORTS.research when not "inherit">]
prompt: "[feature description]
researchDepth: [computed researchDepth from Phase 1.5]
topicSlug: [topicSlug]
outputPath: .aimi/research/YYYY-MM-DD-[topicSlug]-[RUN_TS]-best-practices.md"
Task subagent_type="aimi-engineering:research:aimi-framework-docs-researcher"
[model: <AGENT_MODELS.research when not "inherit">]
[effort: <AGENT_EFFORTS.research when not "inherit">]
prompt: "[feature description]
researchDepth: [computed researchDepth from Phase 1.5]
topicSlug: [topicSlug]
outputPath: .aimi/research/YYYY-MM-DD-[topicSlug]-[RUN_TS]-framework-docs.md"
Consume researcher agent summary returns (brief outputs from Task calls) -- do NOT re-read .aimi/research/ files unless a summary is insufficient for a planning decision.
Fallback: If a summary lacks detail for a specific planning decision, read the corresponding
.aimi/research/YYYY-MM-DD-[topicSlug]-[RUN_TS]-*.mdfile on demand.
Merge findings into a structured consolidation with these sections:
.aimi/solutions/: gotchas, past mistakes, proven approachesTask subagent_type="aimi-engineering:workflow:aimi-spec-flow-analyzer"
[model: <AGENT_MODELS.workflow when not "inherit">]
[effort: <AGENT_EFFORTS.workflow when not "inherit">]
prompt: "[feature description + consolidated research]"
Incorporate identified gaps as acceptance criteria or story notes.
Extract requirements from research + spec-flow output
Group by user-facing capability (vertical slices). Each story bundles all layers (schema + backend + UI) needed to deliver one complete, user-observable outcome. Do NOT create horizontal layer-only stories. If a slice exceeds ~10 files or ~4 architectural layers, add to story notes: Large slice ({n} files across {k} layers). Consider splitting if there's a natural seam, otherwise proceed. Re-scope any orphan UI (component not wired to real backend) into the slice where that capability is introduced — do NOT use storybook-only or dev-preview-route verification as substitutes.
Size check (one context window per story)
Order by capability dependency (capabilities that unlock others come first; assign priority numbers)
Generate dependsOn arrays:
dependsOn: [] between themAssign project field when multiple repos were discovered in Phase 1:
project to the repo's relative path (e.g., backend, services/api)project when only one repo exists or the story targets the CWD repo./, no .. components, must match ^[a-zA-Z0-9][a-zA-Z0-9/_.-]*$Compute wave numbers from dependsOn graph:
dependsOn: []) are wave 1wave = max(wave(dep) for dep in dependsOn) + 1Populate implementation object when research provides sufficient context:
files: concrete file paths from codebase research (omit entire object if no files identified)approach: actionable strategy referencing specific codebase patternsverify: executable command or checkable assertionAssign verification strategy based on story type:
strategy: "api" (with url and expect)strategy: "visual" (with url and expect)strategy: "test" (with expect)verification.status to "pending"IMPORTANT: verification MUST be an object — never a bare string like "passed" or "pending".
Required object format examples:
{"strategy": "visual", "status": "pending", "url": "http://localhost:3000/page", "expect": "Dashboard with charts visible"}{"strategy": "api", "status": "pending", "url": "http://localhost:3000/api/endpoint", "expect": "200 with JSON array"}{"strategy": "test", "status": "pending", "expect": "All unit tests pass"}
9.5. Populate tasks[] — horizontal mechanical breakdown: for every story, generate a tasks array of 3–15 concrete mechanical sub-steps (each ≤ 5000 chars, max 50, verb-object phrasing). MUST include explicit "Wire <X> into <Y>" entries for any file in implementation.files that is also listed in another story's implementation.files (parent shells, routers, index barrels, MSW handlers, main.tsx). Order: creation → integration wiring → local verification. Tasks are planner guidance, not acceptance criteria. Omit the field (do not emit tasks: []) when fewer than 3 meaningful steps exist. See references/task-format-v3.md for the canonical fixture.Detect and attach gate objects using heuristics:
verify gate: OAuth, email, webhooks, payment, external service integrationdecision gate: multiple viable approaches with significant downstream impactaction gate: external manual action the agent cannot performAssign IDs in US-NNN zero-padded format (US-001, US-002, ...) — never US-1, story-1, S1, or any other format
Write descriptions in user story format: "As a [specific role], I want [feature] so that [benefit]" — role must name the actor, never just "user"
Generate verifiable acceptance criteria: every story must include at least one user-observable, end-to-end outcome listed first. Mixed mechanical + behavioral criteria are allowed but the user-observable item comes first.
Validate dependency graph:
dependsOn exist as story IDsBranch on implementationScope from Phase 0:
implementationScope is "full-stack":This prose predates aimi-cli.sh story-merge; /aimi:plan Phase 3e now delegates the actual full-stack split to story-merge --split full-stack (functions _story_merge_write_project_split and _story_merge_write_split) as the implementation of record — the steps below describe what that command does, not an algorithm to hand-run independently.
project values across the merged set (trim, strip one trailing slash, blank/absent treated as null). 2 or more → PROJECT axis (multi-repo): split by project, N output files, one per repo, with no frontend/backend decision anywhere on that path. Fewer than 2 → SIDE axis (single-repo/monorepo, including "no story has project" and "every story shares exactly one project"): the two-file frontend/backend split. project is an N-ary sub-project repo path, not a binary frontend/backend tag, so a multi-repo plan gets one file per repo instead of being force-fit into two side files.project — one file per group, groups ordered lexicographically by normalized path, project-less stories routed to the "." root group; normalization is grouping-only, so project itself is never mutated in the output. On the SIDE axis, classify each story by its own file-pattern/keyword heuristic verdict, unconditionally and per story.US-001 to US-M, in per-group blocks on the PROJECT axis (each repo's stories taking one contiguous run) or frontend US-001 to US-N then backend US-(N+1) to US-M on the SIDE axis — no ID collisions across files.dependsOn independently per file: cross-file references are still removed — each file's graph must stay self-contained because the files execute as independent sessions — but the drop is no longer silent: story-merge emits one aggregated stderr banner reporting the dropped-edge and affected-story counts, enumerates only the resulting false-root stories (those that lost every dependency and thereby became wave-1 eligible), and records one cross-file-dep-dropped entry per affected story in metadata.smellWarnings of every output file. Each entry is keyed by project on the PROJECT axis and by side on the SIDE axis (mutually exclusive).wave numbers per file: roots (dependsOn: []) are wave 1 within each file, independentlybranchName per file: on the PROJECT axis, one per repo derived from that group's slugified project path (e.g. apps/web → feat/merged-apps-web); on the SIDE axis, type/[feature]-frontend and type/[feature]-backend (e.g., feat/add-user-auth-frontend, feat/add-user-auth-backend).schemaVersion: "3.3", planPath: null, brainstormPath, researchDepth, maxConcurrencystatus: "pending", include dependsOn, wave, and optional implementation, verification, gate objects.aimi/tasks/YYYY-MM-DD-[feature-name]-<project-slug>-tasks.json per group, each carrying a self-describing metadata.splitGroup = {project, index, total, siblings[]}; two distinct projects that collide on the same slug hard-fail the merge before any file is written. SIDE axis writes .aimi/tasks/YYYY-MM-DD-[feature-name]-frontend-tasks.json and .aimi/tasks/YYYY-MM-DD-[feature-name]-backend-tasks.json.implementationScope is "frontend-only":metadata.frontendOnly: truemetadata.backendSpec by analyzing story descriptions and acceptance criteria:
endpoints: array of { method, path, description } objects — API contracts implied by UI interactionsdataModels: array of { name, fields } objects — data structures implied by forms and displaysbusinessRules: array of strings — validation rules and business logic encoded in acceptance criteriabusinessContext: object with structured business context:
summary: high-level overview of the business domain and purposeuserRoles: extract persona names from story descriptions ("As a [role]" patterns)constraints: identify non-functional requirements from acceptance criteria (scalability, compliance, performance SLAs)assumptions: document integration assumptions, data patterns, auth model, API stylesuccessCriteria: derive measurable success criteria from acceptance criteria across all stories.aimi/tasks/YYYY-MM-DD-[feature-name]-frontend-tasks.json-frontend suffix), createdAt, schemaVersion: "3.3", planPath: null, brainstormPath, researchDepth, maxConcurrencystatus: "pending", include dependsOn, wave, and optional implementation, verification, gate objectsimplementationScope is unset (legacy):schemaVersion: "3.3", planPath: null, brainstormPath, researchDepth, maxConcurrencystatus: "pending", include dependsOn, wave, and optional implementation, verification, gate objects.aimi/tasks/YYYY-MM-DD-[feature-name]-tasks.jsonAfter writing the tasks.json file(s), validate each generated output independently: resolve $AIMI_CLI per cli-path-resolution.md Layer 0–3 (each Bash call is an isolated shell — re-resolve at the top of every call), then for each output file run init-session --file <path> → validate-ids → validate-deps → validate-stories — once per file named by story-merge's return value, which is N files on the PROJECT axis and exactly two on the SIDE axis for full-stack splits. Drive the repetition off that returned list's length, never off a fixed count of two. Full command sequence: pipeline-phases.md.
If any validation fails (non-zero exit): read the error output, fix the offending story IDs, dependsOn references, dependency cycles, or project fields, re-write the tasks.json file with the Write tool, and re-run all validations until they pass. Do not proceed to the report step until all validations succeed.
| Phase | Failure | Action |
|---|---|---|
| Phase 0 | No feature description | Ask user for input |
| Phase 1 | Research agent fails | Proceed with available results |
| Phase 1.5b | External research fails | Proceed without external context |
| Phase 2 | Spec-flow finds critical gaps | Add gaps as story notes, flag in report |
| Phase 3 | Zero stories produced | Report error, ask user to refine scope |
| Phase 3 | 10+ stories produced | Proceed with warning in report |
| Phase 4 | File write fails | Report error with path |
Apply the validation checklist from validation-checklist.md before writing.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub aimi-so/aimi-engineering-plugin --plugin aimi-engineering19 skills in this plugin
/agent-browserBrowser automation using Vercel's agent-browser CLI. Use when you need to interact with web pages, fill forms, take screenshots, or scrape data. Alternative to Playwright MCP - uses Bash commands with ref-based element selection. Triggers on "browse website", "fill form", "click button", "take screenshot", "scrape page", "web automation"./agent-native-architectureBuild applications where agents are first-class citizens. Use this skill when designing autonomous agents, creating MCP tools, implementing self-modifying systems, or building apps where features are outcomes achieved by agents operating in a loop./Other plugins' skills for the same job