|
1 | 1 | --- |
2 | 2 | name: hotdata-cli |
3 | | -description: Use this skill when the user wants to run hotdata CLI commands, query the Hotdata API, list workspaces, list connections, create connections, list tables, manage datasets, execute SQL queries, or interact with the hotdata service. Activate when the user says "run hotdata", "query hotdata", "list workspaces", "list connections", "create a connection", "list tables", "list datasets", "create a dataset", "upload a dataset", "execute a query", or asks you to use the hotdata CLI. |
| 3 | +description: Use this skill when the user wants to run hotdata CLI commands, query the Hotdata API, list workspaces, list connections, create connections, list tables, manage datasets, execute SQL queries, manage saved queries, search tables, manage indexes, or interact with the hotdata service. Activate when the user says "run hotdata", "query hotdata", "list workspaces", "list connections", "create a connection", "list tables", "list datasets", "create a dataset", "upload a dataset", "execute a query", "search a table", "list indexes", "create an index", "list saved queries", "run a saved query", or asks you to use the hotdata CLI. |
4 | 4 | version: 0.1.5 |
5 | 5 | --- |
6 | 6 |
|
@@ -138,11 +138,13 @@ hotdata datasets <dataset_id> [--workspace-id <workspace_id>] [--format table|js |
138 | 138 | hotdata datasets create --label "My Dataset" --file data.csv [--table-name my_dataset] [--workspace-id <workspace_id>] |
139 | 139 | hotdata datasets create --label "My Dataset" --sql "SELECT * FROM ..." [--table-name my_dataset] [--workspace-id <workspace_id>] |
140 | 140 | hotdata datasets create --label "My Dataset" --query-id <saved_query_id> [--table-name my_dataset] [--workspace-id <workspace_id>] |
| 141 | +hotdata datasets create --label "My Dataset" --url "https://example.com/data.parquet" [--table-name my_dataset] [--workspace-id <workspace_id>] |
141 | 142 | ``` |
142 | 143 | - `--file` uploads a local file. Omit to pipe data via stdin: `cat data.csv | hotdata datasets create --label "My Dataset"` |
143 | 144 | - `--sql` creates a dataset from a SQL query result. |
144 | 145 | - `--query-id` creates a dataset from a previously saved query. |
145 | | -- `--file`, `--sql`, and `--query-id` are mutually exclusive. |
| 146 | +- `--url` imports data directly from a URL (supports csv, json, parquet). |
| 147 | +- `--file`, `--sql`, `--query-id`, and `--url` are mutually exclusive. |
146 | 148 | - Format is auto-detected from file extension (`.csv`, `.json`, `.parquet`) or file content. |
147 | 149 | - `--label` is optional when `--file` is provided — defaults to the filename without extension. Required for `--sql` and `--query-id`. |
148 | 150 | - `--table-name` is optional — derived from the label if omitted. |
@@ -176,6 +178,41 @@ hotdata results <result_id> [--workspace-id <workspace_id>] [--format table|json |
176 | 178 | - Query results include a `result-id` in the footer (e.g. `[result-id: rslt...]`). |
177 | 179 | - **Always use this command to retrieve past query results rather than re-running the same query.** Re-running queries wastes resources and may return different results. |
178 | 180 |
|
| 181 | +### Saved Queries |
| 182 | +``` |
| 183 | +hotdata queries list [--limit <int>] [--offset <int>] [--format table|json|yaml] |
| 184 | +hotdata queries <query_id> [--format table|json|yaml] |
| 185 | +hotdata queries create --name "My Query" --sql "SELECT ..." [--description "..."] [--tags "tag1,tag2"] [--format table|json|yaml] |
| 186 | +hotdata queries update <query_id> [--name "New Name"] [--sql "SELECT ..."] [--description "..."] [--tags "tag1,tag2"] [--format table|json|yaml] |
| 187 | +hotdata queries run <query_id> [--format table|json|csv] |
| 188 | +``` |
| 189 | +- `list` shows saved queries with name, description, tags, and version. |
| 190 | +- View a query by ID to see its formatted and syntax-highlighted SQL. |
| 191 | +- `create` requires `--name` and `--sql`. Tags are comma-separated. |
| 192 | +- `update` accepts any combination of fields to change. |
| 193 | +- `run` executes a saved query and displays results like the `query` command. |
| 194 | +- **Use `queries run` instead of re-typing SQL when a saved query exists.** |
| 195 | + |
| 196 | +### Search |
| 197 | +``` |
| 198 | +hotdata search "<query>" --table <connection.schema.table> --column <column> [--select <columns>] [--limit <n>] [--format table|json|csv] |
| 199 | +``` |
| 200 | +- Full-text search using BM25 across a table column. |
| 201 | +- Requires a BM25 index on the target column (see `indexes create`). |
| 202 | +- Results are ordered by relevance score (descending). |
| 203 | +- `--select` specifies which columns to return (comma-separated, defaults to all). The `score` column is automatically appended when `--select` is used. |
| 204 | +- Default limit is 10. |
| 205 | + |
| 206 | +### Indexes |
| 207 | +``` |
| 208 | +hotdata indexes list --connection-id <id> --schema <schema> --table <table> [--workspace-id <workspace_id>] [--format table|json|yaml] |
| 209 | +hotdata indexes create --connection-id <id> --schema <schema> --table <table> --name <name> --columns <cols> [--type sorted|bm25|vector] [--metric l2|cosine|dot] [--async] |
| 210 | +``` |
| 211 | +- `list` shows indexes on a table with name, type, columns, status, and creation date. |
| 212 | +- `create` creates an index. Use `--type bm25` for full-text search, `--type vector` for vector search (requires `--metric`). |
| 213 | +- `--async` submits index creation as a background job. Use `hotdata jobs <job_id>` to check status. |
| 214 | +- **Before using `hotdata search`, create a BM25 index on the target column.** |
| 215 | + |
179 | 216 | ### Jobs |
180 | 217 | ``` |
181 | 218 | hotdata jobs list [--workspace-id <workspace_id>] [--job-type <type>] [--status <status>] [--all] [--format table|json|yaml] |
|
0 commit comments