diff --git a/install/worker.js b/install/worker.js index 80b0d34..f1b3251 100644 --- a/install/worker.js +++ b/install/worker.js @@ -1,5 +1,5 @@ const GITHUB_REPO = "justrach/codedb"; -const FALLBACK_VERSION = "0.2.52"; +const FALLBACK_VERSION = "0.2.53"; const INSTALL_SCRIPT_URL = `https://raw.githubusercontent.com/${GITHUB_REPO}/main/install/install.sh`; export default { diff --git a/socials/tweet.md b/socials/tweet.md new file mode 100644 index 0000000..ceaab77 --- /dev/null +++ b/socials/tweet.md @@ -0,0 +1,74 @@ +# codedb launch tweets + +Best times to post (PST): Tue-Thu, 8-10 AM +Best times to post (SGT): Tue-Thu, 11 PM - 1 AM + +--- + +Tweet 1 (Hook) + +I built a code intelligence server in Zig that gives AI agents 469x faster queries than grep/find — and uses 92x fewer tokens. + +0.2ms lookups. 3.9ms symbol search. Indexes once, then every query hits memory. No filesystem scans. No raw text dumps. +--- + +Tweet 2 (The problem) + +Every time an AI agent runs grep or find on your codebase, it pays the full cost. + +Filesystem scan. Raw text dump. Thousands of tokens for a simple lookup. + +grep a symbol across 7k files: 763ms, 7.7KB response. +codedb: 3.9ms, 4.4KB. Same answer. 200x faster. Half the bytes. + +--- + +Tweet 3 (The numbers) + +Benchmarked on openclaw (7,364 files, 128MB): + +Word lookup: 0.2ms vs 65ms. 325x. +Symbol find: 3.9ms vs 763ms. 200x. +Reverse deps: 1.3ms vs 750ms. 469x. +Deps response: 162 bytes vs 15KB. 92x less data. + +Cold start: 2.9 seconds for 7,364 files. Then sub-millisecond everything. + +--- + +Tweet 4 (What you get) + +16 MCP tools. Not 5, not 8. Sixteen. + +tree, outline, symbol, search, word, hot, deps, read, edit, changes, status, snapshot, bundle, remote, projects, index. + +codedb_remote queries any GitHub repo without cloning. +codedb_bundle batches multiple queries in one call. +codedb_index indexes any local folder on demand. + +Pure Zig. Single binary. Zero dependencies. + +--- + +Tweet 5 (CTA) + +One command. Auto-registers in Claude Code, Codex, Gemini CLI, and Cursor. + +curl -fsSL https://codedb.codegraff.com/install.sh | sh + +BSD-3 licensed. Open source. + +https://codedb.codegraff.com +github.com/justrach/codedb + +--- + +Alt: Single tweet + +I built a code intelligence server in Zig that gives AI agents 469x faster queries and sends 92x fewer bytes than grep/find. + +16 MCP tools. Zero deps. 2.9s to index 7k files. Sub-millisecond everything after. + +Works with Claude Code, Codex, Gemini CLI, Cursor. One command install. + +curl -fsSL https://codedb.codegraff.com/install.sh | sh diff --git a/socials/tweet3.md b/socials/tweet3.md new file mode 100644 index 0000000..ae221af --- /dev/null +++ b/socials/tweet3.md @@ -0,0 +1,120 @@ +# codedb v0.2.52 update tweets + +Best times to post (PST): Tue-Thu, 8-10 AM +Best times to post (SGT): Tue-Thu, 11 PM - 1 AM + +--- + +Tweet 1 (Hook) + +codedb v0.2.52 just dropped. + +538x faster than ripgrep. 569x faster than rtk. 1,231x faster than grep. + +0.065ms code search. Pre-built trigram index. Query once, instant forever. + +21 issues closed. 14 PRs merged. 7 contributors. One weekend. + +--- + +Tweet 2 (The numbers) + +Benchmarked on rtk-ai/rtk (329 files): + +codedb search: 0.065ms +rtk: 37ms +ripgrep: 45ms +grep: 80ms + +codedb word lookup: 0.013ms. That's 13 microseconds. For an exact match across 329 files. + +First index: 126ms. Then sub-millisecond everything. Forever. + +--- + +Tweet 3 (What changed) + +36% faster indexing. 59% less CPU. 47% less memory. + +Integer doc IDs replaced string HashMaps in the trigram index. Batch-accumulate per file. Skip whitespace trigrams. Sorted merge intersection with zero allocations. + +481ms → 310ms indexing on 5,200 files. Dense queries 63% faster. Pure Zig. No magic. + +--- + +Tweet 4 (Security) + +Also shipped a full security audit this release. + +Blocked .env and credentials from MCP read/edit tools. +Fixed SSRF in codedb_remote. +Added SHA256 checksum verification to the installer. +Telemetry hardened — argv-based curl, no shell injection. + +macOS binary is now codesigned AND notarized. First time. + +--- + +Tweet 5 (Memory) + +Your MCP server was eating 2.5GB on a 5k file repo. + +Now it releases file contents after indexing. Zero-copy ContentRef for search — borrows from cache, reads from disk when evicted. + +447MB → 234MB at 40k files. -47%. + +Large repos (>1000 files) auto-release. Small repos keep everything in RAM. No config needed. + +--- + +Tweet 6 (Fixes) + +Python deps finally work. +TypeScript block comments don't produce ghost symbols. +Triple-quote docstrings don't fool the parser. +Linux installer doesn't choke on Dash. +MCP idle timeout is 2 minutes, not 30. +Duplicate MCP servers get detected. +Exit crash from double thread join — fixed. + +21 bugs. 14 PRs. Zero regressions. + +--- + +Tweet 7 (CTA) + +Update now: + +curl -fsSL https://codedb.codegraff.com/install.sh | bash + +Or just run: codedb update + +macOS (codesigned + notarized) and Linux x86_64. +SHA256 checksums included. +Auto-registers in Claude Code, Codex, Gemini CLI, Cursor. + +codedb.codegraff.com/update + +--- + +Alt: Single tweet + +codedb v0.2.52: 538x faster than ripgrep on code search. + +36% faster indexing. 47% less memory. Full security audit. Python/TS parser fixes. macOS notarized. + +21 issues closed by 7 contributors in one session. + +curl -fsSL https://codedb.codegraff.com/install.sh | bash + +--- + +Alt: Thread opener (punchy) + +538x faster than ripgrep. +569x faster than rtk. +1,231x faster than grep. + +codedb doesn't scan your files. It already knows. 0.065ms. + +Thread on what we shipped in v0.2.52 👇 diff --git a/src/main.zig b/src/main.zig index d138754..be48888 100644 --- a/src/main.zig +++ b/src/main.zig @@ -87,7 +87,7 @@ fn mainImpl() !void { // Handle --version early (no root needed) if (std.mem.eql(u8, cmd, "--version") or std.mem.eql(u8, cmd, "-v") or std.mem.eql(u8, cmd, "version")) { - out.p("codedb 0.2.52\n", .{}); + out.p("codedb 0.2.53\n", .{}); return; } diff --git a/src/telemetry.zig b/src/telemetry.zig index f9bd5cd..791b2d9 100644 --- a/src/telemetry.zig +++ b/src/telemetry.zig @@ -5,7 +5,7 @@ const index = @import("index.zig"); const RING_SIZE = 256; const CLOUD_URL = "https://codedb.codegraff.com/telemetry/ingest"; -const VERSION = "0.2.52"; +const VERSION = "0.2.53"; const PLATFORM = std.fmt.comptimePrint("{s}-{s}", .{ @tagName(builtin.os.tag), @tagName(builtin.cpu.arch) }); pub const Event = struct { diff --git a/website/app/update.zig b/website/app/update.zig new file mode 100644 index 0000000..e4fc550 --- /dev/null +++ b/website/app/update.zig @@ -0,0 +1,243 @@ +const mer = @import("mer"); + +pub const meta: mer.Meta = .{ + .title = "What's New in v0.2.52", + .description = "36% faster indexing, 59% less CPU, 47% less memory, 21 issues closed.", +}; + +pub const prerender = true; + +pub fn render(req: mer.Request) mer.Response { + _ = req; + return .{ + .status = .ok, + .content_type = .html, + .body = html, + }; +} + +const html = + \\ + \\ + \\
+ \\ + \\ + \\Searching for “agent” across 329 files. rtk is a Rust-based code search tool. codedb uses a pre-built trigram index for sub-millisecond queries after a one-time 126ms index.
+ \\codedb keeps a pre-built trigram index in memory. Other tools scan from disk on every query. Apple M4 Pro, macOS, codedb v0.2.52, rtk 0.1.0, ripgrep 15.1, GNU grep. 5 runs, median.
+ \\codedb_read and codedb_edit now block .env, credentials, keys, .pem files via MCP tools.
codedb_remote validated against whitelist. Installer now verifies SHA256 checksums after download.
Trigram postings use u32 doc IDs instead of string HashMaps. Sorted merge intersection with zero allocations.
Local HashMap per file, bulk-insert to global index. Skip whitespace-only trigrams (12% of occurrences).
Release file contents after indexing. Zero-copy ContentRef for search. 47% less memory at 40k files.
Triple-quote docstrings, block comments, import alias handling. Fixed dependency matching for Python imports.
2-minute idle timeout. Singleton PID lock. Fixed crash on exit (duplicate thread join). Linux /bin/bash update.
Added codedb_bundle, codedb_remote, codedb_projects, codedb_index. CLI commands table in README.
macOS Apple Silicon (codesigned + notarized) · Linux x86_64 · SHA256 checksums
+ \\