Thank you for your interest in contributing. Osabio is an early-stage project and contributions are welcome.
By submitting a pull request, you agree to the Contributor License Agreement. This allows the project to offer commercial licenses alongside the AGPL-3.0 open source license without requiring per-contributor approval.
All commits must include a Signed-off-by line (DCO) certifying you wrote the code or have the right to submit it:
git commit -s -m "your commit message"- Bun >= 1.3
- Docker (for SurrealDB)
- An OpenRouter API key (or local Ollama)
# Install dependencies
bun install
# Start SurrealDB
docker compose up -d surrealdb surrealdb-init
# Copy and configure environment
cp .env.example .env
# Edit .env with your API key
# Apply migrations
bun migrate
# Start dev server
bun run dev# Unit tests (no external dependencies)
bun test tests/unit/
# Acceptance tests (requires running SurrealDB)
bun test --env-file=.env tests/acceptance/
# Type checking
bun run typecheck- No
null. Useundefinedvia optional properties (field?: Type). Ifnullappears in domain data, fix the producer. - No module-level mutable singletons. Pass shared state via dependency injection.
- Fail fast. Throw on invalid state. No silent fallbacks, no synthetic defaults, no empty
.catch(() => {}).
- All tables are
SCHEMAFULL. Every persisted field must be declared inschema/surreal-schema.surql. - Read the schema before writing queries. Guessing field names leads to silent rejections.
- Use
RecordIdobjects, not"table:id"strings, in TypeScript code. - Graph edges use
RELATE, neverCREATE. - Schema changes require a versioned migration in
schema/migrations/applied viabun migrate.
- Fixed-table ID fields (
session_id,task_id, etc.) are raw UUIDs without table prefix. - Polymorphic fields (
entity_id,target) may usetable:idformat with an allowlist. - Parse IDs once at the HTTP boundary. Never re-wrap a prefixed ID.
- Use
crypto.randomUUID()for test identifiers, notDate.now(). - Acceptance tests get an isolated SurrealDB namespace per suite.
- MCP endpoints require DPoP auth. Use
createTestUserWithMcp()from the test kit.
- Tool
descriptionsays what it does and when to use it. Keep it short. - Parameter guidance goes in Zod
.describe(), not in the tool description or system prompt.
- Fork the repo and create a branch from
main. - Write tests for new functionality.
- Ensure
bun test tests/unit/andbun run typecheckpass. - Include
Signed-off-byin your commits. - Keep PRs focused. One feature or fix per PR.
Open a GitHub issue with:
- Steps to reproduce
- Expected vs actual behavior
- Environment (OS, Bun version, SurrealDB version)
See SECURITY.md for reporting vulnerabilities.