Test Evolve
Dev-only: manual test harness for the evolution AskUserQuestion flow. Backs up state, seeds a scenario party, auto-verifies + auto-restores after the user…
от ThunderConch★ 26 звёзд на GitHub
Установить Test Evolve в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Dev-only test harness for the evolution AskUserQuestion flow. No tmux, no spawning — the user triggers the evolution prompt manually in this live session. Verify and restore run automatically once the evolution cycle completes; the user only has to pick the scenario and click through the AskUserQuestion UI.
P="${CLAUDE_PLUGIN_ROOT:-$(ls -d ~/.claude/plugins/marketplaces/tkm 2>/dev/null || ls -d ~/.claude/plugins/cache/tkm/tkm/*/ 2>/dev/null | sort -V | tail -1)}"
Dispatch for flag arguments
--list→"$P/bin/tsx-resolve.sh" "$P/src/cli/test-evolve.ts" --list, show output, stop.--restore→ same,--restore. Emergency cleanup when an earlier cycle did not auto-restore (e.g. the session was killed mid-test).--help→ same,--help.--verifyis present in the CLI but should not be invoked directly by users; it is called automatically as part of the lifecycle below.
Scenario lifecycle (when $ARGUMENTS is a scenario name)
Step 1 — setup (this turn)
Run:
"$P/bin/tsx-resolve.sh" "$P/src/cli/test-evolve.ts" --setup ${ARGUMENTS}Show the setup output verbatim.
Tell the user, verbatim:
Party seeded for ${ARGUMENTS}. Send any short message to trigger the Stop-hook evolution prompt. After you click an option (or
Refuse), I'll auto-verify and auto-restore.Stop the turn here. Do not pre-run verify or restore.
Step 2 — user-triggered evolution turn
When the user sends any message after setup, the Stop hook emits {"decision":"block", "reason": ...} and Claude Code feeds the block's reason field back as the next turn's instruction. Within that same turn you MUST complete the entire cycle below without stopping early — do not wait for another user turn between steps, do not acknowledge and stop before the cycle finishes.
In order, without pausing:
- Render the evolution prompt. Call
AskUserQuestionexactly as the block reason directs (one subquestion per pokemon; question text copied verbatim; up to 4 buttons with the 3-eligible-plus-Refuse rule; remaining targets listed inline). - When the user answers:
- Button picking a target → resolve the button label to its target id if needed, then run
"$P/bin/tsx-resolve.sh" "$P/src/cli/tokenmon.ts" evolve <pokemon> <target>in a single Bash call. Refusebutton or Other containingrefuse/no/cancel/거부→ skip the evolve call.- Other containing a pokemon name → validate it against the candidate's
All evolution targetslist; if it matches, run evolve with the resolved target; if it does not match, reply with a short "I didn't recognize that" and re-invoke the sameAskUserQuestion(max two re-prompts, then treat as Refuse).
- Button picking a target → resolve the button label to its target id if needed, then run
- After the evolve call returns (or after the refuse path settles), print a one-line summary to the user that names the pokemon and its new form (or says "refused") so they see that their pick took effect.
- Immediately, in the same turn, run:
"$P/bin/tsx-resolve.sh" "$P/src/cli/test-evolve.ts" --verify"$P/bin/tsx-resolve.sh" "$P/src/cli/test-evolve.ts" --restore
- Show a compact final report: scenario name, user's pick, verify verdict (PASS / FAIL with any failing fields), and restore confirmation.
Critical: --restore must run even when --verify reports FAIL. The user's real state/config/hooks.json only become safe again after the restore completes.
Usage
| Command | Behavior |
|---|---|
/tkm:test-evolve branch-eevee |
Setup → user triggers → auto verify + auto restore |
/tkm:test-evolve --list |
List all 6 scenarios |
/tkm:test-evolve --restore |
Emergency restore (only needed if auto-restore was skipped) |
Scenarios (see src/test-scenarios/*.json)
branch-eevee— full 8-way branch, 3 eligible via stones + 2 via friendship; exercises the overflow rulesingle-charmander— single-chain, expect Charmeleonmulti-3— 3 pokemon ready, batch in oneAskUserQuestionoverflow-5— 5 pokemon ready, first 4 this turn, 5th deferredrefuse-persist— user refuses, verifyevolution_prompt_shownis setaccept-clear-reprompt— accept → flag cleared on the new pokemon key
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл Test Evolve?
Dev-only: manual test harness for the evolution AskUserQuestion flow. Backs up state, seeds a scenario party, auto-verifies + auto-restores after the user completes the evolution prompt.
Как установить скилл Test Evolve?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл Test Evolve запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
AnthropicGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
claude-api
AnthropicReference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
algorithmic-art
AnthropicCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
mcp-integration
AnthropicThis skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…