~/sophana-sokopen to SWE · Data · AI/ML
Sophana Sok
ships terminal tools, data pipelines, and the tests that prove them.writes Rust and TypeScript that ships to package registries, with the tests to show for it.builds pipelines whose numbers you can audit, from scrape to dedupe to export.measures what LLMs actually cost per passing test, and runs them locally to find out.
I build terminal tools in Rust, data pipelines in Python and TypeScript, and the tests that keep them honest. Everything on this page is public, versioned, and counted by a command you can run yourself.
now · Data Specialist doing data QA · B.S. Computer Science, WGU
A terminal dashboard listing four flagship projects with their headline numbers. ai-usage-tui: 532 tests; marquee-markdown: 897 tests; JSON Data Drift Analyzer: 2,682 assertions; Compiled: 60 sources.
| name | lang | proof | lines |
|---|---|---|---|
| ai-usage-tui | Rust | 532 tests | 27k |
| marquee-markdown | Rust | 897 tests | 28k |
| JSON Data Drift Analyzer | TypeScript | 2,682 assertions | 33k |
| Compiled | Python | 60 sources | 2.4k |
- role
- Data Specialist doing data QA · B.S. Computer Science, WGU
- open to
- Software, Data and AI/ML engineeringSoftware EngineeringData EngineeringAI / ML Engineering
- lens
- all workSWE viewData viewAI/ML view
every number above names the command that counted it
00proof
Numbers you can recount, not adjectives.
ai-usage-tuiv0.15.0
- crates.ioregistry
- Homebrew taptap
- Scoop bucketbucket
- PKGBUILDrelease asset
- Chocolatey packagerelease asset
marquee-markdownv0.11.1
- crates.ioregistry
- Homebrew taptap
- Scoop bucketbucket
- nixpkgs (in review)in review
JSON Data Drift Analyzerv1.8.0
Compiledv0.2.0private repo
- 60
- sources
- 108
- tests
- 2,353
- lines of Python
- 1,357
- lines of tests
- Live on Fly.iolive
How these numbers were counted
Each figure was produced by the command beside it, run in the repository at the tag named, on the date shown. Hover a number for the same text. Nothing here is estimated or rounded up.
ai-usage-tui verified 2026-09-03
- 532 tests
grep -rhoE '#\[(tokio::)?test\]' src tests | wc -l, at tag v0.15.0recount ↗ - 27,194 lines of Rust
git ls-files 'src/*.rs' | xargs cat | wc -l, at tag v0.15.0 - 233 commits
git rev-list --count HEAD, at tag v0.15.0recount ↗ - 16 releases
gh api repos/SophanaSok/ai-usage-tui/releases --jq lengthrecount ↗
marquee-markdown verified 2026-09-03
- 897 tests
grep -rhoE '#\[(tokio::)?test\]' src tests | wc -l, at tag v0.11.1recount ↗ - 27,743 lines of Rust
git ls-files 'src/*.rs' | xargs cat | wc -l, at tag v0.11.1 - 109 commits
git rev-list --count HEAD, at tag v0.11.1recount ↗ - 16 releases
gh api repos/SophanaSok/marquee-markdown/releases --jq lengthrecount ↗
JSON Data Drift Analyzer verified 2026-09-03
- 2,682 assertions
git ls-files | grep -E '\.(test|spec)\.tsx?$' | xargs grep -hoE '\bexpect\(' | wc -l, at tag v1.8.0 - 84 test files
git ls-files | grep -cE '\.(test|spec)\.tsx?$', at tag v1.8.0 - 33,287 lines of TypeScript
git ls-files 'src/*.ts' 'src/*.tsx' | xargs cat | wc -l, at tag v1.8.0 - 196 commits
git rev-list --count HEAD, at tag v1.8.0recount ↗ - 9 releases
gh api repos/SophanaSok/json-data-drift-analyzer/releases --jq lengthrecount ↗
Compiled verified 2026-09-03
- 60 sources
grep -cE '^\s*Source\(' compiled/sources.py, at tag v0.2.0 - 108 tests
grep -c 'def test_' tests/*.py, summed, at tag v0.2.0 - 2,353 lines of Python
git ls-files 'compiled/*.py' | xargs cat | wc -l, at tag v0.2.0 - 1,357 lines of tests
git ls-files 'tests/*.py' | xargs cat | wc -l, at tag v0.2.0
01projects
Four flagships, each shipped, versioned and tested.Ranked for a software engineering reader.Ranked for a data engineering reader.Ranked for an AI/ML engineering reader.
01ai-usage-tui
What each AI coding model actually costs per passing test.
27k lines of Rust with 532 tests, released through crates.io, a Homebrew tap and a Scoop bucket from one CI pipeline, across sixteen releases.
Six unlike usage logs, a SQLite database, tailed JSONL sessions and a telemetry file, normalised into one priced model where an unknown rate stays unknown instead of becoming $0.00.
Measures cost per passing test per model, so routing and escalation decisions rest on delivered results rather than token counts.
A terminal dashboard that reads the local usage logs of Claude Code, Codex CLI, GitHub Copilot, Gemini CLI, OpenCode and Ollama and answers a harder question than token counts: was the expensive model worth it? A shipped Claude Code hook turns real test runs into pass/fail events, so cost is measured per delivered result, with retry, escalation and review-defect rates beside it. A cost the tool cannot establish stays unknown rather than rendering as $0.00. Everything is read locally; nothing is sent anywhere.
- 532
- tests
- 27,194
- lines of Rust
- 233
- commits
- Rust
- ratatui
- SQLite
- JSONL tailing
- GitHub Actions
- cargo-dist-style releases
02marquee-markdown
A terminal markdown reader with a contents pane that knows where you are.
A 27k-line Rust TUI with 897 tests and sixteen releases: a markdown renderer written against a cell grid, packaged for crates.io, Homebrew and Scoop, with a nixpkgs submission in review.
A glow-compatible reader that renders markdown the way a document viewer does: a centred reading column on a painted page, typographic headings, sealed code cards, box-drawn tables, and a table-of-contents pane that tracks the scroll and folds sections. It reads files, directories, standard input, URLs and github.com/owner/repo, reloads on save, searches in place, and ships ten themes as TOML data. Linux, macOS and Windows.
- 897
- tests
- 27,743
- lines of Rust
- 109
- commits
- Rust 2024
- ratatui
- crossterm
- pulldown-cmark
- TOML themes
- vhs
03JSON Data Drift Analyzer
Turns "something looks off about this run" into an evidenced answer.
33k lines of TypeScript and React 19 with 2,682 test assertions, Playwright end-to-end runs that include axe accessibility checks, a Web Worker analysis path and a build-time Content Security Policy.
Diffs two pipeline exports record by record, separates systemic field loss from scattered drift, and recovers only what a per-source policy allows, with provenance on every value.
A browser-first QA tool for scraped-data pipeline exports. Upload a known-good baseline and a suspect latest export; it diffs them record by record, separates systemic field loss (a broken selector) from scattered drift, recovers only what a per-source policy allows, routes everything else to a human decision queue with an append-only log, and produces six audit-ready artifacts with a SHA-256 manifest. Everything runs in a Web Worker in your browser. No backend, no upload, no telemetry.
- 2,682
- assertions
- 84
- test files
- 33,287
- lines of TypeScript
- TypeScript
- React 19
- Vite
- Zustand
- Dexie / IndexedDB
- MiniSearch
- Web Workers
- Playwright
- axe-core
- Tailwind
04Compiled
Sixty tech sources, scraped concurrently, deduplicated three ways, served from SQLite.
An async Python 3.12 service on FastAPI and httpx with 108 tests, a Dockerfile, a health check, and a Fly.io deployment that refreshes itself every twenty minutes.
Sixty sources fetched concurrently behind a semaphore with backoff, three-pass dedupe (canonical URL, title fingerprint, Jaccard above 0.85), idempotent WAL upserts, FTS5 search and keyset pagination.
Near-duplicate detection by token-set Jaccard similarity inside a two-day window, and weighted keyword scoring across thirteen categories, with the thresholds written down and tested.
A news aggregator that fetches sixty tech blogs and news sites behind a semaphore with exponential backoff, parses feeds and listing pages with BeautifulSoup, deduplicates by canonical URL, title fingerprint and token-set Jaccard similarity, scores thirteen categories from weighted keyword tables, and serves the result through a FastAPI REST API and a dependency-free web UI on SQLite with FTS5 search. Dockerised and running on Fly.io, refreshing itself every twenty minutes.
- 60
- sources
- 108
- tests
- 2,353
- lines of Python
- Python 3.12
- FastAPI
- httpx (async)
- BeautifulSoup
- SQLite WAL + FTS5
- Docker
- Fly.io
- uv
Case study →private repo · source on requestLive ↗
otacliPython
A terminal anime client, forked with its licence honoured. Explicit COPYRIGHT attribution to the upstream project, kept under the GPL-3.0 the original chose.
source ↗postings-qaPython
A job-postings pipeline with a data-QA core: every rejected row says why. Every rejected listing carries the names of the checks it failed and the reason text, so a filter decision can be inspected rather than trusted.
source ↗oneplusoneTypeScript
A math skill tree that tunes its own difficulty with Elo. Elo per skill, not per player, so difficulty adapts per topic and a proficiency trial gates each unlock.
private repobrick-breakerC++
Breakout in C++20 and raylib, with a boss fight. Endless campaign generated procedurally from JSON level definitions, with a hand-built mecha boss.
private repoalgebraicLua
A roguelike deckbuilder where solving algebra is the combat. Invalid mathematics is never rewarded: a card that breaks equivalence cannot be played, and a wasted move collapses the streak.
private repo
Every project here is public on GitHub or live at a URL you can open. Private repositories are marked and available on request. The full table →
02skills
Only what the work above can show.
01Systems & tooling
- Rust
- two TUIs, 55k lines, 1,429 tests between them
- ratatui / crossterm
- cell-grid layout, titled blocks, themes as data
- TypeScript & React 19
- a 33k-line browser app with a Web Worker core
- C++20 / raylib, Lua / LÖVE
- games, for the languages without a safety net
- Release engineering
- crates.io, Homebrew, Scoop, nixpkgs; one CI pipeline per repo
- Testing
- #[test] on every module, Playwright + axe end to end, doctest
02Data & pipelines
- Python 3.12, async httpx, FastAPI
- sixty sources behind a semaphore, backoff and caps
- SQLite
- WAL, FTS5, keyset pagination, idempotent upserts by constraint
- Dedupe & matching
- canonical URL, title fingerprints, Jaccard; deterministic key matching
- Data QA
- drift vs. systemic field loss, policy-gated recovery, provenance on every value
- IndexedDB / Dexie, Web Workers
- analysis cached by content hash, tables virtualised
- Ops
- Docker, Fly.io, health checks, in-process scheduling
03LLMs & inference
- Cost per delivered result
- per-model cost per passing test, escalation and retry rates
- Six agent integrations
- Claude Code, Codex CLI, Copilot, Gemini CLI, OpenCode, Ollama
- Local inference
- llama.cpp and Ollama on a 16 GB GPU; VRAM budgeting, one model at a time
- Tokens and sampling
- tokenizers, logprobs and attention studied on the model, not the slides
- Similarity & scoring
- token-set Jaccard for near-duplicates, weighted keyword categorisation
- Adaptive systems
- per-skill Elo targeting a success rate, spaced repetition
Not claimed: model training, fine-tuning, or CUDA kernels. The LLM work here is on the inference and economics side, on local hardware and in production cost data.
03writing
- What a Max subscription boughtA month of real usage, priced per passing test, on the ai-usage-tui site.
- Why not glowThe case for a contents pane, and what it took to keep glow’s keys.
- Privacy modelWhy a QA tool for someone else’s data has to run entirely in the browser.
04contact
Open to Software, Data and AI/ML engineeringSoftware EngineeringData EngineeringAI / ML Engineering roles. The fastest way to judge the work is to read it.