CLI Reference
Complete reference for all Semantiq CLI commands.
semantiq init
Initialize Semantiq for Claude Code. Creates index and configures MCP settings automatically.
1semantiq init [PATH] [OPTIONS]23Arguments:4 [PATH] Directory to initialize (default: current directory)56Options:7 -v, --verbose Show detailed output8 -h, --help Print helpExamples
1# Initialize in current directory2semantiq init34# Initialize a specific project5semantiq init /path/to/project67# Initialize with verbose output8semantiq init . --verbosesemantiq init-cursor
Initialize Semantiq for Cursor/VS Code. Creates index and generates .cursor/mcp.json configuration.
1semantiq init-cursor [PATH] [OPTIONS]23Arguments:4 [PATH] Directory to initialize (default: current directory)56Options:7 -v, --verbose Show detailed output8 -h, --help Print helpExamples
1# Initialize for Cursor in current directory2semantiq init-cursor34# Initialize a specific project for Cursor5semantiq init-cursor /path/to/projectsemantiq stats
Display statistics about the current index (files, symbols, size, etc.).
1semantiq stats [OPTIONS]23Options:4 --json Output results as JSON5 -h, --help Print helpExamples
1# Show index statistics2semantiq stats34# Output as JSON5semantiq stats --jsonsemantiq index
Index a directory to create or update the semantic database.
1semantiq index [PATH] [OPTIONS]23Arguments:4 [PATH] Directory to index (default: current directory)56Options:7 -v, --verbose Show detailed output8 -f, --force Force re-index all files9 --exclude Patterns to exclude (can be repeated)10 -h, --help Print helpExamples
1# Index current directory2semantiq index34# Index with verbose output5semantiq index . --verbose67# Force re-index everything8semantiq index --force910# Exclude specific directories11semantiq index --exclude node_modules --exclude distsemantiq search
Search for code patterns, symbols, or text in the indexed codebase.
1semantiq search <QUERY> [OPTIONS]23Arguments:4 <QUERY> Search query (supports natural language)56Options:7 -l, --limit Maximum number of results (default: 20)8 --min-score Minimum similarity score 0.0-1.0 (default: 0.35)9 --file-type Filter by file type (e.g., ts, py, rs)10 --symbol-kind Filter by symbol kind (function, class, etc.)11 --json Output results as JSON12 -h, --help Print helpExamples
1# Search for a pattern2semantiq search "authentication"34# Search with limit and min score5semantiq search "handler" --limit 5 --min-score 0.567# Filter by file type8semantiq search "config" --file-type ts910# Filter by symbol kind11semantiq search "User" --symbol-kind class1213# Output as JSON14semantiq search "database" --jsonsemantiq find-refs
Find all references to a symbol including definitions and usages.
1semantiq find-refs <SYMBOL> [OPTIONS]23Arguments:4 <SYMBOL> Symbol name to find references for56Options:7 -l, --limit Maximum number of results (default: 50)8 --json Output results as JSON9 -h, --help Print helpExamples
1# Find all references to a function2semantiq find-refs handleRequest34# Find references to a class5semantiq find-refs UserService67# Output as JSON8semantiq find-refs Config --jsonsemantiq deps
Analyze the dependency graph for a file.
1semantiq deps <FILE> [OPTIONS]23Arguments:4 <FILE> File path to analyze56Options:7 --imports Show only imports (what this file depends on)8 --dependents Show only dependents (what depends on this file)9 --depth Maximum depth for transitive dependencies10 --json Output results as JSON11 -h, --help Print helpExamples
1# Analyze a file's dependencies2semantiq deps src/auth/handler.ts34# Show only imports5semantiq deps src/index.ts --imports67# Show only dependents8semantiq deps src/utils.ts --dependentssemantiq explain
Get detailed explanation of a symbol including definition, docs, and usage patterns.
1semantiq explain <SYMBOL> [OPTIONS]23Arguments:4 <SYMBOL> Symbol name to explain56Options:7 --json Output results as JSON8 -h, --help Print helpExamples
1# Explain a function2semantiq explain handleAuth34# Explain a class5semantiq explain DatabaseConnectionsemantiq serve
Start Semantiq as an MCP server for integration with AI assistants.
1semantiq serve [OPTIONS]23Options:4 --stdio Use stdio for MCP communication (default)5 --port Use HTTP transport on specified port6 -h, --help Print helpExamples
1# Start MCP server (stdio)2semantiq serve34# Start with HTTP transport5semantiq serve --port 8080See Also
- Usage Guide - Practical examples for each tool
- MCP Integration - Configure with AI assistants