{"id":34742934,"url":"https://github.com/rjwalters/vibesql","last_synced_at":"2026-01-19T08:00:31.500Z","repository":{"id":320796054,"uuid":"1083367178","full_name":"rjwalters/vibesql","owner":"rjwalters","description":"Vibe-coded NIST compatible database in Rust","archived":false,"fork":false,"pushed_at":"2026-01-14T00:34:06.000Z","size":34987,"stargazers_count":7,"open_issues_count":4,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-14T01:28:17.921Z","etag":null,"topics":["ai-development","rust","sql","vibe-coding","wasm"],"latest_commit_sha":null,"homepage":"https://vibesql.org","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"posix4e/nistmemsql","license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rjwalters.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"docs/CONTRIBUTING_TRANSLATIONS.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":"docs/ROADMAP.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2025-10-25T21:41:54.000Z","updated_at":"2026-01-14T00:34:10.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/rjwalters/vibesql","commit_stats":null,"previous_names":["rjwalters/nistmemsql","rjwalters/vibesql"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/rjwalters/vibesql","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rjwalters%2Fvibesql","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rjwalters%2Fvibesql/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rjwalters%2Fvibesql/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rjwalters%2Fvibesql/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rjwalters","download_url":"https://codeload.github.com/rjwalters/vibesql/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rjwalters%2Fvibesql/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28563195,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-19T03:31:16.861Z","status":"ssl_error","status_checked_at":"2026-01-19T03:31:15.069Z","response_time":67,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-development","rust","sql","vibe-coding","wasm"],"created_at":"2025-12-25T04:26:13.410Z","updated_at":"2026-01-19T08:00:31.447Z","avatar_url":"https://github.com/rjwalters.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# VibeSQL\n\n[![CI](https://github.com/rjwalters/vibesql/actions/workflows/ci-and-deploy.yml/badge.svg)](https://github.com/rjwalters/vibesql/actions/workflows/ci-and-deploy.yml)\n[![Demo](https://img.shields.io/badge/demo-live-success)](https://rjwalters.github.io/vibesql/)\n[![sqltest](https://img.shields.io/endpoint?url=https://rjwalters.github.io/vibesql/badges/sql1999-conformance.json)](https://rjwalters.github.io/vibesql/conformance.html)\n[![SQLLogicTest](https://img.shields.io/endpoint?url=https://rjwalters.github.io/vibesql/badges/sqllogictest.json)](https://rjwalters.github.io/vibesql/conformance.html#SQLlogicTest)\n[![TCL Tests](https://img.shields.io/endpoint?url=https://rjwalters.github.io/vibesql/badges/tcl-tests.json)](https://rjwalters.github.io/vibesql/conformance.html#tcl-tests)\n[![PostgreSQL](https://img.shields.io/endpoint?url=https://rjwalters.github.io/vibesql/badges/pgsql-regress.json)](https://rjwalters.github.io/vibesql/conformance.html#postgresql)\n[![i18n](https://img.shields.io/badge/i18n-19%20languages-blue)](docs/CONTRIBUTING_TRANSLATIONS.md)\n\n**SQL:1999 compliant database in Rust, 100% AI-generated**\n\n[Live Demo](https://rjwalters.github.io/vibesql/) | [CLI Guide](docs/CLI_GUIDE.md) | [Python Bindings](docs/PYTHON_BINDINGS.md) | [Conformance Report](https://rjwalters.github.io/vibesql/conformance.html)\n\n## Highlights\n\n- **100% SQL:1999 Core compliance** - 739/739 sqltest tests passing\n- **100% SQLLogicTest conformance** - 622 files (~7.4M tests)\n- **7,000+ unit tests** - comprehensive test coverage\n- **Real-time subscriptions** - Convex-like reactivity with delta updates\n- **HTTP REST \u0026 GraphQL API** - Full CRUD and query endpoints\n- **Vector search** - AI/ML embeddings with similarity search\n- **File storage** - Blob storage with SQL integration\n- **Full-featured CLI** with PostgreSQL-compatible commands\n- **TypeScript SDK** with React hooks and Drizzle ORM adapter\n- **Python bindings** with DB-API 2.0 interface\n- **WebAssembly** - runs in the browser\n- **485,000+ lines** of Rust across 12 crates\n\nBuilt entirely by AI agents using [Claude Code](https://claude.com/claude-code) and [Loom](https://github.com/loomhq/loom).\n\n## Quick Start\n\n```bash\n# Clone and build\ngit clone --recurse-submodules https://github.com/rjwalters/vibesql.git\ncd vibesql\ncargo build --release\n\n# Run the CLI\ncargo run --release --bin vibesql\n\n# Or try the web demo\ncd web-demo \u0026\u0026 npm install \u0026\u0026 npm run dev\n```\n\n### CLI Example\n\n```bash\n$ cargo run --release --bin vibesql\nvibesql\u003e CREATE TABLE users (id INTEGER, name VARCHAR(50));\nvibesql\u003e INSERT INTO users VALUES (1, 'Alice'), (2, 'Bob');\nvibesql\u003e SELECT * FROM users;\n+----+-------+\n| id | name  |\n+----+-------+\n| 1  | Alice |\n| 2  | Bob   |\n+----+-------+\nvibesql\u003e \\q\n```\n\nSee [CLI Guide](docs/CLI_GUIDE.md) for meta-commands, output formats, and import/export.\n\n### Python\n\n```bash\npip install maturin\nmaturin develop\n```\n\n```python\nimport vibesql\n\ndb = vibesql.connect()\ncursor = db.cursor()\ncursor.execute(\"CREATE TABLE t (id INTEGER, name VARCHAR(50))\")\ncursor.execute(\"INSERT INTO t VALUES (1, 'Hello')\")\ncursor.execute(\"SELECT * FROM t\")\nprint(cursor.fetchall())  # [(1, 'Hello')]\n```\n\nSee [Python Bindings Guide](docs/PYTHON_BINDINGS.md) for full API reference.\n\n## Features\n\n### Real-Time Subscriptions\n\nSubscribe to SQL queries and receive automatic updates when data changes—Convex-like reactivity with full SQL power.\n\n```typescript\nimport { VibeSqlClient } from '@vibesql/client';\n\nconst db = new VibeSqlClient({ host: 'localhost', port: 5432 });\nawait db.connect();\n\n// Subscribe to a query - get updates when data changes\nconst subscription = db.subscribe(\n  'SELECT * FROM messages WHERE channel_id = $1 ORDER BY created_at DESC LIMIT 50',\n  [channelId],\n  {\n    onData: (messages) =\u003e setMessages(messages),\n    onDelta: (delta) =\u003e {\n      // Efficient incremental updates\n      if (delta.type === 'insert') addMessage(delta.row);\n      if (delta.type === 'delete') removeMessage(delta.row);\n    },\n  }\n);\n\n// React hook for easy integration\nfunction ChatRoom({ channelId }) {\n  const { data, isLoading } = useSubscription(db,\n    'SELECT * FROM messages WHERE channel_id = $1',\n    [channelId]\n  );\n  return \u003cMessageList messages={data} /\u003e;\n}\n```\n\n**Features:**\n- Delta updates (only changed rows sent)\n- Automatic reconnection with subscription restoration\n- Configurable limits, quotas, and backpressure handling\n- HTTP SSE endpoint for REST API consumers\n- React hooks (`useSubscription`, `useQuery`)\n\n### SQL Support\n\n- **Queries**: SELECT, JOINs (INNER/LEFT/RIGHT/FULL/CROSS), subqueries, CTEs, UNION/INTERSECT/EXCEPT\n- **DML**: INSERT, UPDATE, DELETE, TRUNCATE\n- **DDL**: CREATE/ALTER/DROP TABLE, views, indexes, schemas\n- **Aggregates**: COUNT, SUM, AVG, MIN, MAX with GROUP BY/HAVING\n- **Window functions**: ROW_NUMBER, RANK, DENSE_RANK, LAG, LEAD\n- **Transactions**: BEGIN, COMMIT, ROLLBACK, savepoints\n- **Security**: GRANT/REVOKE with full privilege enforcement\n\n### Advanced Features\n\n- Views with OR REPLACE and column lists\n- Stored procedures and functions (IN/OUT/INOUT parameters)\n- Full-text search (MATCH AGAINST)\n- Spatial functions (ST_* library)\n- Triggers (BEFORE/AFTER)\n- [Scheduled functions](docs/scheduled-functions.md) (SCHEDULE AFTER/AT, CREATE CRON)\n- [Vector types](docs/vector-search.md) for AI embeddings (VECTOR(n), distance functions)\n- [Blob storage](docs/file-storage.md) with STORAGE_URL/STORAGE_SIZE functions\n\n### Performance\n\n- Columnar execution with SIMD acceleration\n- Cost-based join reordering\n- Hash joins for equi-joins\n- Predicate pushdown\n- Expression caching\n\n## Benchmarks\n\nVibeSQL achieves **10,758 TPS** on TPC-C mixed workload (5.5x faster than SQLite) and passes 100% of TPC-H and TPC-DS queries.\n\n### Test Coverage\n\n| Suite | Coverage | Tests |\n|-------|----------|-------|\n| SQL:1999 Core | 100% | 739/739 sqltest |\n| SQLLogicTest | 100% | 622 files (~7.4M tests) |\n| Unit Tests | - | 7,000+ tests |\n| TPC-DS | 100% | 102/102 queries |\n| TPC-H | 100% | 22/22 queries |\n| TPC-C | 100% | All transactions |\n\n### TPC-C (OLTP Transactions)\n\n| Database | TPS | vs SQLite |\n|----------|-----|-----------|\n| **VibeSQL** | **10,758** | **5.5x faster** |\n| SQLite | 1,969 | baseline |\n| DuckDB | 323 | 6x slower |\n\n*Scale Factor 1, 60-second duration, mixed workload (New Order, Payment, Order Status, Delivery, Stock Level).*\n\n### TPC-DS (Complex Analytics)\n\n**102/102 queries passing (100%)** at SF 0.001. All queries complete within timeout.\n\n*Peak memory: ~141 MB. See [full results](docs/performance/TPCDS_RESULTS.md).*\n\n### TPC-H (Decision Support)\n\n**22/22 queries passing (100%)**. All queries optimized with columnar execution and cost-based join reordering.\n\n### Running Benchmarks\n\n```bash\n# Build release binaries first\ncargo build --release\n\n# Run all benchmarks\nmake benchmark          # TPC-H, TPC-C, TPC-DS, Sysbench\n\n# Individual benchmarks\nmake benchmark-tpch     # TPC-H (22 queries, SF 0.01)\nmake benchmark-tpcc     # TPC-C (OLTP, SF 1)\nmake benchmark-tpcds    # TPC-DS (99 queries, SF 0.001)\nmake benchmark-sysbench # Sysbench (point lookups, range scans)\n\n# With custom parameters\nSCALE_FACTOR=0.01 PROFILING_ITERATIONS=3 cargo bench --bench tpch_profiling\nTPCC_SCALE_FACTOR=1 TPCC_DURATION_SECS=10 cargo bench --bench tpcc_benchmark\n```\n\nSee [Benchmarking Guide](docs/development/BENCHMARKING.md) for details on parameters and profiling.\n\n## Development\n\n```bash\n# Full build, test, and benchmark (runs in background)\nmake all            # Starts in background, shows monitoring instructions\nmake status         # Check progress\nmake logs           # Follow full output\n\n# Individual targets\nmake build          # Build all crates\nmake test           # Run all tests (unit + integration + sqllogictest)\nmake benchmark      # Run TPC-H/TPC-C/TPC-DS/Sysbench benchmarks\nmake all-fg         # Run everything in foreground (blocking)\nmake help           # Show all targets\n```\n\n## Documentation\n\n| Guide | Description |\n|-------|-------------|\n| [TypeScript SDK](packages/vibesql-client-ts/README.md) | Real-time subscriptions \u0026 React hooks |\n| [Drizzle ORM](packages/vibesql-drizzle/README.md) | Type-safe queries with Drizzle adapter |\n| [HTTP API](docs/http-api.md) | REST, GraphQL, and SSE endpoints |\n| [CLI Guide](docs/CLI_GUIDE.md) | Command-line interface |\n| [Python Bindings](docs/PYTHON_BINDINGS.md) | Python API reference |\n| [Scheduled Functions](docs/scheduled-functions.md) | Cron jobs and scheduled tasks |\n| [Transactions](docs/transactions.md) | Durability hints and savepoints |\n| [Vector Search](docs/vector-search.md) | AI/ML embeddings and similarity search |\n| [File Storage](docs/file-storage.md) | Blob storage with SQL integration |\n| [ODBC/JDBC](docs/ODBC_JDBC_CONNECTIVITY.md) | Database connectivity |\n| [Roadmap](docs/ROADMAP.md) | Future plans |\n| [History](docs/HISTORY.md) | Development timeline |\n\n## Project Background\n\nThis project originated from a challenge about AI capabilities: implement a NIST-compatible SQL database from scratch. Core SQL:1999 compliance was achieved in under 2 weeks (Oct 25 - Nov 1, 2025).\n\nInspired by [posix4e/nistmemsql](https://github.com/posix4e/nistmemsql).\n\n## VibeSQL Challenge\n\n**Can you build a SQL database faster than we did?**\n\nThe VibeSQL Challenge: pass all 622 SQLLogicTest files using AI tools. Our benchmark is **25 days** from first commit to 100% conformance—but we spent significant time on features beyond the core challenge (storage engine, server mode, i18n, benchmarks). A focused effort could beat this.\n\n**How to participate:**\n\n1. Fork a seed repo or start from scratch\n2. Use any AI tools—Claude, Copilot, Cursor, or your own agents\n3. Run `make test` to track progress against 622 SQLLogicTest files\n4. When all tests pass, [submit to the leaderboard](https://github.com/vibesql-challenge/submissions)\n\n**Starter templates:**\n\n| Language | Repository |\n|----------|------------|\n| Rust | [challenge-seed-rust](https://github.com/vibesql-challenge/challenge-seed-rust) |\n| C++ | [challenge-seed-cpp](https://github.com/vibesql-challenge/challenge-seed-cpp) |\n| Go | [challenge-seed-go](https://github.com/vibesql-challenge/challenge-seed-go) |\n\nSee the [challenge page](https://rjwalters.github.io/vibesql/#challenge) for full details.\n\n## License\n\nMIT OR Apache-2.0. See [LICENSE-MIT](LICENSE-MIT) and [LICENSE-APACHE](LICENSE-APACHE).\n\n## Contributing\n\nSee [CLAUDE.md](CLAUDE.md) for development workflow with Loom AI orchestration.\n\n---\n\n**[Try the Live Demo →](https://rjwalters.github.io/vibesql/)**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frjwalters%2Fvibesql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frjwalters%2Fvibesql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frjwalters%2Fvibesql/lists"}