turso
$
npx mdskill add EpicenterHQ/epicenter/tursoExplains Turso and libSQL patterns for SQLite-compatible database usage
- Solves integration and sync challenges with embedded and remote SQLite-compatible databases
- Relies on Turso CLI, libSQL drivers, and Drizzle ORM for schema and queries
- Analyzes sync behavior, WAL/MVCC, and compatibility gaps in different deployment modes
- Provides guidance on data consistency, lifecycle, and secure client usage boundaries
SKILL.md
.github/skills/tursoView on GitHub ↗
--- name: turso description: Turso and libSQL patterns for embedded SQLite-compatible databases, serverless drivers, sync engines, partial sync, WAL/MVCC behavior, compatibility gaps, CLI usage, and Drizzle integration boundaries. Use when mentioning Turso, libSQL, @libsql/client, remote SQLite, embedded replicas, or local database sync. metadata: author: epicenter version: '1.0' --- # Turso And libSQL ## Reference Repositories - [Turso](https://github.com/tursodatabase/turso) - SQLite-compatible database platform and libSQL ecosystem - [Drizzle ORM](https://github.com/drizzle-team/drizzle-orm) - ORM commonly used with libSQL and Turso ## Upstream Grounding When Turso sync behavior, libSQL driver behavior, embedded replicas, partial sync, concurrency, compatibility, or CLI behavior affects correctness, ask DeepWiki a narrow question against `tursodatabase/turso`. Verify decisive details against local driver versions and Turso docs. Use the `drizzle-orm` skill for schema and query builder decisions. ## Driver Boundaries - Treat Turso/libSQL as SQLite-compatible, not identical to every local SQLite deployment. - Serverless client usage has network and auth behavior. Keep it behind the runtime boundary that owns secrets. - Embedded replicas and sync engines have lifecycle and consistency behavior. Document when data is local, when it syncs, and which writes are accepted. - Do not assume normal multi-process SQLite behavior when using embedded or remote libSQL modes. ## Sync And Compatibility Checks - Decide whether the feature needs remote writes, local reads, offline reads, or bidirectional sync before choosing the driver mode. - For partial sync, define the subset boundary explicitly and test that queries do not silently depend on unsynced rows. - Check current SQLite compatibility before using newer SQLite features, virtual tables, extensions, triggers, or pragma behavior. - WAL, MVCC, and concurrency details are part of the database contract. Do not hide them behind generic "SQLite" language when they affect correctness. ## Operational Rules - Keep Turso CLI commands in docs or scripts, not scattered through app code. - Integration tests should cover auth failure, network failure, sync lag, duplicate writes, and migration compatibility. - When Drizzle is the ORM, keep the schema and migrations in Drizzle, but put Turso connection, sync, and deployment constraints in this skill's mental model.
More from EpicenterHQ/epicenter
- agent-goalWrite `/goal` prompts for long-running agent work in Codex or Claude Code. Use for slash goal, agent goal, durable objective, autonomous coding run.
- approachability-auditReview code as a new TypeScript developer. Use when code feels indirect, clever, hard to follow, or needs a pass on abstractions, names, first-read clarity.
- arktypeArktype: runtime validation, discriminated unions with .merge()/.or(), spread keys. Use when mentioning arktype, type(), union types, command/event schemas.
- attach-primitiveContract and invariants for `attach*` composition primitives in `packages/workspace` (side-effectful building blocks like attachIndexedDb, attachSqlite, attachBroadcastChannel, attachEncryption, attachTable, openCollaboration), and when to use `create*` (pure construction) instead. Use when writing or reviewing an `attach*` or `create*` function, naming a new workspace primitive, composing inside a workspace builder, or deciding whether a primitive registers listeners at call time.
- authEpicenter auth packages: `@epicenter/auth`, `@epicenter/auth-svelte`, OAuth sessions, identity state, auth-owned fetch/WebSocket, and workspace lifecycle binding. Use when editing Epicenter auth clients, session state, hosted sign-in, or auth/workspace integration.
- autumnAutumn billing in Epicenter: `autumn.config.ts`, `autumn-js` credit checks, `atmn` CLI, plan gates, and metered AI usage. Use when changing billing, pricing, credits, plan access, refunds, or usage events.
- better-auth-best-practicesBetter Auth server/client setup: `auth.ts`, generated schema, DB adapters, sessions, cookies, env vars, and plugins. Use when mentioning Better Auth, betterauth, auth handlers, OAuth, email/password, or session configuration.
- better-auth-security-best-practicesBetter Auth security hardening: rate limits, secrets, CSRF, trusted origins, cookies, sessions, OAuth tokens, and audit logging. Use when reviewing auth security, brute-force protection, token handling, or deployment safety.
- change-proposalPresent proposed code changes visually before implementing. Use when: "show me options", "compare approaches", "what should we do", or when changes need before/after comparison.
- claude-code-consultUse this skill when the user asks to consult Claude, ask Claude Code, get another model's take, run a taste check, find cleaner options, or prepare a Claude prompt. Create a bounded second-opinion prompt or run a read-only Claude Code consult, then verify Claude's claims against local files.