framework/core/commands/init/SKILL.md
Initialize project with AGENTS.md and rules, handling both Greenfield (new) and Brownfield (existing) projects.
npx skillsauth add korchasa/flowai initInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Analyze the project, conduct an interview (for Greenfield projects), and
generate a single AGENTS.md file (root) with all project rules, a CLAUDE.md symlink
(for Claude Code compatibility), rules, and scaffolding.
Legacy three-file layouts (documents/AGENTS.md, scripts/AGENTS.md) are detected and collapsed into the single root file.
The agent uses template files from assets/ as reference and writes files directly.
File Structure: init produces a single ./AGENTS.md file containing all sections:
<step_by_step>
Initialize
Analyze Project
deno run --allow-read scripts/generate_agents.ts .
{ "ok": bool, "result": {...} }. The result field contains: project metadata (is_new, stack, file_tree, readme_content), component inventory, and verification checks.Greenfield Workflow (Interview)
interviewer subagent (or conduct Q&A inline if subagent unavailable).
Prompt: "You are helping initialize a new (Greenfield) project. Conduct a brief interview to gather:
Return a SINGLE JSON object: { "project_name": "...", "vision_statement": "...", "target_audience": "...", "problem_statement": "...", "solution_differentiators": "...", "risks_assumptions": "...", "stack": ["..."], "architecture": "...", "key_decisions": "...", "preferences": ["tdd", "strict-mode", ...], "use_deno_tooling": boolean, "use_devcontainer": boolean }"
Brownfield Workflow (Discovery & Extraction)
package.json, deno.json, README.md, etc.).legacy_layout_detected from the analyzer output.documents/AGENTS.md and/or scripts/AGENTS.md exist):
./AGENTS.md, ./documents/AGENTS.md, ./scripts/AGENTS.md.## Documentation Rules section, scripts content → ## Development Commands section, everything else stays in its existing root section../AGENTS.md with the merged result.git rm the two sub-files (documents/AGENTS.md, scripts/AGENTS.md) and their CLAUDE.md symlinks (documents/CLAUDE.md, scripts/CLAUDE.md) if they exist../AGENTS.md.Component Inventory
inventory section from the analysis output (step 2) to check which components exist.Generate AGENTS.md File
Read the pack-level template at ../../assets/AGENTS.template.md (reference for ./AGENTS.md, single file containing all sections).
For Greenfield: Fill template with interview data. Replace {{PLACEHOLDERS}} with actual values.
For Brownfield:
./AGENTS.md: Use the template structure. Fill with data inferred from the project. Preserve user's custom PROJECT_RULES (content between --- and the next ## heading). If legacy layout was collapsed in step 4, the merged content is already prepared — use it.Output: a single ./AGENTS.md file.
Claude Code Compatibility (CLAUDE.md Symlink)
./CLAUDE.md -> ./AGENTS.md.CLAUDE.md does not exist: create the symlink, report to user.CLAUDE.md exists and is already a correct symlink to AGENTS.md: skip silently.CLAUDE.md exists as a regular file or wrong symlink: warn the user, show the current content/target, and ask for confirmation before replacing with the symlink.CLAUDE.md symlinks exist (documents/CLAUDE.md, scripts/CLAUDE.md), they should already be deleted during the legacy-collapse step (step 4). If they still exist at this point, delete them now.OpenCode Compatibility Check
inventory section from the analysis output (step 2) includes opencode_json.exists and opencode_json.has_subdirectory_globs.opencode_json.exists is true and the instructions array contains references to documents/AGENTS.md or scripts/AGENTS.md: propose removing only those stale entries. Do NOT add an AGENTS.md replacement entry — OpenCode auto-loads the root file.Generate Documentation
AGENTS.md: SRS, SDS, tasks, and index. If a role is missing, add it to AGENTS.md before generating docs.SRS: Fill based on interview data (Greenfield) or inferred context (Brownfield). Skip if file exists and has more than 50 lines.SDS: Create initial structure. Skip if file exists and has more than 50 lines.tasks directory:
Configure Development Commands
use_deno_tooling: true, FORCE usage of configure-deno-commands.Deno -> configure-deno-commands).SKILL.md.check, test, dev, prod) using the project's native command runner. For example, for Node.js projects add scripts to package.json; for Make-based projects add targets to Makefile. Do NOT create a scripts/ directory with wrapper scripts if the project's command runner can handle commands directly.check command to ensure it works.use_devcontainer from interview data.setup-ai-ide-devcontainer skill. Read and follow its SKILL.md.project_info.json, interview_data.json (if created).deno run --allow-read scripts/generate_agents.ts .
verification section. If passed is false (exit code 1), fix the issues before proceeding.check command runs successfully../AGENTS.md exists and no legacy documents/AGENTS.md or scripts/AGENTS.md remain.</step_by_step>
tools
Delegate a task to another AI IDE's CLI (codex / claude / opencode / cursor-agent) through an isolated-context subagent. Triggers on "delegate to <ide>", "have <ide> do <task>", "execute <task> in <ide>", "offload to <ide>". For one-shot relay or fan-out comparison use `ai-ide-runner` instead.
tools
Run prompts in Claude Code, OpenCode, Cursor, or Codex CLIs from the current session — pick one IDE, fan out across several, or compare models. You are a courier that relays the other runtime's stdout verbatim, do not synthesise your own answer. Use on "run in <ide>", "compare <ide> vs <ide>", "try on <model>", "which IDE handles X better", "run across models".
tools
Recommend which LLM model to use for a task. Use when asked "which model / best LLM for X", "pick a model for this task", or for a model shortlist ranked by live leaderboard evidence (coding, reasoning, agentic, tool-use, price, speed). Live-fetches public leaderboards and ranks models with per-axis rationale and citations.
development
Produce a comprehensive Product Requirements Document (PRD). Use when the user asks to write a PRD or formalize a feature's scope, goals, and success metrics.