markdownf8555a15
| 1 | # pywitdb |
| 2 | |
| 3 | Python bindings for [WitDatabase](https://github.com/dmitrat/WitDatabase) — embedded ACID store (`.witdb`). |
| 4 | |
| 5 | **Org:** [AI-Guiders](https://github.com/AI-Guiders/pywitdb) |
| 6 | **Upstream engine:** `OutWit.Database.Core` (NuGet) |
| 7 | **Scope:** door-to-singularity / `[PRIMARY:PYWDB]` |
| 8 | |
| 9 | ## Status |
| 10 | |
| 11 | Early bootstrap: ADR-001 accepted; MVP bridge implementation in progress. |
| 12 | |
| 13 | ## Target API |
| 14 | |
| 15 | ```python |
| 16 | import pywitdb |
| 17 | |
| 18 | with pywitdb.open("store.witdb", password="...") as db: |
| 19 | with db.transaction(): |
| 20 | db.put(b"meta:fv", b"94266") |
| 21 | assert db.get(b"meta:fv") == b"94266" |
| 22 | ``` |
| 23 | |
| 24 | ## Architecture |
| 25 | |
| 26 | See [docs/adr/0001-binding-architecture-bridge-and-native.md](docs/adr/0001-binding-architecture-bridge-and-native.md). |
| 27 | |
| 28 | | Phase | Binding | Purpose | |
| 29 | |-------|---------|---------| |
| 30 | | MVP | JSON subprocess bridge (`witdb-bridge` .NET CLI) | Ship `open` / KV / `transaction`; cross-lang contract tests | |
| 31 | | v1 prod | NativeAOT C ABI + `ctypes` wheels | Low latency, no .NET runtime dependency in Python process | |
| 32 | |
| 33 | ## Development |
| 34 | |
| 35 | ```bash |
| 36 | python -m pip install -e ".[dev]" |
| 37 | pytest |
| 38 | ``` |
| 39 | |
| 40 | Bridge CLI and C# fixture tests land in follow-up PRs (ADR-0001 § Implementation plan). |
| 41 | |
| 42 | ## License |
| 43 | |
| 44 | Apache-2.0 — aligned with WitDatabase. |
| 45 | |