Skip to content

Commands Reference

Complete reference for all clinvk CLI commands.

Synopsis

clinvk [global-flags] [prompt]
clinvk [command] [subcommand] [flags]

Command Overview

Command Description Common Use
[prompt] Execute a prompt (default command) Daily AI tasks
resume Resume a previous session Continue conversations
sessions Manage sessions List, show, delete sessions
config Manage configuration View or change settings
parallel Execute tasks in parallel Run multiple tasks
compare Compare backend responses Evaluate different AIs
chain Execute prompt chain Multi-step workflows
mcp Start MCP server MCP integrations
serve Start HTTP API server Application integration
version Show version information Check installed version
help Show help Get command help

Global Flags

These flags work with all commands:

Flag Short Type Default Description
--backend -b string claude AI backend to use
--model -m string Model to use
--workdir -w string Working directory
--output-format -o string json Output format
--config string Config file path
--dry-run bool false Show command only
--ephemeral bool false Stateless mode
--help -h Show help

Prompt-Specific Flags

These flags work only with the default prompt command:

Flag Short Type Default Description
--continue -c bool false Continue the most recent session

Flag Details

--backend, -b

Select the AI backend to use:

clinvk --backend claude "prompt"
clinvk -b codex "prompt"
clinvk -b gemini "prompt"

Available backends: claude, codex, gemini

--model, -m

Override the default model for the selected backend:

clinvk -b claude -m claude-sonnet-4-20250514 "prompt"
clinvk -b codex -m o3-mini "prompt"

--workdir, -w

Set the working directory for the AI backend:

clinvk --workdir /path/to/project "analyze this codebase"

--output-format, -o

Control output format:

Value Description
text Plain text
json Structured JSON (default)
stream-json Streaming JSON events
clinvk --output-format json "prompt"
clinvk -o stream-json "prompt"

--config

Use a custom configuration file:

clinvk --config /path/to/config.yaml "prompt"

--dry-run

Show the command that would be executed without running it:

clinvk --dry-run "implement feature X"
# Output: Would execute: claude --model claude-opus-4-5-20251101 "implement feature X"

--ephemeral

Run in stateless mode without creating a session:

clinvk --ephemeral "quick question"

Command Categories

Core Commands

Commands for everyday use:

  • [prompt] - Execute prompts
  • resume - Continue sessions
  • sessions - Manage sessions

Configuration Commands

Commands for managing settings:

  • config - View and modify configuration

Execution Commands

Commands for advanced execution patterns:

  • parallel - Run multiple tasks concurrently
  • chain - Execute sequential pipelines
  • compare - Compare multiple backends

Server Commands

Commands for running the HTTP API:

  • mcp - Start the MCP server
  • serve - Start the API server

Usage Examples

Basic Usage

# Execute a prompt
clinvk "fix the bug in auth.go"

# Specify backend
clinvk -b codex "implement feature"

# Specify model
clinvk -b claude -m claude-sonnet-4-20250514 "quick review"

Session Management

# List sessions
clinvk sessions list

# Show session details
clinvk sessions show abc123

# Resume last session
clinvk resume --last

# Delete old sessions
clinvk sessions clean --older-than 30d

Configuration

# Show current config
clinvk config show

# Set a value
clinvk config set default_backend codex

Advanced Execution

# Run tasks in parallel
clinvk parallel --file tasks.json

# Compare backends
clinvk compare --all-backends "explain this code"

# Execute a chain
clinvk chain --file pipeline.json

Server

# Start server
clinvk serve --port 8080

Exit Codes

All commands return exit codes:

Code Description
0 Success
1 General error
2 Backend not available
3 Invalid configuration
4 Session error

See Exit Codes for complete reference.

Getting Help

Get help for any command:

# General help
clinvk --help

# Command help
clinvk [command] --help

# Example
clinvk parallel --help

See Also