Skip to content

CLI

The qql binary is the operational interface to the same runtime used by the SDKs. It parses, plans, and executes QQL against a Qdrant instance — or against the in-process edge backend — from a terminal or a script.

The two flags below apply to every subcommand.

FlagPurpose
--url <URL>Qdrant endpoint. Overrides QDRANT_URL when supplied; defaults to http://localhost:6333.
--edgeExecute supported commands against the configured in-process edge backend. Requires an edge-enabled build.
CommandPurpose
qql exec "<query>"Execute one statement or an inline semicolon-delimited script (--json for JSON output, -q/--quiet)
qql execute file.qqlExecute a script file (--stop-on-error; prints a JSON summary {ok, command, path, succeeded, failed, message})
qql explain "<query>"Show the execution plan without a backend (plan text; JSON with --json)
qql connectInteractive REPL
qql convert [file.json]Convert Qdrant REST JSON to QQL (stdin if no file)
qql dump <collection> <output.qql>Export a collection to a .qql script (--batch-size N, default 100; typed CREATE COLLECTION + CREATE INDEX + batched UPSERT)
qql doctorCheck backend and embedder health (--json)
qql config edgeConfigure persistent edge settings (see below)
qql versionPrint version as JSON
QQLExecutable inputTry in playground
SHOW COLLECTIONS;
Execute, explain, and diagnose
qql exec "SHOW COLLECTIONS" qql exec --json "SHOW COLLECTIONS" qql explain "SHOW COLLECTIONS" qql doctor --json qql version

qql config edge writes persistent settings for the in-process edge backend to <config_dir>/edge.json (mode 0600). The edge executor reads this file every time you run a command with --edge.

FlagPurpose
--data-dirDirectory for persistent qdrant-edge data
--in-memoryKeep payloads in RAM instead of persisting them to disk
--embedder fastembed|httpEmbedding backend (default fastembed)
--modelLocal FastEmbed dense model name or alias
--sparse-modelOffline sparse model for fastembed (e.g. splade, bge-m3)
--multi-modelOffline multivector model for fastembed (e.g. bge-m3)
--image-modelOffline CLIP vision model for fastembed (e.g. clip-vision)
--reranker-modelOffline cross-encoder model (e.g. bge-reranker-base)
--cache-dirDirectory for downloaded FastEmbed models
--show-download-progressShow model download progress
--embed-urlOpenAI-compatible embedding endpoint for the HTTP backend
--embed-keyAPI key for the HTTP embedding backend
--embed-modelModel name sent to the HTTP backend (default nomic-embed-text)
--embed-dimExpected HTTP embedding dimension (default 768)
--multi-embed-url / --multi-embed-key / --multi-embed-model / --multi-embed-dimOptional multi/ColBERT HTTP embedding endpoint
--image-embed-url / --image-embed-key / --image-embed-model / --image-embed-dimOptional image/CLIP vision HTTP embedding endpoint

Validation: --embedder http requires --embed-url, and --embed-dim must be greater than zero. After saving, the command prints Use it with: qql --edge exec "SHOW COLLECTIONS".

Configure the edge backend with an HTTP embedder
qql config edge --embedder http
--embed-url http://localhost:11434/v1/embeddings
--embed-model all-minilm:l6-v2
--embed-dim 384

The edge backend is an OPT-IN build: it is compiled into the CLI only when the edge feature is enabled.

Build the edge-enabled CLI
cargo build --release -p qql-cli --features edge

Once configured, every operational command accepts --edge:

Edge commands
qql --edge exec "QUERY TEXT 'local search' FROM docs USING dense LIMIT 10" qql --edge doctor qql --edge connect qql --edge execute script.qql qql --edge dump listings out.qql
QQLQuery the edge backendTry in playground
QUERY TEXT 'quiet apartment near transit' FROM listings
USING dense
WHERE location GEO_RADIUS {
center: {lat: 52.52, lon: 13.405},
radius: 5000.0
}
WITH PAYLOAD INCLUDE (name, neighbourhood, price)
LIMIT 10;

qql connect starts the interactive shell. Results render as psql-style aligned tables with a row-count footer.

Built-inPurpose
help, \h, ?Show available statements and built-in commands
explain <query>Show the execution plan without executing
execute <file>, \e <file>Run a .qql script file
dump <collection> <output.qql>Dump a collection (schema + vectors + payload) to .qql
exit, quit, \q, :qLeave the shell

Ctrl-D exits the shell; Ctrl-C cancels the current input line.

Start the REPL
qql connect qql> help qql> SHOW COLLECTIONS; qql> \q
VariableDefaultPurpose
QDRANT_URLhttp://localhost:6333REST or gRPC endpoint
QDRANT_API_KEYunsetQdrant API key
EMBED_URLunsetOpenAI-compatible embedding endpoint
EMBED_KEYunsetAPI key for the embedding endpoint
EMBED_MODELall-minilm:l6-v2dense model ID
EMBED_DIM384dense output dimension
MULTI_EMBED_URLunsetmulti/ColBERT embedding endpoint
MULTI_EMBED_KEYunsetAPI key for multi embeds
MULTI_EMBED_MODELunsetmulti/ColBERT model ID
MULTI_EMBED_DIMunsetper-token dimension for multi embeds
IMAGE_EMBED_URLunsetimage/CLIP vision embedding endpoint
IMAGE_EMBED_KEYunsetAPI key for image embeds
IMAGE_EMBED_MODELunsetimage/CLIP vision model ID
IMAGE_EMBED_DIMunsetimage output dimension
RERANK_URLunsetcross-encoder rerank endpoint
RERANK_KEYunsetAPI key for reranking
RERANK_MODELunsetreranker model ID
QQL_EDGE_DATA_DIR<config_dir>/edge-dataedge data directory
QQL_EDGE_EMBEDDERfastembededge embedding backend
QQL_EDGE_MODELunsetedge FastEmbed dense model
QQL_EDGE_SPARSE_MODELunsetedge sparse model
QQL_EDGE_MULTI_MODELunsetedge multivector model
QQL_EDGE_IMAGE_MODELunsetedge image/CLIP model
QQL_EDGE_RERANKER_MODELunsetedge reranker model
QQL_EDGE_CACHE_DIRunsetedge FastEmbed model cache
QQL_EDGE_ON_DISKtruepersist payloads to disk (true/false)

qql convert reads a Qdrant REST JSON payload from a file, or from stdin when no file is given, and prints the equivalent QQL statements.

It accepts a wrapped request {method, path, body}:

RequestQQL
PUT /collections/{name}CREATE COLLECTION
PUT /collections/{name}/pointsUPSERT
POST /collections/{name}/points/queryQUERY FORMULA or CTE query
POST /collections/{name}/points/searchQUERY
POST /collections/{name}/points/recommendQUERY RECOMMEND
POST /collections/{name}/points/discoverdiscover query
POST /collections/{name}/points/scrollSCROLL
POST /collections/{name}/points/deleteDELETE
POST /collections/{name}/points/payloadpayload mutation
PUT /collections/{name}/indexCREATE INDEX

A bare REST body is auto-detected from its structure (prefetch + query, searches, points, vector, positive, target, ids, vectors_config, field_name, filter). Qdrant filters translate mustAND, shouldOR, and must_notNOT.

Convert a search request
qql convert search.json cat search.json | qql convert