Python client for CoordiNode — graph + vector + full-text database
Project description
coordinode
Python gRPC client for CoordiNode — the graph-native hybrid retrieval engine for AI and GraphRAG.
Installation
pip install coordinode
uv add coordinode
Requirements
- Python 3.11+
- Running CoordiNode instance (
docker compose up -dor binary)
Quick Start
from coordinode import CoordinodeClient
# Synchronous client — context manager handles connection lifecycle
with CoordinodeClient("localhost:7080") as db:
# Cypher query — returns List[Dict[str, Any]]
result = db.cypher("RETURN 1 AS n")
print(result) # [{'n': 1}]
# With parameters
rows = db.cypher(
"MATCH (n:Person {name: $name}) RETURN n.age AS age",
params={"name": "Alice"},
)
# Create nodes
db.cypher(
"CREATE (n:Document {title: $title, embedding: $vec})",
params={"title": "RAG intro", "vec": [0.1, 0.2, 0.3, 0.4]},
)
# Health check
assert db.health()
Async Client
import asyncio
from coordinode import AsyncCoordinodeClient
async def main():
async with AsyncCoordinodeClient("localhost:7080") as db:
rows = await db.cypher("MATCH (n:Concept) RETURN n.name AS name LIMIT 5")
for row in rows:
print(row["name"])
asyncio.run(main())
Connection Options
# host:port string
client = CoordinodeClient("localhost:7080")
# Separate host and port
client = CoordinodeClient("localhost", port=7080)
# TLS
client = CoordinodeClient("db.example.com:7443", tls=True)
# Custom timeout (seconds)
client = CoordinodeClient("localhost:7080", timeout=60.0)
Type Mapping
CoordiNode properties map to Python types automatically:
| Python type | CoordiNode type |
|---|---|
int |
int_value |
float |
float_value |
str |
string_value |
bool |
bool_value |
bytes |
bytes_value |
list[float] |
Vector (HNSW-indexable) |
list[Any] |
PropertyList |
dict[str, Any] |
PropertyMap |
None |
unset (null semantics) |
Vector Search
# Store a node with a vector embedding
db.cypher(
"CREATE (d:Doc {title: $title, embedding: $vec})",
params={"title": "RAG intro", "vec": [0.1] * 384},
)
# Nearest-neighbour search (requires HNSW index — coming in v0.4)
results = db.vector_search(
label="Doc",
property="embedding",
vector=[0.1] * 384,
top_k=10,
metric="cosine", # "cosine" | "l2" | "dot" | "l1"
)
for r in results:
print(r.node.id, r.distance)
Related Packages
| Package | Description |
|---|---|
langchain-coordinode |
LangChain GraphStore + GraphCypherQAChain |
llama-index-graph-stores-coordinode |
LlamaIndex PropertyGraphStore |
Links
Support
License
Apache-2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file coordinode-0.4.1.tar.gz.
File metadata
- Download URL: coordinode-0.4.1.tar.gz
- Upload date:
- Size: 28.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b6ce54a692b21b985770793e8dbcc0ac380299f10aad55134c33e3ff84f901ec
|
|
| MD5 |
acd19ddf3fa6aa8e738c8d9cbeb3b77e
|
|
| BLAKE2b-256 |
d007fc783ed98d9bce5f23a5b241293743ece1e249522ff32fa173f390c4f7b7
|
Provenance
The following attestation bundles were made for coordinode-0.4.1.tar.gz:
Publisher:
release.yml on structured-world/coordinode-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
coordinode-0.4.1.tar.gz -
Subject digest:
b6ce54a692b21b985770793e8dbcc0ac380299f10aad55134c33e3ff84f901ec - Sigstore transparency entry: 1262659534
- Sigstore integration time:
-
Permalink:
structured-world/coordinode-python@2f55798486c79ab0e6f534fb9987e6ffe81748a4 -
Branch / Tag:
refs/tags/v0.4.1 - Owner: https://github.com/structured-world
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@2f55798486c79ab0e6f534fb9987e6ffe81748a4 -
Trigger Event:
push
-
Statement type:
File details
Details for the file coordinode-0.4.1-py3-none-any.whl.
File metadata
- Download URL: coordinode-0.4.1-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dbb34b6d32ca218ef201533d5395c44853638f4286456af4b5bbc46ef5fcba81
|
|
| MD5 |
29debd9b6728ebde5baa03e2145d251e
|
|
| BLAKE2b-256 |
fdb7bb89ee857b1527326e42eec50d04cc010361fabc558ff8976475a7b8db30
|
Provenance
The following attestation bundles were made for coordinode-0.4.1-py3-none-any.whl:
Publisher:
release.yml on structured-world/coordinode-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
coordinode-0.4.1-py3-none-any.whl -
Subject digest:
dbb34b6d32ca218ef201533d5395c44853638f4286456af4b5bbc46ef5fcba81 - Sigstore transparency entry: 1262659547
- Sigstore integration time:
-
Permalink:
structured-world/coordinode-python@2f55798486c79ab0e6f534fb9987e6ffe81748a4 -
Branch / Tag:
refs/tags/v0.4.1 - Owner: https://github.com/structured-world
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@2f55798486c79ab0e6f534fb9987e6ffe81748a4 -
Trigger Event:
push
-
Statement type: