iris-haystack¶
-
DocumentStore
Full Haystack 2.x protocol implementation backed by InterSystems IRIS native
VECTOR(DOUBLE, N)type. -
Semantic Search
IRISEmbeddingRetrieveruses IRIS nativeVECTOR_COSINEwith SIMD optimisation — no external vector DB required. -
Keyword Search
IRISBm25Retrieverimplements Okapi BM25 in-memory over the filtered document set. -
Metadata Filtering
Uses Haystack's official
document_matches_filter— identical behaviour toInMemoryDocumentStore, all Python types supported.
What is iris-haystack?¶
iris-haystack integrates InterSystems IRIS as a DocumentStore for the Haystack 2.x framework. It lets you store documents, embeddings, and metadata in IRIS and retrieve them with semantic or keyword-based search — without maintaining a separate vector database.
from haystack import Document
from intersystems_iris_haystack.document_stores import IRISDocumentStore
store = IRISDocumentStore(embedding_dim=384)
store.write_documents([
Document(content="IRIS is a multimodel database.", meta={"category": "db"}),
Document(content="Haystack builds LLM pipelines.", meta={"category": "ai"}),
])
print(store.count_documents())
Why IRIS?¶
| Capability | What it means for you |
|---|---|
VECTOR(DOUBLE, N) column | Embeddings stored natively in SQL — no separate vector DB |
VECTOR_COSINE function | SIMD-optimised cosine similarity computed by the database engine |
| ANN / HNSW index | Approximate nearest-neighbour search for large collections |
| SQL + JSON + globals | One platform for relational data and vectors |
Stack¶
intersystems-iris-haystack
├── IRISDocumentStore ← Haystack 2.x protocol
├── IRISEmbeddingRetriever ← VECTOR_COSINE via SQL
└── IRISBm25Retriever ← Okapi BM25 in-memory
Credentials are managed via Haystack Secret — never hardcoded.
Quick install¶
New here?
Start with the Prerequisites page, then follow Installation and Quick Start.