# Commands Overview
The Datalab CLI provides commands for document processing, file management, and workflow automation.
---
## Document Processing
| [`convert`](convert.md) | Convert documents to markdown, HTML, JSON, or chunks |
| [`extract`](extract.md) | Extract structured data using a JSON schema |
| [`segment`](segment.md) | Split multi-document PDFs into logical sections |
| [`fill`](fill.md) | Fill PDF or image forms with field data |
| [`track-changes`](track-changes.md) | Extract track changes from Word documents |
| [`create-document`](create-document.md) | Generate DOCX from markdown |
| [`extract-score`](extract-score.md) | Score extraction results with confidence ratings |
---
## File Management
| [`files upload`](files.md#upload) | Upload a file to Datalab storage |
| [`files list`](files.md#list) | List uploaded files |
| [`files get`](files.md#get) | Get file metadata |
| [`files download`](files.md#download) | Download a file |
| [`files delete`](files.md#delete) | Delete a file |
---
## Workflow Management
| [`workflows create`](workflows.md#create) | Create a new workflow |
| [`workflows list`](workflows.md#list) | List all workflows |
| [`workflows get`](workflows.md#get) | Get workflow details |
| [`workflows execute`](workflows.md#execute) | Execute a workflow |
| [`workflows execution`](workflows.md#execution) | Get execution status |
| [`workflows delete`](workflows.md#delete) | Delete a workflow |
| [`workflows step-types`](workflows.md#step-types) | List available step types |
---
## Cache Management
| [`cache stats`](cache.md#stats) | Show cache statistics |
| [`cache clear`](cache.md#clear) | Clear cached responses |
---
## Global Options
These options are available on all commands:
| `--quiet` | `-q` | Suppress all progress output |
| `--verbose` | `-v` | Enable verbose progress output (even when piped) |
| `--help` | `-h` | Print help information |
| `--version` | `-V` | Print version information |
---
## Common Patterns
### Output Redirection
All commands output JSON to stdout:
```bash
# Pipe to jq for processing
# Save to file
datalab convert document.pdf > result.json
# Use --output flag
datalab convert document.pdf --output result.json
```
### Error Handling
Errors are output to stderr. Exit codes:
- `0` - Success
- `1` - Error
```bash
# Check exit code in scripts
if datalab convert document.pdf; then
echo "Success"
else
echo "Failed"
fi
```
### Progress Suppression
For scripts, suppress progress output:
```bash
datalab -q convert document.pdf
```
### Cache Control
```bash
# Skip local cache
datalab convert document.pdf --skip-cache
# Force reprocessing (skip API cache)
datalab convert document.pdf --force
```
---
## Getting Help
```bash
# General help
datalab --help
# Command-specific help
datalab convert --help
datalab extract --help
# Man pages (if installed)
man datalab
man datalab-convert
```