schema
The definitive guide for inspecting and modifying Retriever's SQLite database schema.
Install
mkdir -p .claude/skills/schema-sdemyanov && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/11476" && unzip -o skill.zip -d .claude/skills/schema-sdemyanov && rm skill.zipInstalls to .claude/skills/schema-sdemyanov
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Use this skill when creating, inspecting, or migrating Retriever's SQLite schema. It is the source of truth for table layouts, path rules, custom field registry behavior, manual field locks, and schema-version behavior.Key capabilities
- →Inspect SQLite table definitions.
- →Manage schema migrations.
- →Handle relative path rules for documents and previews.
- →Register custom field entries.
- →Manage manual-value overwrite protection rules.
How it works
This skill acts as the source of truth for Retriever's SQLite schema, providing rules and guidelines for table definitions, migrations, and field management. It operates under `retriever:routing`.
Inputs & outputs
When to use schema
- →Verify current schema version
- →Apply idempotent database migrations
- →Register custom fields in the registry
- →Inspect table layouts and storage rules
About this skill
Operates under
retriever:routing. If the user's intent actually fits a different tier — anotherretriever:*skill, a Tier 2 slash, a Tier 3tools.pysubcommand, or (last resort) direct DB access — stop and re-route against the ladder before continuing.
Retriever Schema
Use this skill whenever a task touches:
- SQLite table definitions
- schema migrations
- relative path rules
- preview records
- chunk storage
- custom field registry entries
- manual-value overwrite protection rules
- structured filter validation rules
Required references
- Treat ../tool-template/src/10_core.py, ../tool-template/src/40_schema_runtime.py, and the generated ../tool-template/tools.py as the current source of truth.
- Use
python3 skills/tool-template/tools.py schema-versionto confirm the currentschema_versionandtool_version. - Read schema.md for background terminology only; if it conflicts with the source fragments or
schema-version, the code wins.
Rules
- Do not invent new table names when an existing table fits the need.
- Keep document paths relative to the workspace root.
- Keep preview paths relative to
.retriever/. - Preserve manual edits by locking corrected document fields until explicitly overwritten.
- Prefer structured filter contracts over raw SQL filter strings.
- Make migrations idempotent.
- Prefer additive schema changes over destructive rewrites.
When not to use it
- →When the user's intent fits a different `retriever:*` skill.
- →When the user's intent fits a Tier 2 slash command.
- →When the user's intent fits a Tier 3 `tools.py` subcommand or direct DB access.
Limitations
- →The skill does not invent new table names.
- →The skill keeps document paths relative to the workspace root.
- →The skill keeps preview paths relative to `.retriever/`.
How it compares
This skill provides a structured approach to managing Retriever's schema, ensuring consistency and adherence to defined rules, unlike ad-hoc database modifications.
Compared to similar skills
schema side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| schema (this skill) | 0 | 2mo | No flags | Intermediate |
| drizzle-orm | 32 | 2mo | No flags | Intermediate |
| database-design | 6 | 6mo | Review | Intermediate |
| prisma-expert | 12 | 6mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
drizzle-orm
EpicenterHQ
Drizzle ORM patterns for type branding and custom types. Use when working with Drizzle column definitions, branded types, or custom type conversions.
database-design
davila7
Database design principles and decision-making. Schema design, indexing strategy, ORM selection, serverless databases.
prisma-expert
davila7
Prisma ORM expert for schema design, migrations, query optimization, relations modeling, and database operations. Use PROACTIVELY for Prisma schema issues, migration problems, query performance, relation design, or database connection issues.
database-schema-designer
davila7
Design robust, scalable database schemas for SQL and NoSQL databases. Provides normalization guidelines, indexing strategies, migration patterns, constraint design, and performance optimization. Ensures data integrity, query performance, and maintainable data models.
database-migration
wshobson
Execute database migrations across ORMs and platforms with zero-downtime strategies, data transformation, and rollback procedures. Use when migrating databases, changing schemas, performing data transformations, or implementing zero-downtime deployment strategies.
database-migrations-sql-migrations
sickn33
SQL database migrations with zero-downtime strategies for PostgreSQL, MySQL, SQL Server