haiku.rag/tests/capabilities
Yiorgis Gozadinos 971ec0a5b0
Coerce a string db_path to Path at the Store and capability boundaries
The documented `HaikuRAG("knowledge.lancedb")` and `rag(db_path="my.lancedb")`
forms both raised `AttributeError: 'str' object has no attribute 'exists'`.
`Store.__init__` assigned its argument to a `Path`-annotated attribute without
coercing, and `resolve_db_path` returned a non-None argument unchanged. Every
runnable example wraps the path in `Path(...)`, which is why it survived.

Coerce in `Store.__init__` and `resolve_db_path`; widen the annotations on
`Store`, `HaikuRAG` and both `create_capability` factories to accept `str`.
2026-08-21 12:49:45 +03:00
..
conftest.py replace haiku.skills with native Pydantic AI capabilities 2026-07-24 15:26:17 +03:00
test_borrowed_client.py Lend the caller's client to the capability 2026-08-18 14:58:18 +03:00
test_capabilities.py Coerce a string db_path to Path at the Store and capability boundaries 2026-08-21 12:49:45 +03:00
test_citation_policy.py Let the record say whether a question is still being answered 2026-08-13 15:03:24 +03:00
test_evidence_capsule.py Refuse to compact evidence the host kept no record of 2026-08-13 15:46:23 +03:00
test_evidence_ledger.py Enforce a declaration wherever there is something to declare 2026-08-13 13:39:42 +03:00
test_evidence_wire.py Give the evidence capabilities one typed state 2026-08-19 17:08:44 +03:00