Skip to content

CLI Commands

github-actions[bot] edited this page Oct 16, 2025 · 10 revisions

CLI Commands

Complete reference for all Sylphx Flow CLI commands.

πŸ› οΈ Command Structure

npx github:sylphxltd/flow <command> [subcommand] [options]

πŸ“‹ Core Commands

flow init - Initialize Project

Initialize your project with Sylphx Flow development agents and MCP tools.

Syntax

npx github:sylphxltd/flow init [options]

Options

  • --agent <type> - Force specific agent (opencode, cursor, kilocode, roocode)
  • --verbose - Show detailed output
  • --dry-run - Show what would be done without making changes
  • --clear - Clear obsolete items before processing
  • --no-mcp - Skip MCP tools installation

Examples

# Default initialization
npx github:sylphxltd/flow init

# Preview changes
npx github:sylphxltd/flow init --dry-run

# Initialize without MCP tools
npx github:sylphxltd/flow init --no-mcp

# Verbose output
npx github:sylphxltd/flow init --verbose

# Clear existing setup first
npx github:sylphxltd/flow init --clear

flow memory - Manage Memory Database

Manage the Sylphx Flow memory database directly from the command line.

Syntax

npx github:sylphxltd/flow memory [subcommand] [options]

Subcommands

memory stats - Show Database Statistics
npx github:sylphxltd/flow memory stats

Output:

πŸ“Š Memory Statistics
==================
Total Entries: 15
Namespaces: 3

Namespaces:
  β€’ default: 5 entries
  β€’ user: 8 entries
  β€’ project: 2 entries

Oldest Entry: 16/10/2024, 17:00:00
Newest Entry: 16/10/2024, 17:03:20

πŸ“ Database: .sylphx-flow/memory.db
memory list - List Memory Entries
npx github:sylphxltd/flow memory list [options]

Options:

  • --namespace <name> - Filter by namespace
  • --limit <number> - Limit number of entries (default: 50)

Examples:

# List all entries
npx github:sylphxltd/flow memory list

# List specific namespace
npx github:sylphxltd/flow memory list --namespace "user"

# Limit results
npx github:sylphxltd/flow memory list --limit 10
memory search - Search Memory Entries
npx github:sylphxltd/flow memory search --pattern <pattern> [options]

Options:

  • --pattern <pattern> - Search pattern (supports * wildcards) [REQUIRED]
  • --namespace <name> - Filter by namespace

Examples:

# Search for theme-related entries
npx github:sylphxltd/flow memory search --pattern "*theme*"

# Search within namespace
npx github:sylphxltd/flow memory search --pattern "config/*" --namespace "project"

# Exact match
npx github:sylphxltd/flow memory search --pattern "user-settings"
memory delete - Delete Memory Entry
npx github:sylphxltd/flow memory delete --key <key> [options]

Options:

  • --key <key> - Memory key to delete [REQUIRED]
  • --namespace <name> - Namespace (default: default)

Examples:

# Delete from default namespace
npx github:sylphxltd/flow memory delete --key "old-data"

# Delete from specific namespace
npx github:sylphxltd/flow memory delete --key "temp-file" --namespace "cache"
memory clear - Clear Memory Entries
npx github:sylphxltd/flow memory clear [options]

Options:

  • --namespace <name> - Clear specific namespace (optional)
  • --confirm - Confirm the clear operation [REQUIRED]

Examples:

# Clear specific namespace
npx github:sylphxltd/flow memory clear --namespace "temp" --confirm

# Clear all data
npx github:sylphxltd/flow memory clear --confirm
memory tui - Launch Interactive TUI
npx github:sylphxltd/flow memory tui

Note: TUI is coming soon. Currently shows usage information.

flow mcp - Manage MCP Tools

Manage MCP (Model Context Protocol) tools and servers.

Syntax

npx github:sylphxltd/flow mcp [subcommand] [options]

Subcommands

mcp start - Start MCP Server
npx github:sylphxltd/flow mcp start

Starts the Sylphx Flow MCP server for AI agent integration.

mcp install - Install MCP Tools
npx github:sylphxltd/flow mcp install [servers...] [options]

Arguments:

  • servers... - MCP tools to install (memory, everything, gpt-image, perplexity, context7, gemini-search)

Options:

  • --all - Install all available MCP tools
  • --dry-run - Show what would be done without making changes

Examples:

# Install specific tools
npx github:sylphxltd/flow mcp install memory everything

# Install all tools
npx github:sylphxltd/flow mcp install --all

# Preview installation
npx github:sylphxltd/flow mcp install --all --dry-run
mcp list - List Available MCP Tools
npx github:sylphxltd/flow mcp list

Output:

πŸ”§ Available MCP Tools:
====================
memory           - Agent coordination & memory
everything       - Filesystem, web, git tools
gpt-image-1-mcp  - GPT image generation
perplexity-ask   - Perplexity search
gemini-google-search - Google search via Gemini
context7         - Context management
mcp config - Configure API Keys
npx github:sylphxltd/flow mcp config <server>

Arguments:

  • server - MCP server to configure (gpt-image, perplexity, gemini-search)

Examples:

# Configure GPT Image tool
npx github:sylphxltd/flow mcp config gpt-image

# Configure Perplexity tool
npx github:sylphxltd/flow mcp config perplexity

# Configure Gemini Search tool
npx github:sylphxltd/flow mcp config gemini-search

flow sync - Legacy Sync [DEPRECATED]

⚠️ DEPRECATED: Use flow init instead. Kept for backward compatibility.

Syntax

npx github:sylphxltd/flow sync [options]

Options

  • --agent <type> - Force specific agent (cursor, kilocode, roocode)
  • --verbose - Show detailed output
  • --dry-run - Show what would be done without making changes
  • --clear - Clear obsolete items before processing

Examples

# Legacy usage (not recommended)
npx github:sylphxltd/flow sync --agent=cursor
npx github:sylphxltd/flow sync --dry-run

πŸ”§ Global Options

These options can be used with any command:

  • --help, -h - Show help for command
  • --version, -v - Show version number

πŸ“ Output Formats

Success Messages

βœ… Operation completed successfully
βœ… Memory entry deleted: default:test-key
βœ… MCP tools installed

Error Messages

❌ Error: Invalid option
❌ Memory entry not found: default:missing-key
❌ Please use --confirm to clear memory entries

Warning Messages

⚠️ WARNING: The "sync" command is deprecated
⚠️ Database file not found, creating new one

Info Messages

ℹ️ Database: .sylphx-flow/memory.db
ℹ️ Found 15 entries
ℹ️ No changes required

🎯 Common Workflows

1. Complete Setup

# Initialize project
npx github:sylphxltd/flow init

# Check memory system
npx github:sylphxltd/flow memory stats

# Start MCP server
npx github:sylphxltd/flow mcp start

2. Memory Management

# Check what's stored
npx github:sylphxltd/flow memory list

# Search for specific data
npx github:sylphxltd/flow memory search --pattern "*config*"

# Clean up old data
npx github:sylphxltd/flow memory clear --namespace "temp" --confirm

3. MCP Tool Management

# Install all MCP tools
npx github:sylphxltd/flow mcp install --all

# Configure API keys
npx github:sylphxltd/flow mcp config gpt-image

# List available tools
npx github:sylphxltd/flow mcp list

4. Troubleshooting

# Check system status
npx github:sylphxltd/flow memory stats

# Test with dry run
npx github:sylphxltd/flow init --dry-run

# Verbose output for debugging
npx github:sylphxltd/flow init --verbose

πŸ› Error Codes

Error Code Description Solution
INVALID_OPTION Unknown command option Check --help for valid options
FILE_NOT_FOUND Database or config file missing Run flow init to create
PERMISSION_DENIED Insufficient file permissions Check directory permissions
INVALID_JSON Corrupted JSON file Restore from backup or reinitialize
NETWORK_ERROR Failed to download tools Check internet connection
API_KEY_MISSING Required API key not configured Use flow mcp config <server>

Related: Memory System, MCP Tools, Installation

Clone this wiki locally