Skip to main content

The AI-native database client — graph memory + vector search + real-time sync in 5.3 MB

Project description

DriftDB Python Client

The AI-native database client. Graph memory + vector search + real-time sync in 5.3 MB.

pip install driftdb

Quick Start

from driftdb import DriftDB

db = DriftDB("http://localhost:9211", token="your-token")

# Create nodes
db.create_node(labels=["User"], properties={"name": "Amrit", "age": 25})

# Query with DriftQL
result = db.query('FIND (u:User) RETURN u.name, u.age')

# AI Memory — one line to give your LLM a brain
db.remember("User prefers dark mode")
db.remember("Meeting at 3pm tomorrow", labels=["Event"])

# Recall via vector similarity
db.recall(vector=[0.1, 0.5, 0.9], limit=5)

# Vector similarity search
db.similar([0.1, 0.5, 0.9, 0.3], threshold=0.8, limit=10)

# Statistics
db.stats()

API

Method Description
DriftDB(url, token) Connect to DriftDB
db.query(driftql) Execute DriftQL query
db.create_node(labels, properties) Create a node
db.get_node(id) Get node by ID
db.list_nodes() List all nodes
db.delete_node(id) Soft-delete node
db.find(label, where_clause, returns) Find by label
db.create_edge(src, tgt, type, props) Create edge
db.remember(text, labels, vector) Store AI memory
db.recall(text, vector, limit) Recall memories
db.similar(vector, threshold, limit) Vector similarity
db.backup(directory, password) Backup database
db.health() / db.is_healthy() Health check
db.stats() Database stats

Requirements

  • Python 3.8+
  • A running DriftDB server (driftdb --serve --rest)

License

SSPL-1.0 (same as MongoDB)

GitHub · Documentation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

driftdb_ai-0.1.3.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

driftdb_ai-0.1.3-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file driftdb_ai-0.1.3.tar.gz.

File metadata

  • Download URL: driftdb_ai-0.1.3.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for driftdb_ai-0.1.3.tar.gz
Algorithm Hash digest
SHA256 dae139bd4191fdbd50cc5602f7ec34bb0947e6f05f6dcadffc803a3bdfa2cb4e
MD5 5de1044093a5aa9c35dcbfbb1e9c8392
BLAKE2b-256 cc53317edc5659f72b3b3cba99febca0e246ec4e72968a69d52a7d6463c0e693

See more details on using hashes here.

File details

Details for the file driftdb_ai-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: driftdb_ai-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 6.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for driftdb_ai-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 8f868efcf20bfd1aec3129965abcaa0881e61b374b640095f7db3c4632d19f3c
MD5 6ce6b9ea8e5421e4867437d9dbedf3bb
BLAKE2b-256 1b9a241bab490aa8cd9016c639a492a6acf29f1b2ef7ee0a5aa698b44509989e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page