dodil k3 search
Top-level vector search. A single command — text query only, with --collection, --top-k, --min-score. Maps to the Search RPC.
The API’s Search RPC is rich (three query shapes, three modes, multi-collection, rerank, pre-filter, fast-lane tuning). The CLI exposes only the text-query happy path. For everything else — hybrid + rerank, multi-collection, pre-filter, pre-embedded vector queries, multimodal — use the API. Gap callouts below.
dodil k3 search [query] -b BUCKET -c COLLECTION [-k TOP_K] [-s MIN_SCORE]The query is a positional argument — quote it.
| Flag | Short | Type | Default | Description |
|---|---|---|---|---|
--bucket | -b | string | — | Required. Bucket to search in |
--collection | -c | string | — | Collection name or ID. Omit to search all matching collections (the API’s multi-collection mode — but see gap below) |
--top-k | -k | int32 | 10 | Max results to return |
--min-score | -s | float32 | 0.0 | Minimum similarity score threshold |
Examples
Simple text query against one collection:
dodil k3 search "what is multi-head attention" -b kb-prod -c docsTop-5 results, JSON output for downstream processing:
dodil k3 search "transformer architecture" \
-b kb-prod -c docs \
-k 5 \
-o json \
| jq '.results[] | {score, object: .object.key, content}'Filter by minimum similarity:
dodil k3 search "diffusion models" \
-b kb-prod -c docs \
-k 50 -s 0.7 \
-o jsonMulti-collection search via empty
--collection— the API supports leavingcollection_nameempty to fan out across all compatible collections. The CLI accepts an empty-cbut the practical reach is limited because the CLI doesn’t surfacecollection_statuses[]for per-collection observability. For real multi-collection workflows, use the API — see Recipes → Multi-collection Search.
CLI gaps — what’s on the API but not here
For these, drop to curl against POST /:bucket/vector/search — the API page shows the full pbjson body for each:
| Feature | Use the API |
|---|---|
Hybrid search (SEARCH_MODE_HYBRID / _AUTO) — dense + BM25 fusion via RRF | Search → Three search modes |
| Jina rerank (cross-encoder over top-K) | Search → Rerank |
| Pre-filter by metadata (FilterGroup with EQ/NEQ/GT/IN/CONTAINS/EXISTS, AND/OR groups) | Search → Pre-filter |
Pre-embedded vector query (VectorInput.values or .vectors[] for batch) | Search → Shape 2 |
Multimodal file query (s3_key — image / audio / video) | Search → Shape 3 |
include_content / include_highlights — chunk text + highlight snippets in results | Search → Result shape |
Milvus fast-lane tuning (search_params.ef, nprobe, partition_names, output_fields) | Search → Worked example: tuned HNSW |
Common bridging snippet — when you outgrow the CLI
A typical “I want the CLI’s text-search flow but also need rerank + content”:
curl -sS -X POST "https://k3.dev.dodil.io/kb-prod/vector/search" \
-H "Authorization: Bearer $DODIL_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"bucket": "kb-prod",
"text": "what is multi-head attention",
"collectionName": "docs",
"topK": 5,
"searchMode": "SEARCH_MODE_AUTO",
"rerank": true,
"includeContent": true
}' | jq '.results[] | {score, object: .object.key, content}'For everything else, see the full Search API reference — that’s the centerpiece page.
See also
- Search — API Reference — full surface (three query shapes, modes, multi-collection, rerank, filters)
- Core Concepts → SearchRequest / SearchResult — type signatures
- Recipes → Hybrid + Rerank — when each tier helps
- Recipes → Multi-collection Search — empty-collection-name fan-out
- Recipes → Multimodal Search —
s3_keyquery