Slash Commands
Slash commands provide quick access to SII CLI features during interactive sessions. Commands can be built-in (provided by SII CLI) or custom (user-defined).
Built-in Slash Commands
Session Management
| Command | Purpose |
|---|---|
/help or /? | Display help information and available commands |
/new | Start a new conversation session (ends current session and preserves history) |
/clear | Clear the screen and start a new session (alias for /new) |
/quit or /exit | Exit the interactive session |
/compress or /summarize | Compress context by replacing it with a summary |
Chat History
| Command | Purpose |
|---|---|
/chat list | List saved conversation checkpoints |
/chat save <tag> | Save the current conversation as a checkpoint |
/chat resume <tag> or /chat load <tag> | Resume a conversation from a checkpoint |
Configuration
| Command | Purpose |
|---|---|
/config init [--global|-g] [--overwrite|--merge] | Initialize configuration file |
/config wizard [--global|-g] | Interactive configuration wizard |
/config quick-start <scenario> | Quick configuration for common scenarios (development, production, minimal) |
/config template | Show complete configuration template with all available options |
/config list [scope] [category] | Show current configuration settings |
/config get <key> [scope] | Get a specific configuration value |
/config set <key> <value> [scope] | Set a configuration value |
/config reset [scope] | Reset configuration to defaults |
/config path | Show configuration file paths |
/config help <key> | Show detailed help for a specific configuration key |
/config validate | Validate current configuration and provide optimization suggestions |
/config status | Check configuration status and get recommendations |
/config env-status | Check SII environment variables status |
/config env-guide | Show environment variables setup guide |
/config migrate [--auto] | Show migration guide from legacy environment variables to SII_ prefixed ones |
/config persist | Persist current SII environment variables to shell configuration file |
/config auth-status | Check authentication status and connection health |
/config migrate-to-env | Migrate environment variables from shell config to .env file |
/config env-file-status | Check .env file status and environment variable configuration |
/config reload-env | Reload .env file and sync to current process environment variables |
/config sync-env | Force sync all SII environment variables to current process |
/config migrate-to-global | Migrate existing configuration to global config directory (~/.sii/.env) |
/config config-status | Show detailed configuration status and hierarchy information |
/config ide-port [status|set <port>|migrate] | Manage IDE port configuration |
Model Management
| Command | Purpose |
|---|---|
/model | Show current model |
/model <model_name> | Switch to specified model (e.g., openai/gpt-4o, anthropic/claude-3.5-sonnet, gemini-2.0-flash) |
Memory Management
| Command | Purpose |
|---|---|
/memory show | Show the current memory contents |
/memory add <text> | Add content to the memory |
/memory refresh | Refresh the memory from source files |
Prompt Management
| Command | Purpose |
|---|---|
/prompt show | Display the prompt currently used by this session |
/prompt enable | Enable the user prompt file for this session |
/prompt disable | Disable the user prompt file and revert to the default prompt |
/prompt edit | Open the prompt file in your default editor |
/prompt set --file <path> | Set a custom prompt file for this session |
/prompt reset | Reset to the default prompt |
MCP (Model Context Protocol)
| Command | Purpose |
|---|---|
/mcp list | List all configured MCP servers |
/mcp status [server_name] | Show status of MCP servers |
/mcp install <preset> [options] | Install an MCP server from preset |
/mcp remove <server_name> | Remove an MCP server configuration |
/mcp presets | List available MCP server presets |
/mcp preset <name> | Show details of a specific preset |
/mcp tools [server_name] | List tools provided by MCP servers |
/mcp prompts [server_name] | List prompts provided by MCP servers |
Remote Sessions
| Command | Purpose |
|---|---|
/connect | Create a SII session and connect via WebSocket |
/remote status | Show remote handle status |
/remote start [handle] | Start a remote handle |
/remote stop | Stop the remote handle |
/remote qr | Display QR code for remote connection |
Statistics & Information
| Command | Purpose |
|---|---|
/stats | Check session statistics |
/stats model | Show model-specific usage statistics |
/stats tools | Show tool-specific usage statistics |
/about | Show version and system information |
/tools | List available tools and their status |
Workspace Initialization
| Command | Purpose |
|---|---|
/init [--json|--scan-only|--file <path>] | AI-guided workspace exploration and snapshot |
Options:
--json: Output snapshot in JSON format--scan-onlyor--summary: Show summary without AI analysis--file <path>: Specify target file for notes (default: SII.md)
UI & Display
| Command | Purpose |
|---|---|
/theme | Change the UI theme |
/editor | Configure the default editor |
/privacy | View and update privacy settings |
/auth | Change the authentication method |
/vim | Enter vim mode for alternating insert and command modes |
/corgi | Toggle corgi mode (easter egg) |
Utilities
| Command | Purpose |
|---|---|
/copy | Copy the last response to clipboard |
/bug | Report a bug (sends conversation to developers) |
/docs | Open documentation in browser |
/extensions | Manage SII CLI extensions |
/ide | Manage IDE integration settings |
/restore | Restore a previous session |
/resume | Resume the most recent session (shortcut for /restore) |
/upload | Configure trajectory upload settings |
/gh-issue | Create a GitHub Issue (requires GitHub MCP server configuration) |
Custom Slash Commands
Custom slash commands allow you to define frequently-used prompts as TOML files that SII CLI can execute. Commands are organized by scope (project-specific or personal).
Syntax
/<command-name> [arguments]Parameters
| Parameter | Description |
|---|---|
<command-name> | Name derived from the TOML filename (without .toml extension) |
[arguments] | Optional arguments passed to the command |
Command Types
Project Commands
Commands stored in your repository and shared with your team.
Location: .sii/commands/
Example - Create the /optimize command:
# Create a project command directory
mkdir -p .sii/commands
# Create a command file
cat > .sii/commands/optimize.toml << 'EOF'
name = "optimize"
description = "Analyze code for performance issues"
prompt = """
Analyze this code for performance issues and suggest optimizations:
- Identify bottlenecks
- Suggest algorithmic improvements
- Recommend caching strategies
"""
EOFPersonal Commands
Commands available across all your projects.
Location: ~/.sii/commands/
Example - Create the /security-review command:
# Create a personal command directory
mkdir -p ~/.sii/commands
# Create a command file
cat > ~/.sii/commands/security-review.toml << 'EOF'
name = "security-review"
description = "Review code for security vulnerabilities"
prompt = """
Review this code for security vulnerabilities:
- Check for injection attacks
- Validate input sanitization
- Review authentication/authorization
- Check for sensitive data exposure
"""
EOFCommand File Format
Custom commands are defined in TOML files with the following structure:
name = "command-name"
description = "Brief description of what the command does"
prompt = """
The prompt text that will be sent to the AI model.
Can be multi-line and include placeholders.
"""
# Optional: Specify allowed arguments
[args]
arg1 = "Description of first argument"
arg2 = "Description of second argument"
# Optional: Command metadata
[metadata]
author = "Your Name"
version = "1.0.0"
tags = ["code-review", "security"]Features
Namespacing
Organize commands in subdirectories for better organization:
.sii/commands/
├── frontend/
│ ├── component.toml
│ └── style.toml
└── backend/
├── api.toml
└── database.tomlCommands are invoked by their filename, not their directory path:
/component- invokes frontend/component.toml/api- invokes backend/api.toml
Arguments
Pass dynamic values to commands:
name = "fix-issue"
description = "Fix a specific issue"
prompt = """
Fix issue #{{ISSUE_NUMBER}} following our coding standards.
Priority: {{PRIORITY}}
"""
[args]
ISSUE_NUMBER = "Issue number to fix"
PRIORITY = "Priority level (high, medium, low)"Usage:
/fix-issue ISSUE_NUMBER=123 PRIORITY=highDiscovery
Custom commands are automatically discovered and loaded when SII CLI starts. They appear in the /help output alongside built-in commands.
To refresh custom commands without restarting:
/memory refreshCommand Completion
Many commands support tab completion for arguments:
/model <TAB>- Shows available models/chat resume <TAB>- Shows saved conversation tags/mcp install <TAB>- Shows available MCP presets
Tips
- Quick Help: Type
/helpor/?to see all available commands - Command History: Use arrow keys to navigate through command history
- Multi-line Input: Press
Shift+Enterfor multi-line input (if terminal supports it) - Aliases: Some commands have shorter aliases (e.g.,
/clear=/new,/?=/help,/resume=/restore) - Tab Completion: Use
Tabkey for command and argument completion - Session Persistence: Use
/chat saveto save important conversations - Custom Commands: Create project-specific commands in
.sii/commands/for team workflows - Quick Resume: Use
/resumeto quickly restore the most recent session without selection - GitHub Integration: Use
/gh-issueto create GitHub Issues directly from CLI (requires GitHub MCP server configuration)
Examples
Basic Session Management
# Start a new session
/new
# Save current conversation
/chat save important-discussion
# Resume a saved conversation
/chat resume important-discussion
# Quick resume the most recent session
/resume
# Restore a previous session (interactive selection)
/restore
# Compress context to save tokens
/compressConfiguration Management
# Initialize project configuration
/config init
# Set API key
/config set api.openaiApiKey "your-api-key"
# Switch model
/model openai/gpt-4o
# Check configuration status
/config statusMemory Management
# Show current memory
/memory show
# Add important information
/memory add "Project uses React 18 with TypeScript"
# Refresh memory from files
/memory refreshMCP Integration
# List available presets
/mcp presets
# Install GitHub MCP server
/mcp install github token=ghp_xxx
# List tools from GitHub server
/mcp tools github
# Check server status
/mcp status
# Create a GitHub Issue using MCP
/gh-issue
# Note: Requires GitHub MCP server to be configured firstWorkspace Initialization
# Initialize workspace with AI guidance
/init
# Get JSON snapshot only
/init --json
# Scan without AI analysis
/init --scan-only
# Use custom target file
/init --file NOTES.mdSee Also
- CLI Reference - Complete CLI options and flags
- Configuration - Configuration file reference
- MCP Integration - Model Context Protocol guide
- Custom Commands - Creating custom slash commands
