LapClusters: Turn a Team’s Laptops into a Private AI Code Review Cluster
A local AI model keeps code on your own machines, but one laptop can take a long time to review a whole repository. Cloud review can be faster, but it may send private code outside your team and add per-request costs.
We built LapClusters to spread that work across the laptops a team already owns.
How it works
One laptop acts as the host. It collects supported source files from a local folder or Git URL and puts one review task per file into a Redis Streams queue. Each worker laptop runs its own Gemma 4 model through Ollama and pulls a task when it is ready.
The workers return structured findings. LapClusters combines them into one Markdown report, ordered by severity and including file paths and line numbers. Worker heartbeats help the cluster detect a laptop that has dropped out, so another worker can take over its abandoned task.
The approach is different from splitting one large model across several machines: every laptop runs a complete model, and the cluster distributes independent tasks.
What we built
A Redis Streams task queue with task status tracking
Ollama workers that review files with Gemma 4 locally
Host discovery for laptops on the same network
Heartbeats and recovery for abandoned work
A local browser interface for starting reviews, seeing connected laptops and active files, following progress, viewing findings, and downloading the report
A command-line tool for sending a single prompt through the cluster
We ran the backend across two laptops over a phone hotspot. A four-laptop run and a formal performance benchmark are still planned.
How we built it
The backend uses Python, redis-py, httpx, and python-dotenv. Redis 7 coordinates work, Docker can run Redis, and Ollama serves the local Gemma 4 model. The browser interface uses HTML, CSS, JavaScript, and Python’s standard-library HTTP server.
There are tradeoffs: files are reviewed independently, so the model may miss bugs that span files. The current collector skips unsupported files and source files larger than 20 KB. Findings can be wrong, so they should be checked before acting on them.
Code is sent between team laptops over the cluster network for review; inference uses each worker’s local Ollama model. There is no hosted AI endpoint in the review path.
Repository: https://github.com/VishnuVardhanNk/LapCluster
Demo video: https://youtu.be/QDoHNfAD5zs?si=jhAWyCH7WKOksAnw
Built by [ReLUactivation]:
Members and contributions:
- [Nithin Krishnappa]: [Built the Redis Streams task queue and task status tracking]
- [Vishnu vardhan]: [Implemented the Ollama worker and Gemma 4 review flow, including structured findings]
- [Dheeraj]: [Built the local web interface for cluster status, review progress, and report downloads]
- [Niranjan]: [Integrated repository collection, host discovery, and worker recovery; prepared setup instructions and the demo]
Tags: python, ollama, gemma4, opensource, ai
Top comments (0)