SurrealDB Agent Skills
Official SurrealDB agent skills for use in agentic
workflows. Agent Skills are folders of instructions, scripts, and resources
that agents can discover and use to do things more accurately and efficiently.
Compatible with most AI agents including Claude Code, GitHub Copilot, Cursor,
Cline, and many others.
The skills in this repo follow the Agent Skills
format.
Installation
As a plugin (recommended)
Claude Code:
/plugin marketplace add surrealdb/agent-skills
/plugin install surrealdb@surrealdb
Third-party marketplaces do not auto-update by default. We recommend enabling
it so you always get the latest skills: run /plugin, open the Marketplaces
tab, select surrealdb, and choose Enable auto-update.
Codex:
codex plugin marketplace add surrealdb/agent-skills
Then install surrealdb from the plugin directory. To pick up new releases,
run codex plugin marketplace upgrade surrealdb periodically.
Cursor reads .cursor-plugin/plugin.json.
Install all skills
npx skills add surrealdb/agent-skills
Install a specific skill
npx skills add surrealdb/agent-skills --skill surrealql
npx skills add surrealdb/agent-skills --skill surrealql-performance
npx skills add surrealdb/agent-skills --skill surrealql-functions
npx skills add surrealdb/agent-skills --skill surrealkit
npx skills add surrealdb/agent-skills --skill surrealdb-vector
npx skills add surrealdb/agent-skills --skill surrealdb-python
npx skills add surrealdb/agent-skills --skill surrealdb-js
npx skills add surrealdb/agent-skills --skill surrealdb-cli
npx skills add surrealdb/agent-skills --skill surrealdb-docs
npx skills add surrealdb/agent-skills --skill surrealdb-agent-memory-docs
Local install from repository
-
Clone the repository:
git clone https://github.com/surrealdb/agent-skills.git
-
Copy the skills/ directory to the location where your coding agent reads
its skills or context files. Refer to your agent's documentation for the
correct path.
Available Skills
surrealql
Core SurrealQL query language reference covering syntax, best practices, schema
definitions, graph relationships, and common patterns.
Use when:
- Writing SurrealQL queries (SELECT, CREATE, UPDATE, DELETE, RELATE)
- Designing schemas with DEFINE TABLE, DEFINE FIELD, and DEFINE INDEX
- Working with graph relationships and record IDs
- Migrating from traditional SQL to SurrealQL
- Setting up live queries for real-time updates
surrealql-performance
Performance optimization for SurrealDB: record ID and key design for locality and
range scans, indexing strategy, and computed/derived fields.
Use when:
- Designing record IDs and keys for efficient lookups and range scans
- Choosing between standard, unique, full-text, or vector indexes
- Verifying index usage with
EXPLAIN and avoiding over-indexing
- Precomputing values with computed fields, views, or events
- Diagnosing and fixing slow queries
surrealql-functions
Discover and use SurrealDB's built-in SurrealQL functions with version-current
signatures via the SurrealQL language server and tree-sitter grammar, plus a
namespace catalog linking every function group to its docs.
Use when:
- Looking up which built-in function to use or its exact signature
- Getting editor completions, hover, and signature help for
.surql files
- Confirming a function exists in the installed SurrealDB version
- Setting up the
surrealql-language-server (LSP)
surrealkit
SurrealKit CLI for SurrealDB schema management: project scaffolding from
templates, development sync, phased production rollouts, schema modules and
database targets, static SurrealQL analysis, type generation, and a declarative
testing framework.
Use when:
- Scaffolding a new SurrealDB project with
surrealkit init and templates
- Applying schema changes in development with
surrealkit sync
- Planning, executing, or rolling back production migrations with
surrealkit rollout
- Adopting SurrealKit on an existing database with
surrealkit rollout baseline
- Splitting a schema into modules, or applying it to several database targets
- Statically checking SurrealQL without a database with
surrealkit check
- Generating JSON or TypeScript types from a live schema with
surrealkit typegen
- Writing declarative TOML tests for schemas, permissions, and API endpoints with
surrealkit test
surrealdb-vector
Vector search with SurrealDB using HNSW indexes, KNN queries, and similarity
scoring.
Use when: