initx

A project setup command that examines a codebase, identifies its technologies, and creates project-specific helper agents. It can also update the project's CLAUDE.md instruction file.

In plain words
What is it for?
Use it to detect frontend, backend, mobile, or security technologies, create essential or focused agents, preview changes, overwrite existing agents when needed, and choose a project template or model.
Why use it?
It reduces the manual work of explaining a project's structure and choosing suitable specialist agents. Preview and focus options let you inspect or narrow the setup before files are created.

Command

Part of the sub-agents plugin โ€” 2 commands, 28 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/toskysun/sub-agents/initx
Clone the repo
git clone --depth 1 https://github.com/Toskysun/sub-agents

Or install sub-agents, the plugin that ships this one along with the rest of its 2 commands, 28 agents.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,241 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.02241
Opus 5 $0.00000 $0.01120
Sonnet 5 $0.00000 $0.00448
Haiku 4.5 $0.00000 $0.00224

Measured 3d ago against content hash 01069c19fe8e, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

initx scanned grade A with 0 findings against 26 rules in 11 categories โ€” prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency โ€” measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/initx.md ยท 290 lines

How it starts

The opening of the file, as written. The whole thing โ€” 290 lines โ€” stays where its author put it; the contents beside it link to each section on GitHub.

InitX - Project Intelligence & Agent Recruitment System

Usage

/initx [OPTIONS]

๐ŸŽฏ Core Function

Analyze project codebase, detect technology stack, and CREATE NEW PROJECT-SPECIFIC AGENTS tailored to your unique requirements. Saves custom agents to .claude/agents/ and updates project CLAUDE.md.

๐Ÿš€ Command Modes

๐ŸŽฏ Basic Usage

/initx                    # Smart analysis & agent creation
/initx --preview         # Preview mode (no file creation)
/initx --force          # Force overwrite existing agents

๐Ÿ“Š Advanced Options

  • --mode=minimal - Create only essential agents
  • --focus=security - Focus on security-specific agents
  • --exclude=ui - Skip UI/design agents
  • --template=mobile - Use mobile project template
  • --model=inherit - Force all agents to use specified model (inherit/sonnet/opus/haiku)

๐Ÿง  Intelligence Detection Matrix

Technology Stack Recognition

Frontend: vue (*.vue, nuxt.config.js), react (*.jsx, next.config.js), angular
Backend: fastapi (main.py), spring (pom.xml), go (go.mod), node (express/koa)
Mobile: android (*.kt, AndroidManifest.xml), flutter (pubspec.yaml)
Security: reversing (*.apk, frida scripts), hooking (xposed modules)

Project Complexity Assessment

  • Simple: 1-2 custom agents (single stack)
  • Medium: 3-5 custom agents (multi-stack)
  • Complex: 5-8 custom agents (microservices)
  • Enterprise: 8+ custom agents (distributed)

๐Ÿค– Agent Creation Algorithm

Phase 1: Core Stack Agents

Creates NEW specialized agents based on detected stack:

  • vue-{project-name}-developer - Project-specific Vue expert
  • api-{domain}-specialist - Custom API integration expert
  • {database}-data-architect - Database-specific data expert

Phase 2: Domain-Specific Agents

Creates NEW agents for unique project domains:

  • {domain}-business-logic-expert - Business rules specialist
  • {integration}-connector-agent - Third-party integration expert
  • {platform}-deployment-specialist - Platform-specific deployment

Read the full file on GitHub ยท 290 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen ยท 290 lines ยท 0 tokens per session scan A 01069c19fe8e

Subscribe to this mod's changes

initx is a command published in the GitHub repository Toskysun/sub-agents (111 stars, last pushed 7mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,241 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.