Skip to content

solarhell/nexus-cli

ย 
ย 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Nexus CLI

Nexus CLI Logo

Smart Routing, Perfect Match.

ไธญๆ–‡ๆ–‡ๆกฃ

Intelligent Task Router for Claude Code - Automatically route development tasks to the most suitable AI executor (Claude, Gemini, or Codex) based on task characteristics.

Features

  • Smart Task Routing: AI-powered analysis to select the optimal executor for each task
  • Multi-Executor Support: Seamlessly integrate Claude, Gemini CLI, and Codex CLI via PAL MCP
  • Structured Workflow: Spec-first approach with requirements โ†’ design โ†’ implementation phases
  • Batch Execution: Atomic task decomposition (โ‰ค5 min each) with parallel execution
  • Real-time Progress: TodoWrite integration for live progress tracking
  • AI Code Review: Intelligent code review powered by PAL MCP

Platform Support

Platform Status
macOS โœ… Fully Supported
Windows ๐Ÿšง Coming This Week
Linux ๐Ÿ”œ Planned

Requirements

  • Claude Code installed and configured
  • PAL MCP Server for Gemini/Codex CLI integration (optional, enables multi-executor routing)

Installation

# Clone the repository
git clone https://github.com/CoderMageFox/nexus-cli.git
cd nexus-cli

# Run the installer
./install-nexus-skill.sh

The installer will:

  1. Register Nexus as a Claude Code skill at ~/.claude/commands/nexus.md
  2. Create default configuration file .nexus-config.yaml
  3. Check for optional dependencies (PAL MCP, Gemini CLI, Codex CLI)

PAL MCP Configuration (Optional)

To enable multi-executor routing, add PAL MCP to ~/.claude.json:

{
  "mcpServers": {
    "pal": {
      "command": "uvx",
      "args": ["--from", "git+https://github.com/BeehiveInnovations/pal-mcp-server.git", "pal-mcp-server"],
      "env": {
        "GEMINI_API_KEY": "your-gemini-api-key"
      }
    }
  }
}

Installation Guide for AI Assistants

Note: This section is intended for AI coding assistants (Claude Code, Cursor, etc.) to help users install Nexus CLI.

Copy & Paste to Your AI Assistant

Simply copy the text below and send it to Claude Code, Codex, or any AI coding assistant:

English:

Help me install Nexus CLI.

For quick install, run:
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/CoderMageFox/nexus-cli/main/commands/nexus.md -o ~/.claude/commands/nexus.md

For full install with dependency check, run:
cd ~/.claude && git clone https://github.com/CoderMageFox/nexus-cli.git skills/nexus-cli && ~/.claude/skills/nexus-cli/install-nexus-skill.sh

After installation, verify with: ls ~/.claude/commands/nexus.md

ไธญๆ–‡:

ๅธฎๆˆ‘ๅฎ‰่ฃ… Nexus CLIใ€‚

ๅฟซ้€Ÿๅฎ‰่ฃ…๏ผŒ่ฟ่กŒ๏ผš
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/CoderMageFox/nexus-cli/main/commands/nexus.md -o ~/.claude/commands/nexus.md

ๅฎŒๆ•ดๅฎ‰่ฃ…๏ผˆๅŒ…ๅซไพ่ต–ๆฃ€ๆŸฅ๏ผ‰๏ผŒ่ฟ่กŒ๏ผš
cd ~/.claude && git clone https://github.com/CoderMageFox/nexus-cli.git skills/nexus-cli && ~/.claude/skills/nexus-cli/install-nexus-skill.sh

ๅฎ‰่ฃ…ๅŽ้ชŒ่ฏ๏ผšls ~/.claude/commands/nexus.md

Method 1: One-Line Install (Fastest)

Download the skill file directly - no cloning required:

mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/CoderMageFox/nexus-cli/main/commands/nexus.md -o ~/.claude/commands/nexus.md

โš ๏ธ Note: This method only installs the core skill file. Dependencies (PAL MCP, Gemini CLI, Codex CLI) must be installed separately if needed.

Method 2: Full Install with Configuration (Recommended)

Includes interactive configuration wizard and automatic dependency installation:

cd ~/.claude && git clone https://github.com/CoderMageFox/nexus-cli.git skills/nexus-cli && ~/.claude/skills/nexus-cli/install-nexus-skill.sh

โœ… This method will:

  • Install the Nexus skill
  • Check and install missing dependencies (PAL MCP, Gemini CLI, Codex CLI, jq, uv)
  • Generate customized .nexus-config.yaml
  • Configure quality gates and executor preferences

Comparison

Feature One-Line Install Full Install
Speed โšก Fastest ๐Ÿข ~2 min
Dependencies โŒ Manual โœ… Auto-install
Configuration โŒ Default only โœ… Interactive wizard
Best for Quick start, CI/CD First-time setup

Step-by-Step for AI Assistants

  1. Check Platform: Verify user is on macOS (Windows support coming soon)

    uname -s  # Should return "Darwin" for macOS
  2. Choose Install Method:

    • New users โ†’ Use Full Install (Method 2)
    • Experienced users / just need the skill โ†’ Use One-Line Install (Method 1)
  3. Verify Installation:

    ls -la ~/.claude/commands/nexus.md  # Should exist after installation
  4. Check Dependencies (if using One-Line Install):

    # Optional: Install PAL MCP for multi-executor support
    # Add to ~/.claude.json under mcpServers

Post-Installation: The /nexus command will be available in Claude Code after restarting the session.

Usage

In Claude Code, invoke Nexus with:

/nexus <your task description>

Examples

# Full workflow with spec generation
/nexus Create a user authentication system with JWT tokens

# Skip spec phase for simple tasks
/nexus Create a hello world function --skip-spec

# Frontend task (routes to Gemini)
/nexus Build a responsive login form component

# Backend task (routes to Codex)
/nexus Implement REST API endpoints for user management

Workflow

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚              Phase 0: PAL MCP Availability Check            โ”‚
โ”‚         Available โ†’ Normal Mode | Unavailable โ†’ Claude-Only โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                              โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                    SPEC Flow (Phase 1-3)                    โ”‚
โ”‚  Phase 1: Requirements (EARS format)                        โ”‚
โ”‚  Phase 2: Design Document                                   โ”‚
โ”‚  Phase 3: Task Breakdown (Batch format)                     โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                              โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                 Execution Flow (Phase 4-5)                  โ”‚
โ”‚  Phase 4: TodoWrite Init + User Confirmation                โ”‚
โ”‚  Phase 5: Batch Execution Loop                              โ”‚
โ”‚           โ”œโ”€ Execute tasks in parallel per batch            โ”‚
โ”‚           โ”œโ”€ Update TodoWrite immediately after each batch  โ”‚
โ”‚           โ””โ”€ Route: Claudeโ†’Task, Gemini/Codexโ†’PAL clink     โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                              โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚              Quality Gates (Phase 6) - Optional             โ”‚
โ”‚                     AI Code Review                          โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                              โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚              Completion Options (Phase 7)                   โ”‚
โ”‚         Acceptance Confirmation โ†’ Documentation             โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Executor Selection

Executor Best For Icon
Claude Architecture design, deep analysis, security review, complex reasoning ๐Ÿง 
Gemini Frontend UI, algorithms, web search, creative tasks ๐Ÿ’Ž
Codex Backend APIs, databases, server-side logic ๐Ÿ”ท

Configuration

Edit .nexus-config.yaml in your project root:

# Language: auto, zh-CN, en-US
language: auto

# Executor routing rules
routing:
  default_executor: claude
  rules:
    - pattern: "**/components/**"
      executor: gemini
      description: "React/Vue components"
    - pattern: "**/api/**"
      executor: codex
      description: "API endpoints"

# Execution settings
execution:
  max_parallel_tasks: 5
  task_timeout_minutes: 10
  batch_timeout_minutes: 30

# Quality gates (AI-powered)
quality_gates:
  enabled: true
  gates:
    review:
      enabled: true
      focus:
        - security
        - performance
        - quality

Mandatory Constraints

Constraint Requirement
FORCE_PAL_CHECK Must check PAL MCP availability before routing to Gemini/Codex
FORCE_SPEC_FIRST Must complete Spec flow before execution (unless --skip-spec)
FORCE_ATOMIC_TASKS Each task must be โ‰ค5 minutes
FORCE_BATCH_GROUPING Tasks must be grouped by dependencies
FORCE_BATCH_TODOWRITE Must update TodoWrite immediately after each batch
FORCE_USER_CONFIRMATION Must get user confirmation before execution

Scripts

Script Description
./install-nexus-skill.sh Install Nexus CLI
./uninstall-nexus.sh Uninstall Nexus CLI
./update-nexus.sh Update to latest version

Install Options

./install-nexus-skill.sh [options]

Options:
  --quick         Skip dependency checks
  --check-deps    Only check dependencies, don't install
  --help          Show help message

Project Structure

nexus-cli/
โ”œโ”€โ”€ commands/
โ”‚   โ””โ”€โ”€ nexus.md           # Main skill definition
โ”œโ”€โ”€ lib/                   # Library modules
โ”œโ”€โ”€ locales/               # i18n translations (en-US, zh-CN)
โ”œโ”€โ”€ templates/             # Document templates
โ”œโ”€โ”€ tests/                 # Test files
โ”œโ”€โ”€ install-nexus-skill.sh # Installer
โ”œโ”€โ”€ uninstall-nexus.sh     # Uninstaller
โ”œโ”€โ”€ update-nexus.sh        # Updater
โ”œโ”€โ”€ .nexus-config.yaml     # Configuration template
โ””โ”€โ”€ VERSION                # Version file

License

MIT License

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Related Resources

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 60.0%
  • Shell 40.0%