framework/core/commands/flowai-adapt/SKILL.md
Adapt project-local flowai primitives (skills, agents, AGENTS.md artifacts, hooks) to project specifics. Standalone adaptation — independent of flowai-update.
npx skillsauth add korchasa/flowai flowai-adaptInstall 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.
Adapt project-local flowai framework primitives (skills, agents, AGENTS.md artifacts, hooks) to the current project's tech stack and conventions. Runs independently of flowai-update — use after first project-local install, stack change, or selectively for specific resources.
Plugin-installed and user-level primitives are read-only for this command. If flowai is installed through an IDE plugin or a global/user config directory, do not rewrite those files. Report that no project-local primitives are available unless the user asks to create a local copy.
Adaptation state is tracked through git history — no extra metadata fields needed. The working tree contains the current version; git show HEAD:<path> provides the previous adapted version for 3-way merge.
Two subagents handle the actual adaptation work:
flowai-skill-adapter — adapts a single skill's SKILL.mdflowai-agent-adapter — adapts a single agent's .md body (preserving frontmatter)
</context>
<step_by_step>
Detect IDE config directories
.claude/, .cursor/, .opencode/.Parse arguments
--skills -> only skills.--agents -> only agents.--assets -> only AGENTS.md artifacts.--hooks -> only hooks.Adapt skills (when applicable)
flowai-* directories in {ide}/skills/.deno test, deno lint, deno fmt in a Python/pytest or Go project).
d. Skip skills that do not contain stack-specific commands/examples, and mention them in the summary.
e. For no-arg full adaptation, cap the first automatic batch to the highest-signal skills (prefer flowai-commit, flowai-do, and stack setup skills) so the run can still verify assets and ask confirmation before timeout. Report remaining candidates as deferred follow-ups.flowai-skill-adapter subagent per selected skill — all in parallel.git show HEAD:<path>/SKILL.md (previous adapted version, if exists)git diff HEAD -- <skill-path>.git checkout HEAD -- <skill-path>.Adapt agents (when applicable)
flowai-* files in {ide}/agents/.flowai-commit for skills and flowai-console-expert for agents when they contain stale commands.--- through closing ---) for that agent.flowai-agent-adapter subagent per selected agent — all in parallel..md (current version)git show HEAD:<path> (previous adapted version, if exists)deno test, deno lint, or deno fmt as recommended project commands, rerun or fix that agent before presenting the diff.git diff HEAD -- <agent-path>.git checkout HEAD -- <agent-path>.Verify AGENTS.md artifacts (when applicable)
pack.yaml from installed packs (via .flowai.yaml) to get the assets: mapping (template name -> artifact path).pack.yaml is unavailable, use default mapping:
AGENTS.template.md -> AGENTS.mddocuments/AGENTS.md or scripts/AGENTS.md, defer to flowai-update or flowai-init to run the legacy-collapse procedure — do NOT handle collapse here.{ide}/assets/.
b. Read the project artifact.
c. Compare using git diff --no-index -- <template> <artifact>.
d. Ignore {{PLACEHOLDER}} sections in the diff.
e. Focus on framework-originated sections (rules, TDD flow, doc formats, planning rules).
f. If framework sections are outdated -> propose update with before/after.Adapt hooks (when applicable)
{ide}/scripts/ (installed by flowai).deno lint, npm test).Summary
</step_by_step>
development
Use when the user asks to add TypeScript strict-mode code-style rules to AGENTS.md for a TypeScript project using strict mode. Do NOT trigger for Deno projects (use setup-agent-code-style-deno) or non-strict TS configurations.
development
Use when the user asks to add Deno/TypeScript code-style rules to AGENTS.md, or during initial Deno project setup when code-style guidelines need to be established. Do NOT trigger for non-Deno TypeScript projects (use setup-agent-code-style-strict), or for runtime-agnostic style advice.
testing
Use when the user provides a source (URL, file path, or free text) to save into the project's memex — a long-term knowledge bank for AI agents. Stores the raw source, extracts entities into cross-linked pages, runs a backlink audit, and updates the index and activity log. Do NOT trigger on casual reads; only when the intent is to persist a source into the memex.
development
Use when the user asks to audit a memex (long-term knowledge bank for AI agents) for orphans, dead SALP REFs, missing sections, contradictions, or index drift. Runs a deterministic structural check, layers LLM-judgement findings, optionally auto-fixes trivial issues with `--fix`. Do NOT trigger on general code linting.