plugins/flow/skills/capability-discovery/SKILL.md
Discover available agents, skills, quality commands (lint, test, typecheck), tech stack, verification capabilities, and LSP code intelligence features via parallel environment scanning. Use when starting implementation, creating PRs, reviewing PRs, or addressing feedback. This skill MUST be consulted because assuming tools exist causes runtime failures, and assuming they do not causes missing capabilities.
npx skillsauth add synaptiai/synapti-marketplace capability-discoveryInstall 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.
Discovers available capabilities in the user's environment for dynamic workflow adaptation.
DISCOVER BEFORE ASSUMING. Never hardcode tool availability. Always scan the environment first.
Assuming a tool exists leads to runtime failures. Assuming it doesn't leads to missing capabilities.
Steps 1-5 are independent — execute ALL simultaneously with parallel tool calls.
Use Glob to find agent files, then Grep to extract descriptions:
Glob: ".claude/agents/*.md" — project agentsGlob: "plugins/*/agents/*.md" — plugin agentsParse: source, name (filename without .md), description (from frontmatter).
Glob: ".claude/skills/*/SKILL.md" — project skillsGlob: "plugins/*/skills/*/SKILL.md" — plugin skillsParse: source, name (parent directory), description (from frontmatter).
Glob: ".claude/commands/*.md" — project commandsGlob: "plugins/*/commands/*.md" — plugin commandsParse: source, name (filename without .md), description (from frontmatter).
CLAUDE_MD=""
[ -f ".claude/CLAUDE.md" ] && CLAUDE_MD=".claude/CLAUDE.md"
[ -z "$CLAUDE_MD" ] && [ -f "CLAUDE.md" ] && CLAUDE_MD="CLAUDE.md"
[ -n "$CLAUDE_MD" ] && grep -E "(npm|pnpm|yarn|bun|ruff|pytest|go |cargo |make )" "$CLAUDE_MD" 2>/dev/null
[ -f "package.json" ] && echo "node"
[ -f "tsconfig.json" ] && echo "typescript"
[ -f "pyproject.toml" ] && echo "python"
[ -f "Gemfile" ] && echo "ruby"
[ -f "go.mod" ] && echo "go"
[ -f "Cargo.toml" ] && echo "rust"
[ -f "Makefile" ] && echo "makefile"
If no tech stack files found and no quality commands in CLAUDE.md, report:
ls verify.sh scripts/verify* playwright.config.* cypress.config.* 2>/dev/null
Pre-check: Read lsp.enabled from settings (default true). If false, skip this step and report all LSP features as "Disabled" in the output table.
Probe for available LSP code intelligence features. Find a representative source file in the project (use the first file matching the detected tech stack — e.g., .ts, .py, .go, .rs, .rb), then test each LSP operation against it.
LSP feature probes (run each, catch failures individually):
| Operation | Test | Capability |
|-----------|------|-----------|
| documentSymbol | List symbols in the file | Symbol navigation |
| hover | Hover on first symbol (line 1, char 1) | Type info / docs |
| goToDefinition | Definition lookup on an import or reference | Definition tracing |
| findReferences | Find references to a symbol | Impact analysis |
| goToImplementation | Find implementations | Interface resolution |
Diagnostics inference: LSP diagnostics are not a discrete operation to probe — they are reported by the language server when it processes a file. If documentSymbol succeeds, the LSP server is active and diagnostics are available. Record diagnostics as "Available" when documentSymbol succeeds, "Unavailable" otherwise.
Process:
Find a representative source file using Glob (consistent with Steps 1-3):
Glob: "**/*.ts" or "**/*.py" or "**/*.go" or "**/*.rs" or "**/*.rb" (match detected tech stack)For each operation, attempt an LSP call against the file. Record success or failure:
Read lsp.timeout from settings (default 5000ms). If an operation doesn't respond within this timeout, mark it as unavailable.
Report results in the LSP Capabilities output table.
Graceful degradation: If no source files exist (markdown-only project) or no LSP server is configured, report "No LSP server available — using CLI-only analysis" and skip. This is not an error.
### Agents Available
| Agent | Source | Description |
|-------|--------|-------------|
### Skills Available
| Skill | Source | Description |
|-------|--------|-------------|
### Quality Commands
| Command | Purpose | Source |
|---------|---------|--------|
### Tech Stack
- {language} ({indicator file})
### Verification Capabilities
| Capability | Command | Source |
|-----------|---------|--------|
### LSP Capabilities
| Feature | Status | Use Case |
|---------|--------|----------|
| documentSymbol | {Available/Unavailable} | Symbol navigation in files |
| hover | {Available/Unavailable} | Type info and documentation during CODE phase |
| goToDefinition | {Available/Unavailable} | Trace code paths during EXPLORE phase |
| findReferences | {Available/Unavailable} | Impact analysis during EXPLORE, caller verification during REVIEW |
| goToImplementation | {Available/Unavailable} | Interface resolution |
| diagnostics | {Available/Unavailable} | Quality signal during VERIFY phase (errors→P1, warnings→P2) |
| Missing | Fallback | |---------|----------| | No agents | Use built-in review checklist | | No CLAUDE.md commands | Detect from tech stack | | No tech stack | Ask user for commands | | No LSP server | CLI-only analysis (grep/glob for references, CLI tools for diagnostics) |
This skill runs in a forked context. The calling command must store the output for use in later phases — do not re-invoke within the same command execution.
tools
Validate a FlowWorkflow YAML at `plugins/flow/workflows/<id>.workflow.yaml` against `schemas/v1/workflow.schema.json` AND cross-reference the referenced skills/agents exist + every Tier 3 action is confirm-gated + no native /goal or /loop dependency is declared. Use when /flow:workflow validate is invoked, when CI runs the workflow schema gates, or when a new workflow is being authored. This skill MUST be consulted because schema validation alone catches shape errors; cross-reference validation catches the silent-correctness failures (typo'd skill name, Tier 3 escape, /goal dependency) that would otherwise ship to users.
tools
Verify UI-facing changes by running a screenshot-analyze-verify loop across configured viewports, with a browser-tool priority cascade (Playwright MCP → Chrome DevTools MCP → CLI fallback → external skill fallback) and bounded iteration. Use after build/runtime verification passes and the diff includes `.tsx`/`.jsx`/`.vue`/`.html`/`.css`/`.scss`/`.svelte` files OR the acceptance criteria mention UI/page/render/display/visual. This skill MUST be consulted because UI changes that pass build and unit tests can still ship blank pages, render-blocking console errors, or broken responsive layouts that no other verification phase catches.
data-ai
Coordinate agent teams for adversarial review (paired skeptic/verifier per facet, challenge round with disposition vocabulary, consolidated findings with confidence) or parallel implementation (task sizing 5-6 per teammate, non-overlapping files). Enforces independent analysis before shared conclusions. Reference only (`disable-model-invocation: true`); loaded only when `agentTeams: true` in settings.
development
Conduct two-stage code review: Stage 1 verifies spec compliance (criterion-to-code mapping), Stage 2 evaluates security, correctness, performance, and maintainability across 6 parallel facets with P1/P2/P3 synthesis and deduplication by file:line. Use when reviewing code changes or pull requests. This skill MUST be consulted because reviewing quality on broken logic is wasted effort, and unmet acceptance criteria must block merge.