Projects

Work spanning machine learning, distributed systems, and software engineering.

AI Deep Dive

AI Deep Dive is an open-source AI/ML learning platform. Its flagship course, Build GPT from Scratch, walks learners from tokenization through a full Transformer implementation across 11 chapters, 20 coding challenges, and a four-part capstone project that trains a GPT-2 model.

  • Designed challenge evaluation to run in two modes: lightweight problems run in the browser via Pyodide for instant feedback, heavier ones run on a server-side judge
  • Wrote the server-side judge as a warm-fork executor with cgroup v2 memory limits, seccomp-bpf syscall filters, and per-job resource caps for sandboxing user code
  • Built the frontend in Next.js and TypeScript, with course content authored in MDX, KaTeX for math rendering, inline visualizations, and an in-browser code editor (Monaco with Vim mode)
  • Deployed to production with Prometheus and Grafana monitoring, alerting, and automated backups
PyTorch Transformers Pyodide Sandboxing FastAPI Next.js TypeScript Deep Learning Redis Streams Docker Prometheus Grafana

Remux

Remux is a native iOS tmux client that maps tmux's session model directly into iOS. Windows and panes run as native iOS views, the terminal renders through a modified libghostty, and a custom control-mode client drives tmux over SSH.

  • Designed an iOS-native UI for tmux primitives: each window and pane has its own native view, with a switcher that shows a live render of every pane
  • Embedded libghostty's C runtime in iOS, with framework-level changes to support terminal surfaces driven by tmux instead of by local subprocesses
  • Built a custom implementation of tmux's control-mode protocol to drive sessions, windows, and panes natively from the app
  • Designed pane state to persist across UI presentation, so switching panes is instant and running jobs, scroll history, and editor state are preserved
  • Implemented SSH auth and trust handling: password and key-based login, on-device key generation, Keychain-stored credentials, and host-key-change warnings
iOS Swift tmux libghostty SSH SwiftUI Swift Concurrency UIKit Keychain

kbolt

kbolt is a local-first retrieval engine in Rust for notes, docs, and source code across 11+ programming languages. It runs as a single binary that indexes a project, serves hybrid retrieval with optional reranking, and exposes the same engine to humans through a CLI and to coding agents through a native MCP server.

  • Designed kbolt to keep indexes live as content changes, with file watching for incremental updates, gitignore-style excludes, and scheduled re-indexing
  • Implemented four search modes (keyword, semantic, hybrid with three fusion strategies, and deep with LLM query expansion), with optional cross-encoder reranking
  • Built pluggable inference so embeddings, reranking, and query expansion can each run on a managed local LLM or any OpenAI-compatible endpoint
  • Exposed the engine through a CLI for direct queries and a native MCP server for coding agents
  • Released on Homebrew (`brew install h3nock/kbolt/kbolt`) and Cargo
Rust RAG MCP Vector Search Hybrid Retrieval Semantic Search Embeddings Reranking BM25

Transformer + RoPE

From-scratch PyTorch implementation of the original Transformer (Vaswani et al., 2017). Trained a 65M-parameter model on WMT14 English-German with multi-GPU DDP, then extended it with Rotary Positional Embeddings (RoPE), improving BLEU from 25.53 to 25.97 with no additional parameters.

  • Implemented Transformer from scratch (~65M params, 6+6 layers), including joint BPE tokenization and beam search decoding
  • Trained for ~140K steps (~15B tokens) on 6x V100 GPUs with multi-node PyTorch DDP, using the Noam LR schedule with 4K-step warmup; tracked with Weights & Biases
  • Extended multi-head attention with Rotary Positional Embeddings (Su et al., 2021), implementing cached frequency-based rotation matrices for query and key embeddings
  • Compared baseline and RoPE runs with the same training recipe, beam search, and sacreBLEU on WMT14 En-De; BLEU improved from 25.53 to 25.97 (+0.44)
PyTorch Transformers RoPE Distributed Training NLP Weights & Biases Python

Scriptify: Handwriting Synthesis from Text

End-to-end handwriting synthesis system that generates realistic handwriting from text. Uses a custom deep learning model (~5M parameters) for synthesis, a FastAPI backend for inference, and a React frontend for live rendering.

  • Trained an attention-based LSTM with a Gaussian Mixture Model output layer in PyTorch, following Graves' handwriting synthesis paper
  • Optimized inference for real-time generation with TorchScript compilation and quantization
  • Served the model through FastAPI with a React frontend and interactive canvas for live rendering and stroke animation
PyTorch Deep Learning LSTM TorchScript FastAPI React Python

MYA: My Assistant

Personal AI assistant that unifies search and management across email, calendar, tasks, and local files. Uses a hybrid RAG pipeline (BM25 + semantic embeddings + Reciprocal Rank Fusion) for retrieval, an LLM-powered email intelligence engine, and multi-interface access through web, CLI, Raycast, and Chrome extension.

  • Built a RAG pipeline with hybrid retrieval combining BM25 keyword search, dense semantic embeddings, and Reciprocal Rank Fusion for cross-source retrieval
  • Built an email intelligence engine with LLM-driven priority scoring, auto-classification, labeling, and context-aware draft generation
  • Designed a pluggable LLM provider layer supporting OpenAI, Groq, and Ollama for local inference
  • Developed a FastAPI async backend with ChromaDB for vector storage, SQLite for metadata, and APScheduler for background indexing
  • Built a Next.js web dashboard with email triage, calendar briefings, task management, and daily digest views
  • Built CLI (Typer + Rich), Raycast extension, and Chrome extension for multi-interface access
  • Integrated Gmail, Google Calendar, and TickTick APIs with OAuth, background sync, and notification scheduling
RAG LLMs ChromaDB Python FastAPI OpenAI Next.js TypeScript BM25 Groq OAuth

Distributed Task Queue

Distributed task queue for offloading work to background workers. Features at-least-once delivery, priority queues, exponential backoff with Dead-Letter Exchange, and PostgreSQL-backed result storage.

  • Designed the end-to-end pipeline (API, broker, workers, result store) with at-least-once delivery and idempotency guarantees
  • Implemented durable queuing with manual ACK/NACK and persisted results before ACK to prevent lost work during failures
  • Exposed a REST API for job submission, status retrieval, and health checks
  • Implemented automatic retries with exponential backoff (5s to 1h) using RabbitMQ TTL and Dead-Letter Exchange
  • Designed priority queuing (default/high) with tuned worker prefetch/concurrency to balance throughput and latency
  • Stored task status, attempts, timestamps, and results in PostgreSQL with optional idempotency keys
  • Integrated Prometheus metrics and a lightweight dashboard for observability
Go RabbitMQ PostgreSQL Docker Prometheus Grafana

HDFS Cloud Starter

Deploys a multi-node Hadoop HDFS cluster on GCP with a single command. Uses Terraform for infrastructure provisioning and Ansible for configuration management, orchestrated by a shell script.

  • Provisioned VMs, networking, and firewall rules on GCP using Terraform
  • Wrote Ansible playbooks to automate Hadoop installation, Java setup, SSH config, and user creation across nodes
  • Generated Ansible inventory dynamically from Terraform outputs to bridge provisioning and configuration
  • Created a unified bash script to orchestrate end-to-end infrastructure provisioning and cluster setup
  • Added a test MapReduce job (word count) to validate the deployed cluster
Terraform Ansible GCP Hadoop HDFS MapReduce Bash Python

Kafka-Lite

Kafka implementation in Java built through the Codecrafters challenge. Supports TCP networking, binary wire protocol parsing, API version negotiation, concurrent clients, and message consumption via Fetch. Producer functionality in progress.

  • Built a TCP server in Java handling multiple concurrent client connections
  • Implemented Kafka's binary wire protocol parsing with correlation IDs and API version negotiation
  • Added DescribeTopicPartitions and Fetch request handling for reading messages from disk
  • Currently implementing the Produce API for message publishing
Java Distributed Systems TCP Networking Kafka Protocol

Neural Network From Scratch

Neural network library built from scratch in NumPy with modular layers supporting MLPs, RNNs, and CNNs. Handles forward/backward passes, multiple optimizers, and full backpropagation.

  • Implemented core architectures (MLP, RNN, CNN) with forward and backward passes in pure NumPy
  • Wrote activation functions (ReLU, Sigmoid, Softmax, Tanh) and loss functions for regression (MSE, MAE) and classification (Cross-Entropy)
  • Added He and Xavier weight initialization for stable gradient flow during training
  • Built data loaders and preprocessing utilities for training pipelines
NumPy Python Machine Learning Pytest