database
Database operations — SQLite migrations, bun:sqlite queries, schema patterns. Trigger keywords: database, sqlite, migration, schema, query, table, db.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Database operations — SQLite migrations, bun:sqlite queries, schema patterns. Trigger keywords: database, sqlite, migration, schema, query, table, db.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Git workflows — branching, committing, worktrees, branch isolation, merge strategies. Trigger keywords: git, commit, branch, merge, rebase, worktree, pull, push, cherry-pick.
Testing — writing and running tests with bun:test, test patterns, validation. Trigger keywords: test, testing, unit test, integration test, bun test, spec, assertion.
Pre-commit verification — tsc type checking, test suite, spec invariant checks. Trigger keywords: verify, validate, check, tsc, typecheck, spec check, pre-commit.
Discord messaging — how to send and receive messages, bridge architecture, user identity, formatting. Trigger keywords: discord, discord message, discord reply, discord user, discord bridge, send discord.
Cross-channel messaging — routing rules, channel affinity, how to send messages on each channel, safety rules. Trigger keywords: message, send message, reply, respond, channel, routing, corvid_send_message.
Use this skill when you need to discover remote agents, fetch their capabilities via A2A Agent Cards, or invoke tasks on remote A2A-compatible agents. Triggers include "discover agent", "find agent", "agent card", "invoke remote agent", "send task to agent", "A2A", or any reference to inter-agent communication beyond simple messaging.
基于 SOC 职业分类
| name | database |
| description | Database operations — SQLite migrations, bun:sqlite queries, schema patterns. Trigger keywords: database, sqlite, migration, schema, query, table, db. |
Database patterns for corvid-agent using bun:sqlite.
bun:sqlitecorvid-agent.db (protected — agents cannot modify directly)server/db/schema.ts — contains all migrationsAdd a new entry to the MIGRATIONS object in server/db/schema.ts:
const MIGRATIONS: Record<number, string> = {
// ... existing migrations ...
63: `
CREATE TABLE IF NOT EXISTS my_new_table (
id TEXT PRIMARY KEY,
name TEXT NOT NULL,
created_at TEXT NOT NULL DEFAULT (datetime('now'))
);
`,
};
IF NOT EXISTS for table creationALTER TABLE for adding columns to existing tablesimport { db } from '../db/schema';
// Select one
const row = db.query('SELECT * FROM agents WHERE id = ?').get(agentId);
// Select many
const rows = db.query('SELECT * FROM sessions WHERE agent_id = ?').all(agentId);
// Insert
db.run('INSERT INTO agents (id, name) VALUES (?, ?)', [id, name]);
// Update
db.run('UPDATE agents SET name = ? WHERE id = ?', [name, id]);
// Transaction
db.transaction(() => {
db.run('INSERT INTO ...');
db.run('UPDATE ...');
})();
? placeholders) — never string concatenationTEXT for IDs (UUIDs), timestamps (ISO 8601), and JSON blobsINTEGER for counts, booleans (0/1), and numeric valuesREAL for floating-point valuescreated_at TEXT NOT NULL DEFAULT (datetime('now')) on new tables