Use existing Qdrant gRPC drivers unchanged, and add NornicDB's NornicSearch proto as an extra client when you want SearchText.
You do not need to fork Qdrant drivers.
- You already use Qdrant gRPC APIs (
Points.Search,Points.Query, etc.). - You also want Nornic-native
NornicSearch/SearchText. - You want both over the same endpoint (
:6334by default).
NORNICDB_QDRANT_GRPC_ENABLED=true- Port
6334exposed/reachable - Existing Qdrant gRPC client in your app (unchanged)
- Add generated client code from
pkg/nornicgrpc/proto/nornicdb_search.proto
- Qdrant client: talks to Qdrant-compatible services
- Nornic client: talks to
NornicSearchservice - Same gRPC channel: both clients can share one connection to
127.0.0.1:6334
-
Keep your current Qdrant client/protos.
-
Generate Go stubs for Nornic proto:
protoc \
--go_out=. \
--go-grpc_out=. \
pkg/nornicgrpc/proto/nornicdb_search.proto- Create both clients on the same connection:
conn, err := grpc.Dial("127.0.0.1:6334", grpc.WithTransportCredentials(insecure.NewCredentials()))
if err != nil {
log.Fatal(err)
}
defer conn.Close()
qdrantClient := qdrant.NewPointsClient(conn) // Existing Qdrant driver usage
nornicClient := nornicpb.NewNornicSearchClient(conn) // Additive Nornic client
// Existing Qdrant-compatible vector search
_, err = qdrantClient.Search(ctx, &qdrant.SearchPoints{
CollectionName: "my_vectors",
Vector: make([]float32, 128),
Limit: 10,
})
if err != nil {
log.Fatal(err)
}
// Nornic-native text search
resp, err := nornicClient.SearchText(ctx, &nornicpb.SearchTextRequest{
Query: "machine learning",
Limit: 10,
})
if err != nil {
log.Fatal(err)
}
_ = respIf you only need text query with existing Qdrant drivers, use Points.Query with Document.text:
from qdrant_client import QdrantClient, models
client = QdrantClient(host="127.0.0.1", grpc_port=6334, prefer_grpc=True)
client.query_points(
collection_name="my_vectors",
query=models.Document(text="machine learning"),
limit=10,
)- Use Qdrant
Points.Query+Document.textwhen you want pure Qdrant-driver semantics. - Use
NornicSearch/SearchTextwhen you want Nornic-native typed search RPC behavior. - Use both together if your app needs both compatibility and native features.