К основному содержанию
скилл CX Codex

flow-next-map — скилл для Claude Code: индекс функций репозитория

Скилл flow-next-map оборачивает clawpatch map, чтобы построить индекс функций и модулей репозитория на ~20 языках. По умолчанию работает без LLM-вызовов.

MIT ★ 730 обновлён 2026-10-29

Установить в Claude Code · Через маркетплейс плагинов Все способы и платформы ↓
/plugin marketplace add gmickel/flow-next
/plugin install flow-next@flow-next
Открыть на GitHub

Что делает flow-next-map

Скилл запускает clawpatch map и сохраняет индекс в .clawpatch/features/*.json. Режим по умолчанию (--source heuristic) анализирует структуру проекта эвристически — без вызовов к провайдерам, без трат на API, детерминированно. Для нестандартных репозиториев (CLI-утилиты, плагины, документация) можно явно указать --source auto или --source agent, но это потребует настроенный CLAWPATCH_PROVIDER в самом clawpatch.

Скилл проверяет наличие clawpatch (поддерживается версия >=0.4.0 <0.5.0), инициализирует .clawpatch/ при первом запуске и создаёт .gitignore со звёздочкой внутри — весь индекс локальный, в коммиты не попадает. Это защищает от шума в пул-реквестах и конфликтов слияния. flowctl не зависит от clawpatch напрямую: скилл — единственная точка касания, и его можно удалить вместе с .flow/ без следов.

Передача аргументов после -- прокидывается в clawpatch map (например, --since-ref origin/main, --paths src/). Глобы вроде * и ? доходят нетронутыми, но пробелы и метасимволы шелла не выживут — сложные кейсы проще запустить clawpatch map вручную.

Какие задачи решает

  • построить семантический индекс функций и модулей репозитория
  • проанализировать структуру проекта без вызовов к LLM
  • подготовить карту кодовой базы для скаутов и /flow-next:prime
  • инициализировать clawpatch в новом проекте
  • переиндексировать только изменённые файлы с --since-ref

Примеры запросов агенту

  • Построй индекс функций репозитория через flow-next-map
  • Запусти /flow-next:map с --source heuristic
  • Переиндексируй изменения с последнего коммита: /flow-next:map -- --since-ref HEAD~1

Как установить flow-next-map

1Через маркетплейс плагинов

/plugin marketplace add gmickel/flow-next
/plugin install flow-next@flow-next

Команда ставит плагин flow-next целиком, со всеми его скиллами

2Через Skills CLI (Vercel)

npx skills add gmickel/flow-next --skill flow-next-map -a claude-code

3Вручную: положить файлы

~/.claude/skills/flow-next-map/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/flow-next-map/

По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов

Вопросы о flow-next-map

Как установить flow-next-map в Claude Code?

Добавь репозиторий командой /plugin marketplace add gmickel/flow-next, установи плагин /plugin install flow-next@flow-next, затем скилл через npx skills add gmickel/flow-next --skill flow-next-map -a claude-code. Путь к SKILL.md — ~/.claude/skills/flow-next-map/SKILL.md.

Что делает flow-next-map?

Оборачивает clawpatch map и строит индекс функций, классов и модулей репозитория в .clawpatch/features/*.json. По умолчанию использует режим heuristic — быстрый анализ структуры без обращения к LLM. Индекс читают скауты flow-next и команда /flow-next:prime, но сам flowctl от clawpatch не зависит.

Можно ли закоммитить .clawpatch/features/ в репозиторий?

Скилл создаёт .clawpatch/.gitignore со звёздочкой — весь каталог игнорируется, индекс локальный. Это защищает от шума в PR и конфликтов слияния. Можешь отредактировать .gitignore и разрешить !features/, но тогда столкнёшься с дрифтом при каждом запуске clawpatch map — официально не поддерживается.

Исходный текст

SKILL.md · MIT
---
name: flow-next-map
description: Wrap `clawpatch map` to produce a semantic feature index of the repo (~20 languages, persisted at `.clawpatch/features/*.json`). Detects install, runs `clawpatch init` when `.clawpatch/` absent, invokes provider-free `clawpatch map --source heuristic` by default; `--source auto|agent` flows through as passthrough. Opt-in enrichment — scouts and prime read the resulting index, but flowctl never depends on clawpatch.
user-invocable: false
allowed-tools: Read, Bash, Grep, Glob, Write, Edit
---

# /flow-next:map — wrap `clawpatch map` for a semantic feature index

**Read [workflow.md](workflow.md) for the bundled-script invocation and summary.**

Wrap the upstream [`clawpatch`](https://github.com/openclaw/clawpatch) CLI's `map` subcommand. Default invocation is provider-free (`--source heuristic`) — zero LLM calls, zero API spend, deterministic mapper. Output lands at `.clawpatch/features/*.json` (Zod-validated upstream, `schemaVersion: 1`). Scout enrichment and the `/flow-next:prime` DE7 nudge read the resulting index; this skill is the install/init/invoke surface.

**Role**: thin shell-out wrapper. flowctl never imports or requires clawpatch; the skill is the only flow-next surface that touches it.

## Preamble

**CRITICAL: flowctl is BUNDLED — NOT installed globally.** `which flowctl` will fail (expected). Define once; subsequent blocks (here and in `workflow.md`) use `$FLOWCTL`:

```bash
FLOWCTL="${DROID_PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT}}/scripts/flowctl"
[ -x "$FLOWCTL" ] || FLOWCTL="<plugin-root>/scripts/flowctl"   # <plugin-root> = the directory two levels above this skill's SKILL.md file (the harness gave you that file's absolute path when the skill loaded); substitute it literally
[ -x "$FLOWCTL" ] || FLOWCTL=".flow/bin/flowctl"
```

**Inline skill (no `context: fork`)** — the map skill is fully non-interactive: install detection, version-range guard, `clawpatch init`, `.clawpatch/.gitignore` skeleton, and `clawpatch map` invocation all proceed without prompting the user. No blocking-question tool is required or used.

## Input

Arguments: `$ARGUMENTS`

Format: `[--source <heuristic|auto|agent>] [-- <extra clawpatch args>]`

- **Default** (no args) → `clawpatch map --source heuristic` (provider-free, deterministic). Heuristic targets conventional app/framework layouts; unconventional repos (CLI tools, plugins, markdown/docs-heavy, non-standard monorepos) may map to 0 features — The summary surfaces a `--source=auto|agent` suggestion when that happens.
- `--source auto|agent` → passthrough to clawpatch; user must have `CLAWPATCH_PROVIDER` configured for these paths (clawpatch's own concern, not ours).
- `--` → terminator; tokens after flow to `clawpatch map` (e.g. `--since-ref origin/main`, `--paths src/`).

**Passthrough boundary.** The slash-command host delivers `$ARGUMENTS` as a single string; the skill word-splits on whitespace. Passthrough is therefore **token-level (whitespace-separated), not full shell-verbatim** — tokens containing literal spaces or shell metacharacters that require shell quoting will not survive. Globs (`*`, `?`) are protected from expansion (`set -f` before the parse) so they reach clawpatch untouched. Users needing complex quoting should run `clawpatch map` directly.

**flow-next's review backend config (codex / copilot / cursor / claude / host / none) stays out of clawpatch.** clawpatch's provider matrix (codex / acpx / claude / cursor / grok / opencode / pi) is orthogonal — a run that sets `CLAWPATCH_PROVIDER` from the flow-next backend has broken this. The script echo reports the backend as informational only.

## Version pin

```
SUPPORTED_CLAWPATCH=">=0.4.0 <0.5.0"
```

Single source of truth for the supported clawpatch range. The bundled script parses `clawpatch --version` with a tolerant `(\d+\.\d+\.\d+)` regex and compares against this range. **Outside-range → warn one line to stderr and degrade (continue). Never block.** Re-verify on each clawpatch minor release.

clawpatch is pre-1.0 (v0.4.0, 2026-05-22; weekly minor releases). The README forecasts breaking changes between minor releases — tolerant parsing matters.

## Workflow

Invoke the bundled script as [workflow.md](workflow.md) directs. It handles
install detection, the version warning, init, ignore skeleton, streaming map
and mechanical counts. The host explains the result and optional next steps.

## Sharing contract — local-only by design

The `.clawpatch/.gitignore` skeleton this skill writes is `*` + `!.gitignore` — **everything under `.clawpatch/` is git-ignored; only the `.gitignore` itself is tracked**. The feature index is local-per-developer, not committed.

This is a deliberate design choice for a pre-1.0 mapper:

- **No PR review noise** from regenerated feature data on every `clawpatch map` run.
- **No merge conflicts** on `features/*.json` when two branches mapped at different SHAs.
- **No coupling of PR review to mapper-output drift** as clawpatch schema bumps land (weekly minor releases at the time of writing).
- **Onboarding cost is low** — `--source heuristic` is a fast filesystem walk; new contributors regenerate locally in seconds.

Teams that want a shared, in-repo feature index can edit `.clawpatch/.gitignore` directly (e.g. `!features/`, `!project.json`, ignore only `.cache/` and `*.log`). The skill is idempotent and won't clobber a customized `.gitignore` on re-run. **This is unsupported** — be prepared for review noise and merge conflicts; document the choice in your team's `CLAUDE.md` / `AGENTS.md`. See [flow-next.dev/skills/map](https://flow-next.dev/skills/map/) for the full trade-off table.

## Forbidden

- **Auto-installing clawpatch.** The skill detects and instructs; users install with their own permission. Global npm installs are user-consent territory.
- **Proxying flow-next's review backend into `CLAWPATCH_PROVIDER`.** Orthogonal matrices. clawpatch users configure clawpatch directly.
- **Auto-upgrading `--source` to `auto` or `agent` when heuristic coverage looks weak.** Users opt up explicitly via `--source`.
- **Touching the repo `.gitignore`.** The `.clawpatch/.gitignore` skeleton is self-contained inside `.clawpatch/` so a full deletion of that directory removes both data and ignore rules in one step.
- **Importing or requiring clawpatch from flowctl.** flowctl never references this skill or clawpatch — uninstall promise (`rm -rf .flow/`) stays intact and zero-dep STRATEGY track is preserved.
- **Network calls beyond what clawpatch itself does.** The wrap is local-only; clawpatch's network behavior is upstream's concern.

© Gordon Mickel · MIT · gmickel/flow-next

Похожие скиллы

Все скиллы по теме «Настройка агента: память, контекст, субагенты» →
zero-hallucination-coder Alireza Rezvani Плагин zero-hallucination-coder для Claude Code выстраивает процесс разработки до записи файлов: обсуждение, карта проекта, декомпозиция, выполнение и проверка. Отсекает выдуманные API в задачах, где они недопустимы. ★ 30 251звёзд репо gsd-map-codebase open-gsd Скилл gsd-map-codebase для Claude Code анализирует существующий проект и создаёт карту его устройства. Полное сканирование запускает параллельных агентов и сохраняет семь документов в .planning/codebase/. CX Codex +1 589установок next-best-practices pedronauck Скилл next-best-practices для Claude Code и других агентов: набор правил Next.js по файловым конвенциям, границам RSC, async API, метаданным и обработке ошибок. Подключается автоматически при написании или ревью кода на Next.js. CX Codex +1 402установок context-map официальный github Скилл context-map заставляет агента сначала собрать карту файлов, тестов и зависимостей по задаче, а код менять уже после этого. Пригодится на незнакомой кодовой базе. CX Codex +1 9 641установок map SethGammon Скилл map строит компактный JSON-индекс кодовой базы с файлами, экспортами, импортами и графом зависимостей, чтобы агент находил нужные файлы без лишних Glob и Grep. CX Codex +1 ★ 937звёзд репо codebase-map dotslashsimran Скилл codebase-map для Claude Code разбирает незнакомый репозиторий и собирает карту его архитектуры. Запускается по просьбе объяснить устройство проекта или проследить путь запроса. CX Codex +1 ★ 541звёзд репо

Из того же набора70

Весь набор →
flow-next-plan Скилл flow-next-plan превращает описание функции или существующую спецификацию в план задач, опираясь на исследование репозитория. Он пригодится до начала реализации: код скилл не пишет. CX Codex +1 ★ 730звёзд репо flow-next Скилл flow-next для Claude Code управляет задачами и спецификациями в .flow/: показывает списки и статусы, создаёт задачи и закрывает выполненные. Помогает разобраться, что запланировано и готово к работе. CX Codex +1 ★ 730звёзд репо github-scout Субагент github-scout для Claude Code ищет на GitHub примеры кода, реализации библиотек и открытые issues. Находит решения для изучения перед написанием своего кода. CX Codex ★ 730звёзд репо flow-next-prospect Скилл flow-next-prospect для Claude Code придумывает и ранжирует идеи развития на основе файлов репозитория. Запускается по просьбе обсудить, что строить дальше. CX Codex +1 ★ 730звёзд репо security-scout Субагент security-scout проверяет настройки безопасности репозитория GitHub, защиту веток, CODEOWNERS и автообновление зависимостей перед запуском агентов. CX Codex ★ 730звёзд репо flow-next-tracker-sync Скилл flow-next-tracker-sync проецирует спеку flow-next в задачу Linear, GitHub, GitLab или Jira и сверяет тело, статус и комментарии. Спека остаётся источником правды. CX Codex +1 ★ 730звёзд репо claude-md-scout Субагент claude-md-scout оценивает содержательность файлов CLAUDE.md и AGENTS.md по шкале из восьми пунктов, проверяя наличие реальных команд и проектных правил перед стартом работы. CX Codex ★ 730звёзд репо flow-gap-analyst Субагент flow-gap-analyst разбирает краткое описание функции и находит пробелы, неоднозначности и пограничные случаи. Он помогает собрать вопросы, на которые нужно ответить до начала разработки. CX Codex ★ 730звёзд репо

Спонсоры проекта

Компании, которые помогают держать аналитику открытой