Commands
Complete reference for CoreViz CLI commands
CLI Commands
The CoreViz CLI provides powerful commands for working with images from the command line. All commands support a --help flag for detailed usage information.
AI Features
Describe
Generate detailed descriptions and captions for images using AI.
npx @coreviz/cli describe path/to/image.jpgUse Cases:
- Generate alt text for accessibility
- Create image metadata
- Understand image content programmatically
- Generate captions for social media
Example Output:
A beautiful sunset over a mountain landscape with vibrant orange and pink colors in the sky.Edit
Edit images with natural language prompts using AI.
npx @coreviz/cli edit path/to/image.jpg "make it cyberpunk style"Options:
<prompt>: The editing instruction (required)--output <path>: Specify output file path (optional)--quiet: Suppress UI output, return only file path
Use Cases:
- Style transfer
- Image transformation
- Creative editing
- Batch processing with scripts
Example:
npx @coreviz/cli edit photo.jpg "make it look like a vintage film photo" --output vintage-photo.jpgTag
Generate tags or classify images using AI.
Basic Tagging:
npx @coreviz/cli tag path/to/image.jpg "objects in the image"Classification with Choices:
npx @coreviz/cli tag path/to/image.jpg --choices "receipt,invoice,document" --singleOptions:
--choices <list>: Comma-separated list of classification options--single: Return only the best match (for classification)--mode <local|api>: Use local processing or cloud API (default: api)
Use Cases:
- Automatic image tagging
- Document classification
- Content moderation
- Organizing photo libraries
Examples:
# Tag with custom prompt
npx @coreviz/cli tag image.jpg "identify all animals"
# Classify document type
npx @coreviz/cli tag doc.jpg --choices "receipt,invoice,contract,other" --single
# Local processing (offline)
npx @coreviz/cli tag image.jpg "objects" --mode localSearch
Search through local images using natural language queries.
npx @coreviz/cli search "a person wearing a red t-shirt"How It Works:
- Automatically indexes images in the current directory
- Creates a
.index.dbfile for fast subsequent searches - Returns top matches ranked by relevance
Options:
--mode <local|api>: Use local embeddings or cloud API (default: local)--limit <number>: Maximum number of results (default: 10)--directory <path>: Search in specific directory (default: current directory)
Use Cases:
- Finding specific photos in large collections
- Organizing photo libraries
- Content discovery
- Similarity search
Examples:
# Search current directory
npx @coreviz/cli search "sunset over ocean"
# Search specific directory
npx @coreviz/cli search "dog playing" --directory ~/Photos
# Use cloud API for better results
npx @coreviz/cli search "wedding ceremony" --mode api
# Limit results
npx @coreviz/cli search "mountain landscape" --limit 5Authentication
Login
Authenticate with CoreViz using device authorization.
npx @coreviz/cli loginThis will open a browser window or provide a code for device authorization. Once authenticated, you can use cloud features that require authentication.
Logout
Sign out from your CoreViz account.
npx @coreviz/cli logoutWhoami
Check your current authentication status.
npx @coreviz/cli whoamiDisplays your authenticated user information or indicates if you're not logged in.
Scripting & Automation
All commands support a --quiet flag that suppresses UI output and returns only raw results. This is perfect for scripting and automation.
Example:
# Get only the file path of edited image
EDITED_FILE=$(npx @coreviz/cli edit image.jpg "prompt" --quiet)
echo "Edited image saved to: $EDITED_FILE"Use Cases:
- Batch processing scripts
- CI/CD pipelines
- Automated workflows
- Integration with other tools
Command Options
Most commands support these common options:
--help: Show detailed help information--quiet: Suppress UI output, return only raw results--version: Show CLI version
Getting Help
Get help for any command:
npx @coreviz/cli [command] --helpFor example:
npx @coreviz/cli search --help
npx @coreviz/cli edit --helpNext Steps
- Authentication: Learn about authentication and cloud features
- Installation: Review installation instructions