You've already forked agentic-coding-workflow
feat(acp): sqlc queries (agent_kinds + sessions + events) + generated code
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
-- name: InsertEvent :one
|
||||
INSERT INTO acp_events (
|
||||
session_id, direction, rpc_kind, method, payload, payload_size, truncated
|
||||
) VALUES ($1, $2, $3, $4, $5, $6, $7)
|
||||
RETURNING id, session_id, direction, rpc_kind, method, payload,
|
||||
payload_size, truncated, created_at;
|
||||
|
||||
-- name: ListEventsSince :many
|
||||
SELECT id, session_id, direction, rpc_kind, method, payload,
|
||||
payload_size, truncated, created_at
|
||||
FROM acp_events
|
||||
WHERE session_id = $1 AND id > $2
|
||||
ORDER BY id ASC
|
||||
LIMIT $3;
|
||||
|
||||
-- name: PurgeEventsBefore :execrows
|
||||
DELETE FROM acp_events WHERE created_at < $1;
|
||||
Reference in New Issue
Block a user