You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: AGENTS.md
+9Lines changed: 9 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -155,6 +155,15 @@ class MyAdapterDriver(SyncDriverBase):
155
155
- Add integration tests under `tests/integration/test_adapters/<adapter>/test_driver.py::test_*statement_stack*` that cover native path, sequential fallback, and continue-on-error.
156
156
- Guard base behavior (empty stacks, large stacks, transaction boundaries) via `tests/integration/test_stack_edge_cases.py`.
157
157
158
+
### ADK Memory Store Pattern
159
+
160
+
-`SQLSpecMemoryService` delegates storage to adapter-backed memory stores (`BaseAsyncADKMemoryStore` / `BaseSyncADKMemoryStore`).
161
+
- All ADK settings live in `extension_config["adk"]`; memory flags are `enable_memory`, `include_memory_migration`, `memory_table`, `memory_use_fts`, and `memory_max_results`.
162
+
- Search strategy is driver-determined: `memory_use_fts=True` enables adapter FTS when available, otherwise fall back to `LIKE`/`ILIKE` with warning on failure.
163
+
- Deduplication is keyed by `event_id` with idempotent inserts (ignore duplicates, return inserted count).
164
+
- Multi-tenancy uses the shared `owner_id_column` DDL; stores parse the column name to bind filter parameters.
165
+
- TTL cleanup is explicit via store helpers or CLI (`delete_entries_older_than`, `sqlspec adk memory cleanup`).
166
+
158
167
### Driver Parameter Profile Registry
159
168
160
169
- All adapter parameter defaults live in `DriverParameterProfile` entries inside `sqlspec/core/parameters.py`.
- Schedule periodic cleanup with adapter-provided pruning helpers or ad-hoc SQL that removes stale rows.
226
226
- Back up tables like any other transactional data; events can grow quickly, so consider partitioning or TTL policies in PostgreSQL (`CREATE POLICY ... USING (create_time > now() - interval '90 days')`).
227
227
228
+
## Future Enhancements
229
+
230
+
- Vector/embedding search hooks for adapter-specific similarity queries.
231
+
- Vertex AI Memory Bank and RAG bridge helpers for hybrid deployments.
232
+
- Background TTL pruning workflows for high-volume memory tables.
0 commit comments