UNPKG

@sema-agent/core

Version:

Stateless, task-oriented AI agent core

13 lines (12 loc) • 314 B
export function pgQuery(pool) { return async (sql) => (await pool.query(sql)).rows; } export function mysqlQuery(conn) { return async (sql) => { const [rows] = await conn.query(sql); return rows; }; } export function sqliteQuery(db) { return async (sql) => db.prepare(sql).all(); }