CLI Usage¶
urimai is operated entirely through the urim command-line interface. Every
interaction — from initial setup to chatting with your data — happens through
subcommands documented below.
Typical workflow¶
A typical session looks like this:
urim setup # one-time: configure provider and API key
urim init sales.db # register a database
urim chat sales # ask questions in plain English
urim export sales # export a data dictionary when you're done
Command overview¶
Command |
Description |
|---|---|
|
Run the setup wizard |
|
Register a SQLite database or CSV file |
|
List registered databases |
|
Start interactive chat with a database |
|
Re-sync schema metadata |
|
View or modify settings |
|
Export data dictionary |
Global option¶
--model <provider>Override the default LLM provider for a single invocation (e.g.
urim chat mydb --model openai).
urim setup¶
Run the interactive setup wizard.
urim setup
Configures your API provider, API key, and user name. Settings are stored in
~/.urimai/config.toml and keys in the system keyring.
You only need to run this once. To change settings later, use urim config.
urim init¶
Register a new database.
urim init <path> [OPTIONS]
Option |
Description |
|---|---|
|
Custom name (default: filename stem) |
|
Table name for CSV import (default: LLM-suggested) |
|
CSV delimiter (default: |
|
CSV file encoding (default: |
When you register a database, urimai:
Extracts the schema (tables, columns, types).
Uses the LLM to enrich column descriptions.
Profiles each column (min, max, nulls, distribution).
Runs data-quality checks.
Examples¶
# Register a SQLite database
urim init sales.db
# Register with a custom name
urim init sales.db --name quarterly_sales
# Import a CSV file (auto-converted to SQLite)
urim init report.csv --delimiter ";" --encoding latin-1
urim list¶
List all registered databases.
urim list
Displays each database’s name, file path, and last sync time.
urim chat¶
Start an interactive chat session with a registered database.
urim chat <db_name>
Inside the session, type questions in plain English. urimai generates SQL,
executes it, and explains the results. Type exit or press Ctrl+D to end
the session.
Example¶
urim chat sales
You: What were the top 5 products by revenue last quarter?
urimai will select the relevant tables, write a SQL query, run it, and present the results with an explanation.
urim sync¶
Re-sync schema metadata for a database whose structure has changed.
urim sync <db_name>
This re-extracts all table schemas and re-runs LLM enrichment, profiling, and quality checks. Useful after you’ve added tables or columns to the underlying database.
urim config¶
View or modify configuration.
urim config [KEY] [VALUE] [OPTIONS]
Option |
Description |
|---|---|
|
Reset configuration to defaults |
|
Show config and data directory paths |
Examples¶
urim config # show all settings
urim config provider.default openai # change default provider
urim config settings.query_timeout 120 # set query timeout
urim config --reset # reset to defaults
urim config --path # show directory paths
See Configuration for the full list of settings.
urim export¶
Export a data dictionary for a registered database.
urim export <db_name> [OPTIONS]
Option |
Description |
|---|---|
|
Output format: |
|
Output file path |
|
Include sample data rows |
|
Include column profile stats (default: on) |
|
Include quality report (default: on) |
Examples¶
urim export mydb
urim export mydb -f markdown -o docs/mydb.md
urim export mydb --include-sample-data --no-include-quality