Metadata-Version: 2.4
Name: coffy
Version: 0.2.2
Summary: Lightweight local NoSQL, SQL, and Graph embedded database engine
Author: nsarathy
License: MIT
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: networkx>=3.0
Requires-Dist: pyvis>=0.3.2
Dynamic: author
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: license
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Coffy: Local-First Embedded Database Engine for Python

[![PyPI](https://img.shields.io/pypi/v/coffy)](https://pypi.org/project/coffy/)
![PyPI Downloads](https://static.pepy.tech/badge/coffy)

**Coffy** is a lightweight, local-first embedded database engine supporting **NoSQL**, **SQL**, and **Graph** models — all in pure Python. Designed for fast prototyping, scripting, and local apps.

[coffydb.org](https://coffydb.org/)

---

## Installation

```bash
pip install coffy
```

---
![preview](https://github.com/nsarathy/Coffy/blob/main/assets/Coffy%20preview%20image.png)
---
## Features

- Local persistence (JSON, SQLite)
- In-memory mode (`:memory:` or `None`)
- No server needed
- Logical and comparison operators
- Unified query interface

---

## Engines

| Engine | Description | Docs |
|--------|-------------|------|
| `coffy.graph` | Local graph database (NetworkX-based) | [Graph Docs](https://github.com/nsarathy/Coffy/blob/main/Documentation/GRAPH_DOCS.md) |
| `coffy.nosql` | Document store with chainable queries | [NoSQL Docs](https://github.com/nsarathy/Coffy/blob/main/Documentation/NOSQL_DOCS.md) |
| `coffy.sql`   | Thin SQLite wrapper | [SQL Docs](https://github.com/nsarathy/Coffy/blob/main/Documentation/SQL_DOCS.md) |

---

## What sets Coffy apart?
Only embedded Python graph DB with:

- ✅ Declarative traversal syntax (match_node_path(...))
- ✅ Label/type filtering, limit/offset, result projection
- ✅ Unified API for both nodes and relationships

Only pure-Python embedded document store with:

- ✅ Auto-indexing on all top-level fields
- ✅ Chainable logical queries (.where(...).eq(...).or_().in_())
- ✅ Merge/lookups across collections (like mini $lookup)
- ✅ JSON persistence or in-memory fallback

---

## 🔗 Links

- [coffydb.org](https://coffydb.org/)
- PyPI: [coffy](https://pypi.org/project/coffy/)
- Source: [GitHub](https://github.com/nsarathy/Coffy)

---

## License

MIT License © 2025 [Neel Sarathy](https://github.com/nsarathy)

