Metadata-Version: 2.4
Name: cortexdb-py
Version: 0.2.1
Summary: Python SDK for CortexDB — a RAG-powered memory database
Author: VectorNode
Requires-Python: >=3.9,<4.0
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Dist: eval-type-backport (>=0.3.1,<0.4.0)
Requires-Dist: google-genai (>=1.0.0,<2.0.0)
Requires-Dist: httpx (>=0.28.0,<0.29.0)
Requires-Dist: pydantic (>=2.0,<3.0)
Requires-Dist: python-dotenv (>=1.0.0,<2.0.0)
Description-Content-Type: text/markdown

# CortexDB Python SDK

A Python client for the CortexDB RAG backend, providing easy access to ingestion, querying, and LLM orchestration.

## Features

- **Setup API**: Configure LLM providers (Gemini, OpenAI, Azure).
- **Ingest API**: Ingest documents with automatic embedding generation.
- **Query API**: Perform semantic search, entity retrieval, and graph traversals.
- **Native LLM Integration**: Uses `google-genai` for native Gemini support.

## Installation

```bash
pip install -e .
```

## Usage

See `main.py` for a complete example of setting up a medical chatbot.

```python
from cortexdb import CortexDB

db = CortexDB("http://localhost:8080")

# Setup
db.setup.configure(provider="GEMINI", api_key="...", chat_model="gemini-2.0-flash", embed_model="gemini-embedding-001")

# Ingest
db.ingest.document(uid="user-1", document_title="Test Doc", document_text="Hello world")
db.ingest.prompt(uid="user-1", converser="USER", text="What is this?")

# Query
results = db.query.search_contexts("Hello", limit=5)
```

## Testing

```bash
pip install pytest respx
pytest tests/
```

