@agentprodready/persistence
v1.0.1
Published
**Persistence ports — repositories and transactions without locking you to a database vendor.**
Downloads
1,030
Readme
@agentprodready/persistence
Persistence ports — repositories and transactions without locking you to a database vendor.
| | |
|---|---|
| Status | Production contracts published |
| Install | npm install @agentprodready/persistence |
| Module | ESM · Node.js >=22 <25 |
| License | MIT |
| Repository | ameenmari/agentprodready |
When to use
You need durable stores (checkpoints, memory records, etc.) behind replaceable providers.
Prefer not to start here if ephemeral Simple Memory is enough (memory: true).
Install
npm install @agentprodready/persistence
# Postgres provider (optional)
npm install @agentprodready/persistence-postgresSample
import type { PersistenceUnitOfWork } from '@agentprodready/persistence';
declare const uow: PersistenceUnitOfWork;
await uow.withTransaction(async (tx) => {
// repositories accessed via tx — drivers live in provider packages
return tx;
});Ownership
| Owns | Does not own | |---|---| | Persistence ports and repository contracts | Postgres driver details (see persistence-postgres); Runtime recovery policy |
Documentation
License
MIT © 2026 ameenmari
