Skip to content

Consolidate 30 skills → 1 zerion skill + fix init.js onboarding#86

Merged
graysonhyc merged 1 commit into
mainfrom
consolidate-skills-fix-init
May 27, 2026
Merged

Consolidate 30 skills → 1 zerion skill + fix init.js onboarding#86
graysonhyc merged 1 commit into
mainfrom
consolidate-skills-fix-init

Conversation

@graysonhyc
Copy link
Copy Markdown
Collaborator

Summary

Fixes the onboarding pain evgen flagged in Slack: the picker showed 30 separate Zerion skills (mostly partner demos), install counts scattered, Claude Code wasn't auto-selected, and `npx -y zerion-cli init -y --browser` could stall when the CLI was already installed.

  • Collapsed 30 `skills/zerion-` dirs into one `skills/zerion` skill with progressive disclosure. Capabilities (analyze, trading, sign, wallet, agent-management, swap-0x) live in `skills/zerion/capabilities/.md`. Partners (Bankr, Li.Fi, Moonpay, Vaults.fyi, Trails, Umbra, Somnia, Monad, Sendai, Uniswap, Consolidate) live in `skills/zerion/partners/*.md`. The root `SKILL.md` is ~150 lines and routes by task — capability/partner docs are loaded on demand via Read.
  • `cli/commands/init.js`:
    • `ensureGlobalInstall` now short-circuits if `zerion --version` already resolves, even when invoked via npx temp dir (previously re-ran `npm install -g zerion-cli` on every npx call).
    • `installSkills` now auto-detects the host coding agent via env fingerprints (`CLAUDECODE`, `CURSOR_TRACE_ID`, `CODEX_HOME`, `GEMINI_API_KEY`) and fallback `~/.` dirs, then passes `-a ` to `npx skills add` so the 55-agent multi-select picker doesn't open.

What this fixes (from Slack)

  1. 27+ skills polluting picker → now 1 entry (`zerion`).
  2. Install counts scattered → single skill = single counter.
  3. Bug: `init -y --browser` stuck when CLI installed → `which zerion` short-circuit + agent auto-pin removes the picker hang.
  4. Claude Code not selected by default in picker → detected and passed via `-a claude-code` automatically.

Test plan

  • `npm test` — 299/299 pass
  • `node --check cli/commands/init.js`
  • Manual: `npx -y zerion-cli init -y --browser` on a clean machine + a machine with global install
  • Manual: verify Claude Code picker shows single `zerion` skill
  • Manual: agent reads `capabilities/trading.md` correctly for a swap intent
  • Manual: `gemini extensions install …` still works end-to-end
  • Confirm install-count metric on agentskills.io now reports one slug

🤖 Generated with Claude Code

…it.js

Onboarding pain: 30 separate skills polluted agentskills.io picker and
scattered install counts. Now one `zerion` skill at the top, with
progressive disclosure via nested `capabilities/*.md` (core: analyze,
trading, sign, wallet, agent-management, swap-0x) and `partners/*.md`
(Bankr, Li.Fi, Moonpay, Vaults.fyi, Trails, etc.). Same total content,
loaded on demand — root SKILL.md stays ~150 lines.

init.js fixes:
- ensureGlobalInstall now short-circuits if `zerion --version` already
  resolves globally, even when npx temp dir hosts the binary (was
  re-installing on every run when CLI was already present).
- installSkills auto-detects the user's coding agent (env fingerprints
  + ~/.<agent> dirs for claude-code, cursor, codex, gemini) and passes
  `-a <agent>` to `npx skills add` so the 55-agent multi-select picker
  doesn't open. ~70% of users are on Claude Code — this skips the
  manual checkbox dance evgen flagged.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@graysonhyc graysonhyc merged commit 257ebe0 into main May 27, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant