Required behavior
- Wrap provider calls without changing their return values or thrown errors.
- Emit only inside an active
EngramClient.withTurnscope. - Preserve concrete memory IDs, ranks, scores, provider/store identity, and useful metadata.
- Label translated provider responses
mappedorobservedaccording to the integration boundary and include a source path. - Report an instrumentation gap instead of fabricating an operation when IDs or outcomes are unavailable.
- Keep retrieval separate from context loading. The application must call
turn.loadafter prompt construction. - Remain fail-open unless the SDK was explicitly configured with
strict: true.
Tests
Include deterministic coverage for successful operations, empty results, malformed/partial provider output, asynchronous acknowledgements, provider errors, and calls outside an active turn. Do not require live credentials in normal CI.Review checklist
- Does every emitted operation have evidence provenance?
- Can an asynchronous write be mistaken for a completed store?
- Can a retrieved record be mistaken for loaded context?
- Are provider errors and return values preserved?
- Are unknown response shapes surfaced rather than silently normalized?
- Does the README document unsupported operations and provider-version assumptions?