Rocky: An Open-Source Coding Agent with Minimal Architecture and Native DeepSeek Integration

Rocky is a minimal open-source coding agent with native DeepSeek search, local trajectory storage, and built-in SWE benchmarks.
Rocky is an open-source coding agent built for simplicity and transparency, with a core Python loop of just a few hundred lines and a system prompt under 1,000 tokens. It natively integrates DeepSeek search and a Deep Research mode for literature surveys, stores all trajectories locally for full auditability, and includes a one-click SWE benchmark harness — making it ideal for learning, experimentation, and reproducible agent research.
Building a Transparent Coding Agent from Scratch
At a time when Claude Code and Codex nearly dominate the coding agent space, two developers with algorithmic backgrounds (Bilibili creators CC and Dudu Xuejie) spent about two months of spare time building an open-source coding agent called Rocky. Its positioning is refreshingly distinct — not to outcompete Claude Code, but to create a simple, transparent, and quantifiable coding agent experimentation framework.
The name Rocky comes from a character in the sci-fi novel Project Hail Mary — an enthusiastic, boundary-challenged alien spider engineer. That personality made it into the product: Rocky displays little animated musical notes while working, and occasionally gets overly eager and runs your entire test suite when you only asked it to "take a look" at the code.

The authors' most striking realization was this: something built with just one or two thousand lines of code actually works. Opening the repo and seeing "such a simple loop can actually run" speaks volumes about how capable today's models already are. This is one of Rocky's core value propositions.
Minimal Architecture: What Can a Few-Hundred-Line Loop Do?
Rocky's most compelling feature is its tiny codebase. Written entirely in Python, it's a fraction of the size of other coding agents: the core loop is only a few hundred lines, and the system prompt is just 30–50 lines (roughly 300–500 tokens) — under 1,000 tokens total.
For comparison, Kimi's system prompt is about five to six times longer, and tools like OpenCode and Claude Code have codebases in the hundreds of thousands of lines (Claude Code is around 500K lines), making them notoriously difficult to navigate. Rocky keeps the entire loop transparent — whether you want to use it directly or learn how a coding agent works, the barrier to entry is extremely low.
One notable implementation detail: the final version of Rocky uses a plain while-true loop rather than more complex mechanisms like ReAct or Reflection. ReAct (Reasoning + Acting), proposed by Google Research in 2022, interleaves a language model's reasoning chain with tool calls to theoretically improve decision quality. Reflection lets an agent self-evaluate after each step and dynamically adjust its strategy. However, the authors found in small-scale SWE-verified benchmark tests (20/50/100 samples) that these additions produced differences that "weren't statistically significant," so they opted for the principle of keeping things as simple as possible. These mechanisms add token consumption and latency without always delivering measurable engineering gains.
This gets to a fundamental question: why does such a small loop actually work? Rocky provides a reproducible, locally inspectable answer that you can take apart and learn from.
Native DeepSeek Search and Deep Research Mode
One of Rocky's standout features is its deep integration with DeepSeek's native search capabilities. This addresses a real pain point: if you use Codex or Claude Code with a third-party model, built-in search typically breaks; with open-source tools like OpenCode, search usually requires a paid membership or manually wiring up MCP or a search API.
Rocky calls DeepSeek's native search directly. Users only pay DeepSeek's API fees and get search out of the box. Search requests are parallelized for speed, and costs are kept very low (the search step uses the Flash model).
Building on this, Dudu Xuejie led the development of a Research Mode, which includes two sub-modes: Deep Research and Learn. In the authors' tests, asking Rocky to survey a cutting-edge concept like "RSI (Recursive Self-Improvement)" returned around 80 references and generated a structured hierarchical document in a single pass, at a cost of roughly 1 RMB.
The authors also ran an interesting cross-validation: they handed Rocky's 70+ returned links to GPT for verification one by one, and found 63 fully correct, 10 partially correct, 6 incorrect, and 2 missing — a notably high link accuracy rate. Dudu Xuejie added a key perspective: for genuine deep research, recall (returning enough valuable references) often matters more than raw precision. This reflects the classic precision-recall tradeoff in information retrieval: precision measures how many returned results are relevant, while recall measures how many relevant results were actually found. In academic research contexts, missing a key paper is far more costly than returning a few noisy extras — researchers can filter out redundancies, but they can't discover papers they never knew existed. Returning 80 papers in a first pass that cover the canonical literature is already impressive, and tools like Codex typically won't do this in one shot.
Strict Sandboxing and Local Trajectory Persistence
Safety is a design priority that's repeatedly emphasized in Rocky. The authors have personally experienced the nightmare of Claude Code and Codex deleting local branches "before you even realized what happened" — and Rocky has done similar things to itself. As a result, Rocky implements a fairly heavyweight sandboxing mechanism:
- Docker-based sandbox; the feature is unavailable if Docker isn't installed
- Supports being called via SSH by other AI agents, but those too are confined to the sandbox
- All potentially "dangerous" features (memory, dream, proactive reminders) are off by default

Another core design decision is local trajectory persistence. In reinforcement learning for large language models, a trajectory refers to the full sequence of states, actions, and rewards from when an agent receives a task to when it completes it — this is the core data used to train reward models and optimize policies. Rocky has no server side; it's a purely local TUI client. All search and model requests go to the model's API endpoint, while everything else is stored locally in a .rocky-code folder. This brings exceptional transparency: users can pull up usage history at any time, ask Rocky to write a Python script analyzing their most frequent use patterns, or compare local trajectories to understand "why a particular run didn't return the expected result."
The authors note that exporting full chat logs from Codex is painful — tool calls and conversations are stored separately in an extremely complex format — while Rocky is "like a transparent spider," with its entire execution visible at a glance. One caveat: trajectory storage can quietly consume significant disk space.
Built-in Benchmarks and a Co-Evolution Vision

What sets Rocky apart from ordinary coding tools is its built-in one-click benchmark harness. The authors' original goal was simple: how does a bare model compare to a model plus harness on a benchmark?
- SWE-verified: Introduced by Princeton University in 2023, this benchmark is built from real GitHub software engineering issues and requires AI systems to automatically fix bugs and pass corresponding unit tests. An expert review process filters out ambiguous problems, making it one of the most realistic Coding Agent evaluation benchmarks available. The authors tested 100 problems and averaged around 80 points over two runs, close to DeepSeek-V4-Pro's official 80+ score. The authors are careful to note this only shows "the harness doesn't hurt the model" — not that the harness itself is exceptional.
- Deep-SWE: A stricter new benchmark where DeepSeek-V4's official score is around 8%, and all current models effectively "fail." The authors ran 20 problems and currently score 0 — partly due to bugs in their own code, partly due to step-count limits (execution terminates if the step cap is exceeded).
For tools like Codex to participate in evaluations requiring Docker, you'd need to write additional scripts and navigate multiple layers of indirection. Rocky "runs with just a few code tweaks," making it function more like a bundled Agent experimentation environment and educational reference.
The longer-term vision involves co-evolution between model and harness. The authors believe the harness can't improve on its own — it needs trajectory data to drive long-horizon reinforcement learning training. Rocky's trajectory persistence mechanism is fundamentally a minimal offline RL data pipeline, following the same trajectory replay philosophy used by DeepMind, OpenAI, and others in agent training, just dramatically simplified in scale and complexity. Rocky is essentially a prototype of a small RL training environment, with experimental components already stubbed in — self-reflection, routine distillation, memory, and a "dreaming mechanism" for prioritizing memory importance. But the authors offer an apt analogy: it's like having an engine to build a spaceship — the ship can fly faster than light, but parts might fall off along the way. The RL components aren't built yet, and individual users would struggle to accumulate enough training data anyway.
Who Should Use Rocky

Based on the authors' real-world experience, Rocky is best suited for the following use cases:
- Research and lightweight tasks: Literature surveys, writing visualization scripts, and other lower-volume coding work — low cost (pay DeepSeek API rates, no expensive subscription), fast execution
- Learning and teaching: The ideal hands-on reference for understanding "how a minimal coding agent actually works"
- Reproducible Agent benchmark experiments: One-click benchmark runs, inspectable trajectories, easy to modify and extend
Known limitations are equally clear: Rocky has weak support for large, complex codebases. LSP functionality is off by default (requires manual activation), and relying solely on grep/glob to search large codebases is error-prone. Additionally, switching between Chinese and English prompts or between modes flushes the cache — but given the already-low overall cost, the authors consider this acceptable cache-miss overhead. "Task completion comes first."
Worth noting: the team has also developed a VS Code extension and an experimental formal verification feature based on Lean4. Lean4 is a next-generation theorem prover developed by Leonardo de Moura at Microsoft Research, used by the mathematics and computer science communities to build machine-verifiable proofs. DeepSeek's Prover series of models were trained in the Lean4 environment and demonstrated near-professional-mathematician-level reasoning on IMO-level problems. Integrating Lean Prover into a coding agent framework represents a frontier direction: enabling AI to not only write code but to provide formal guarantees of correctness — with significant implications for safety-critical systems in aerospace, finance, and cryptography. These forward-looking, experimental features make Rocky not just a tool, but an open laboratory for observing the boundaries of AI capability.
For individual developers, Rocky's greatest value may not be "training your own model" — it's the complete transparency. You can see exactly how an agent works, how it scores on benchmarks, and how it fails. That's precisely what most closed-source or bloated commercial tools simply cannot offer.
Key Takeaways
Related articles

Network Doctor: An Open-Source Terminal Tool for Network Fault Diagnosis
Network Doctor is an open-source terminal network diagnostic tool that integrates ping, dig, curl, and traceroute, automatically detecting connectivity in stages and outputting fault conclusions in natural language.

LangChain Guardrails Explained: Building Safe and Controllable AI Agents
A detailed guide to LangChain Guardrails covering layered ecosystem architecture, middleware implementation, deterministic and model-driven protection for building production-grade secure AI Agents.

Deep Dive into Microsoft's AI Security Tools: Does Performance Really Surpass the Competition?
Microsoft launches enterprise AI security tools claiming superior performance. This deep analysis examines core capabilities, ecosystem advantages, and risks to guide enterprise security decisions.