Skip to main content
Qdrant is an open-source vector database for similarity search. Qdrant has no OpenInference auto-instrumentor, so this guide wraps each query_points call in a retriever span that records the query and the documents Qdrant returns, using the OpenInference semantic conventions. The embedding and chat calls around it are captured by openinference-instrumentation-openai, so Arize AX shows the full retrieval-augmented generation (RAG) flow in one trace.

Prerequisites

  • Python 3.10+
  • An Arize AX account (sign up)
  • An OPENAI_API_KEY from the OpenAI Platform, used for embeddings and the answer
  • A running Qdrant server: either a Qdrant Cloud cluster, or a local container started with docker run -d -p 6333:6333 qdrant/qdrant (Podman works too: use podman run with the same arguments)

Launch Arize AX

  1. Sign in to your Arize AX account.
  2. From Space Settings, copy your Space ID and API Key. You will set them as ARIZE_SPACE_ID and ARIZE_API_KEY below.

Install

Configure credentials

QDRANT_URL points at the local container from the prerequisites. For Qdrant Cloud, set it to your cluster URL and also set QDRANT_API_KEY.

Setup tracing

Run Qdrant

The example indexes three short documents, then answers a question in a traced RAG flow: a chain span wraps a retriever span for the Qdrant query and the LLM call that answers from the retrieved text.

Expected output

Verify in Arize AX

  1. Open your Arize AX space and select project qdrant-tracing-example.
  2. You should see a new trace within ~30 seconds rooted at an answer_question chain span. It contains a qdrant.query_points retriever span that lists the two retrieved documents with their scores (with the question’s CreateEmbeddings embedding span nested under it), followed by a ChatCompletion LLM span. Indexing the documents produces a separate CreateEmbeddings trace.
  3. If no traces appear, see Troubleshooting.

Check from the skill, CLI, or SDK

Confirm spans are actually reaching your Arize AX project. Use whichever fits your workflow — the skill and CLI work for any framework; the SDK check is shown for each language.
Install the Arize Skills plugin and let your coding agent check for you:
Then prompt your agent:
Use the arize-trace skill to export and analyze recent traces from my project. Confirm spans are arriving, and summarize any errors or latency issues.

Troubleshooting

  • No traces in Arize AX. Confirm ARIZE_SPACE_ID and ARIZE_API_KEY are set in the same shell that runs example.py. Enable OpenTelemetry debug logs with export OTEL_LOG_LEVEL=debug and re-run.
  • Embedding and chat spans missing, but the retriever span is present. OpenAIInstrumentor().instrument(...) must run before openai is imported. Make sure instrumentation.py is the first import in your entry point.
  • The retriever span shows no documents. The span only lists what Qdrant returned. An empty result usually means the collection is empty or was created with a different vector size: text-embedding-3-small returns 1,536 dimensions, so the collection’s size must match.
  • Connection refused on port 6333. The Qdrant container isn’t running. Start it with docker run -d -p 6333:6333 qdrant/qdrant (or podman run), then check curl http://localhost:6333/readyz. With Podman on macOS, run podman machine start first.
  • 401 Unauthorized from Qdrant Cloud. Set QDRANT_API_KEY to a key for the same cluster as QDRANT_URL.

Resources

Qdrant Documentation

OpenInference Semantic Conventions

Manual instrumentation in Arize AX

Qdrant Python client