

Just-in-Time Software: When Code Writes Itself

Late last year I first wrote about “just-in-time” software, which explored how software will change in the era of generative AI. Even in the short few months since then, we’ve seen the introduction of diffusion language1 models that have the potential to speed up token output significantly (not to mention faster hardware like Groq2 or Cerebras3) - and more generally, the field continues to speed up with smaller models doing more and bigger models getting faster and more efficient.
Instantaneous code generation that is immediately executed and disposed of is a ways off, but the trajectory we’re on is clear. Per the anecdotal figure below, the following are the three phases of Just-in-time Software (JITS) as AI code-generation continues to improve:
- The copilot stage
- The Just-in-Time Software stage
- The Living Software phase

The Co-Pilot Stage
Code generation has improved substantially in precision, accuracy and utility. However, it remains relatively slow and expensive and is currently most useful as a “co-pilot”. This is the stage that we are currently in, as made possible by the stellar offerings from companies like Cursor, Windsurf and even Codex/Cline style coding agents. The copilot modality is powerful, but it still involves the fundamental supervision loop where a human operator or team directs the generation of code with the intent of producing a stationary codebase, which codifies the flow of data, business logic, and user facing functionality.
The copilot stage is still characterized by a traditional approach of building software. Similar to how early automobiles were essentially carriages with engines, the copilot mode still leans on decades of modern software development practices. Much like so-called “motorized carriages” that had to enter a world designed for horses, with large spoked wheels that had to navigate unpaved roads - copilot based code-gen solutions need to interoperate in a world where most code is still written, reviewed and maintained by human beings.
Many engineering decisions in large code bases must be dictated by the scarcity of code - and the fact that code takes significant time/cost to build and maintain. So teams will fall on sword after sword of framework, architecture and design arguments and debates per the need to amortize the high-cost of software development across the anticipated lifetime of their product. As the adage goes, many perfectly designed codebases litter the startup graveyard - ultimately, even the most well intentioned efforts are ill-fated given the real difficulty of finding out what people actually want.
So it is no surprise that copilot-like tools are not just being welcomed, but embraced by most4 software developers. Often when I talk to folks about AI/Code-gen copilots or using LLMs I hear how it has made them 30-50% more efficient. What surprises me is how modest this seems. In my own experience, I find 5-10x speed ups, and I anticipate this to only accelerate.
This all points towards what I anticipate will be the next phase: just-in-time software, where we abandon the tradition of explicitly writing and maintaining a code base in favor of letting code generate itself directly from higher-level manifest - which is a collection of specifications, verifications, and requirements.
Just-in-Time Software
As code generation becomes faster and cheaper, the act of supervising an IDE or managing a stationary code base will become obsolete. This shift will fundamentally upend how we think about building software in the coming years.
Convergent software leverages the increased speed and reduced cost of AI code generation to iteratively produce stable solutions from a manifest of specifications, verifications, and requirements. Think of it as software that writes and rewrites itself until it meets all defined criteria, the manifest acting like a form of “DNA” that software generates itself from.
I've now observed this firsthand with Zerg, a system we’ve been building capable of converging just-in-time code. Over dozens of independent 3-6 hour generation cycles, Zerg has produced functionally equivalent software solutions that strictly adhere to requirements and integrate seamlessly into production codebases. Each solution looks only slightly different under the hood, but all perform identically - and often the code is so similar it is reminiscent of true convergent evolution5. What makes convergent software remarkable is its ability to adapt to environmental changes. In software terms, the "environment" includes interfacing systems, dependencies, and evolving requirements. When any of these change, convergent software automatically regenerates itself to meet new constraints, like a living organism adapting to its surroundings.
In this paradigm, the manifest becomes the new programming language. Essentially, the manifest is like a kind of software DNA - which inevitably results in the optimal code as generated by AI. While claims that "English is the new programming language" or "PMs are the new coders," are growing in prevalence, the reality is more nuanced. Such a manifest makes it possible to structure and define desired outcomes over implementation details, similar to how DNA encodes instructions that result in complex organisms through cellular processes.
I dive much deeper into these biological underpinnings below, and this code-free “IDE-less” approach to software development is inevitable in the same way that organisms are able to maintain coherence even though they are largely made up of orders of magnitude smaller components which each individually have no knowledge or influence on one another.
To claim that the future of software will no longer involve coding is bold, I’ve experienced the rise, and subsequent rise of the modern software industry since the early 90s. The software industry has grown into a sluggish and slow moving behemoth that has come to completely undermine its own underpinnings6. Today's software development resembles large infrastructure projects. Teams invest heavily in complex architectures and system designs to amortize high development costs over a product's intended lifespan. This makes sense when projects require thousands of people and years to build, but what if that constraint disappears?
Historically, "spaghetti code", tangled, hard-to-read implementations, has been software development's cardinal sin. While spaghetti code often out-performs clean code, it is nearly impossible for humans to maintain or modify. It is in effect the purest form of "technical debt" that must eventually be paid back by the team through expensive refactoring.
But here's the key insight: nearly every successful production system started as spaghetti code, or accumulated significant technical debt over time. Teams constantly wish they could rebuild systems "knowing what they know now."

Just-in-Time software flips this equation around! If a system can generate functionally equivalent spaghetti code in moments rather than months, human readability becomes irrelevant. The system can even approach theoretical performance limits by optimizing every function, loop, and module to its narrowest possible implementation. When the marginal cost of code generation approaches zero, spaghetti code becomes not just acceptable, it becomes superior.
Living Software
Beyond just-in-time software, which uses “software DNA” to converge on optimal code, lies an even more radical paradigm: living software. As code generation approaches instantaneous speed and zero cost, we can treat code as the direct transformation of intent. Objectives and functionality become operation directly and without persistent or intermediate artifacts. Code generates at the exact moment of need, executes, and is disposed of.
For example - it’s been shown that LLMs can be trained against data generated from compilers, transforming code directly into machine code7. It was already demonstrated by Neural Turing Machines8 that it is possible to train neural networks to approximate algorithms and functions, with the limitation that these models cannot extrapolate past their trained data. However, considering a sufficiently large training corpus which at the time of NTMs were not feasible, it’s possible to consider how an LLM can be used as a universal function space, which can then be navigated using embeddings (akin to embeddings in LLMs) to then used to “look up” various programs/functions.
This is essentially what we're seeing today. Code generation isn't actually code creation, it's sophisticated pattern matching. LLMs project known functions and programs from their training corpus onto a specific problem, by way of projecting their latent representations into incredibly precise outputs. This is why LLMs excel at code generation: they're essentially performing high-dimensional lookups in a vast space of existing solutions, then adapting those patterns to new contexts.
Coupled with the just-in-time paradigm using either specification guided iteration, evolution, or even Monte Carlo methods, it is possible to rapidly converge on a robust and resilient solution that meets and quickly optimizes to the topology of the criteria it’s intended to meet.
Living software will fundamentally change how we think about systems. Instead of pre-designed frameworks and carefully planned structures, systems will follow physics-like principles of least action, always taking the most direct computational path from problem to solution respective to environmental constraints.
Imagine a system that needs to process user data. Rather than routing through pre-built APIs, middleware, and databases, just-in-time software would generate the minimal code necessary to accomplish that specific task at that specific moment, then dispose of it. No persistent infrastructure, no technical debt, no maintenance overhead.
These systems will appear remarkably biological, spontaneous, adaptive, and ephemeral. Like cellular processes that assemble proteins on demand then break them down, just-in-time software will materialize computational solutions only when and where needed. The "architecture" becomes emergent rather than designed, arising naturally from the interaction between requirements and constraints. This represents software's evolution from static monuments to dynamic processes, from building cathedrals to growing organisms.
Generative Just-in-Time Software Through Convergence
Just-in-time generative software represents a fundamental shift from hand-crafted code to iterative, evolved, or even grown solutions. Instead of writing code iteratively and precisely, it is generated iteratively, or even grown under environmental pressures and constraints until converged at a solution that meets our specifications and requirements. Converging to an optimal point means that the software has landed in what we call a preferential state of the environment - this state being defined by a manifest as mentioned above.
This mirrors how biological systems actually work. Even simple organisms like E. coli9 don't operate from static blueprints9. Their DNA functions as dynamic circuitry, constantly responding to environmental conditions. Take the lac operon: when lactose is present, it triggers a genetic circuit that produces enzymes to metabolize it. The same DNA expresses different behaviors based on environmental context.

This principle scales up dramatically. Biological systems converge on holistic organisms made up of hierarchical components, cells within tissues within organs, each operating semi-independently yet contributing to the whole. Remarkably, this complexity emerges without central planning or supervision. The key insight is that convergence happens inevitably under the right conditions. Early Earth's hydrothermal vents created natural ion gradients that bootstrapped the first cellular processes10. These processes inevitably became self-sustaining, evolved genetic circuits, and ultimately produced all life we see today, all without design or oversight.
Environment matters enormously. We haven't found life elsewhere in our solar system because the specific conditions that drive convergence are rare. The same principle applies to software: convergent systems can only emerge in environments that support and select for viable solutions. Preferential states of systems cannot be defined independently of their respective environment, and the same must be true of software and code if we wish it to express from an underlying, more fundamental code that is resilient to varying environments.
In convergent software, code is no longer the end artifact we develop and improve. Instead, it becomes the "facade", the visible boundary of the software11, 12, while the underlying implementation constantly changes. Like biological cells that replace themselves while maintaining the organism's structure, convergent software maintains stable interfaces while its internal implementation evolves.
This requires a new kind of foundational code, software DNA, that defines core specifications and constraints rather than implementation details. This DNA-like code would express different solutions under different environmental pressures, just as the lac operon evolved in E. Coli to produce different proteins based on available nutrients. Our answer to this is the manifest, a collection of specifications, verifications and requirements which when met by a convergent software system such as the one we are building with Zerg, result in a resilient and ever-adapting piece of software13.
Such an underlying convergent software system will maintain its external behavior and interfaces while internally restructuring itself for optimal performance in its current environment. Like living organisms, it appears stable from the outside while constantly adapting internally anytime aspects of the environment or it’s underlying DNA undergoes a change.
Zerg: JITS Convergence Through Iterative Refinement and Exploration
My fascination with feedback systems spans decades, from implementing the Karplus-Strong algorithm to model guitar string resonance14 to building autonomous helicopter stabilization systems15. Indeed, the original Generative Adversarial Network16 (GAN) paper was the watershed AI/ML moment for me. GANs leveraged dueling networks by way of adversarial feedback, and foreshadowed just how powerful generative AI would come to be.
This core principle of handling ongoing feedback underlies nearly all realtime and autonomous systems. So it's unsurprising to me that Zerg, the JITS software system that we are building, has come to embody similar patterns: a "call and response" system that simultaneously addresses various aspects of a problem while iteratively adapting to environmental pushback.
Beyond Single-Dimensional Rewards
Traditional Reinforcement Learning provides a useful framework: an agent exists in an environment with unobservable states, takes actions, and receives rewards. This simple loop has driven massive progress in both RL and LLM training through reward-based optimization17.

The "Reward is Enough" paper by Silver, Sutton et al. even claimed that sufficiently defined reward functions could train networks to arbitrarily optimize any objective18 in the context of an agent operating on an environment, essentially a Universal Approximation Theory19 for environmental interaction. While theoretically sound, this approach has fundamental limitations. RL operates with unidimensional reward signals, forcing complex real-world processes into oversimplified metrics. Even when systems define multiple rewards, they are linearly separable, which falls short of modeling the intricate, non-separable and entangled processes that govern even the simplest real-world environments.
The real world doesn't provide clean and separable reward signals, and thus far there are clear ways to derive defined reward signals from underlying environmental process that do not involve human intervention. Saying we can train networks given perfect rewards is like saying we can solve problems once we've already solved them. The deeper challenge lies in understanding what constitutes as "better" in complex, dynamic, and partially observable environments.
Preferential Environmental States
Instead of artificial reward functions, we should examine how actual systems navigate uncertainty. Even simple organisms like E. coli don't optimize single metrics, they use mechanical-like processes that steer toward preferential environmental states and away from harmful ones.
Consider how E. coli's chemotaxis works: when it detects increasing nutrient concentration, it continues straight; when concentration decreases, it tumbles randomly to find a new direction. No global optimization, no single reward function, just local preferences that collectively produce effective navigation.
This concept of preferential states becomes our foundation for convergent software. Rather than defining what we want to maximize, we define what environmental configurations are preferable and let the system guide itself toward them by way of various strategies.
The Zerg Loop
The Zerg loop implements this through two coupled processes:
Inner Agent Loop: Takes actions on its environment based on specifications and requirements defined in the target manifest. The manifest ultimately delineates what the preferential states are allowing the system to guide/steer itself towards them, not directly or through numerical rewards, but through a mix of specifications, verifications and requirements - such as, for example, unit tests or specifications that outline specific functions or capabilities.
External Environment Loop: Continuously run environmental processes, such as running code against an existing codebase, or analyzing the generated software using static or dynamic tools. This provides ongoing feedback about the current state relative to preferences defined in the manifest, giving the inner loop feedback from the environment to allow it to further guide/steer itself to a preferred state given the target manifest.

Here's a concrete example: Zerg generating a database query optimization system. The manifest specifies preferential states: query response times under 50ms, memory usage below 2GB, successful handling of concurrent connections. The agent generates code variations while the environment continuously tests them. When a variation moves toward preferential states (faster queries, lower memory), the system explores similar directions. When it moves away (slower performance, crashes), it pivots to new approaches.
Convergence Through Exploration
This push-pull continues until convergence, the point where all manifest criteria are satisfied. Unlike traditional optimization that seeks global maxima, this process finds stable configurations that satisfy multiple, often competing preferences simultaneously.
Manifests can include both hard verifications (such as unit tests) and soft specifications (DesignDoc / PRD like requirements). The interaction between these criteria creates a topology that the agent explores, ultimately finding stationary points that represent viable solutions. The key insight: convergence emerges from the dynamic interaction between agent exploration and environmental feedback, not from predefined optimization targets. Like biological systems finding stable configurations through environmental pressures, convergent software discovers solutions through iterative refinement guided by preferential states.
Related Work, and Current State of Code Generation
AI's transition from "can it work?" to "what can it do?" has been particularly dramatic for software development. Among verifiable domains like mathematics and formal logic, code offers the most immediate commercial value, addressing software development's historically high costs while producing measurable, testable results.
The Copilot Era: Supervised Code Enhancement
The evolution began with AI replacing Stack Overflow searches, then quickly progressed to IDE-integrated copilots. Today's popular tools like Cursor and Windsurf marry familiar development environments (built on Visual Studio Code's foundation) with powerful LLMs like GPT-4 and Claude.
These systems have evolved into embedded agents that combine IDE tooling with LLM reasoning to execute complex tasks. Some operate locally, manipulating files through command-line interfaces, while others run in cloud-based sandboxes with their own browsers, internet access, and repository management. Products like Devin and OpenHands can generate and submit pull requests autonomously, while generalist agents like Manus and Neo extend these capabilities across broader workflows.
However, this entire paradigm, from copilots to autonomous agents, remains fundamentally rooted in traditional software development. Whether human-supervised or fully autonomous, these tools treat code as a valuable, persistent artifact that must be carefully evolved and maintained. They're essentially optimizing the process of moving a boulder up a hill rather than questioning whether the hill-climbing approach itself is optimal.
This represents the AI era's "horseless carriage" moment, applying new technology to old paradigms rather than reimagining the fundamental approach.
##Early Convergent Examples
Recent developments point toward a more radical shift. Google's AlphaEvolve20, while not yet publicly available, demonstrates true convergent software principles. Rather than maintaining persistent codebases, AlphaEvolve uses evolutionary strategies to iteratively generate solutions to verifiable problems.
Most notably, AlphaEvolve discovered a significant improvement to 4x4 matrix multiplication algorithms, reducing floating-point operations in ways that had eluded human optimization for decades. For anyone familiar with computer graphics, this represents a massive achievement, a 4% improvement across billions of triangles translates to substantial real-world performance gains.
What makes AlphaEvolve convergent is its approach: it doesn't maintain or refine existing code. Instead, it generates, tests, and discards countless variations until finding solutions that meet optimization criteria. The code is ephemeral; the solution is what persists.
Abstraction Evolution in Program Synthesis
DreamCoder, though predating modern LLMs, demonstrated another crucial convergent principle: the evolution of abstractions themselves21. Using a domain-specific language, DreamCoder implemented a "wake-sleep" cycle where it would search for optimal programs during "wake" periods, then consolidate successful patterns into reusable abstractions during "sleep" phases.
This approach enabled DreamCoder to rediscover complex physics formulas and algorithms by building increasingly sophisticated conceptual building blocks. The key insight: truly understanding a problem requires evolving not just solutions, but the abstractions used to construct those solutions.
While DreamCoder operated in simplified DSLs, modern LLMs can apply similar principles to full programming languages like Python and JavaScript, leveraging vast training corpora instead of hand-crafted domain languages.
Implications for Just-in-Time Software
These examples reveal convergent software's core principles emerging across different research directions:
- Ephemeral code generation (AlphaEvolve's evolutionary approach)
- Solution-focused optimization rather than codebase maintenance
- Abstraction evolution that improves problem-solving capabilities over time
- Verification-driven development using measurable success criteria
The progression from copilots to convergent systems isn't just technological, it's philosophical. Instead of treating code as crafted artifacts requiring careful stewardship, convergent approaches treat code as transient expressions of solution intent, generated and regenerated as needed to meet evolving requirements.
The Inevitable Future of Software
Just-in-time software isn't just an incremental improvement, it represents a fundamental phase transition in how we create and maintain software systems. While LLMs excel at projecting existing code patterns into new contexts, they're limited to recombining known solutions. True innovation emerges when we combine LLM capabilities with convergent loops like Zerg, evolutionary strategies like AlphaEvolve, and neuro-symbolic approaches like DreamCoder.
This convergence enables code to generate itself against higher-level specifications, transforming software development from manual craftsmanship to guided evolution. We're witnessing the emergence of software that adapts to its environment rather than requiring constant human intervention.
Proven Impact
This isn't theoretical speculation. Zerg is already generating production-ready software components for mission critical systems, proving that convergent approaches can meet the most demanding real-world requirements. These systems don't just work, they evolve, adapt, and optimize themselves in ways that traditional development approaches cannot match.
A New Paradigm
Just as the transition from manual assembly to high-level programming languages seemed revolutionary to earlier generations, convergent software will fundamentally reshape our relationship with code. Instead of managing static artifacts that decay over time, we'll specify desired behaviors and let software continuously regenerate itself to meet changing requirements.
The implications extend far beyond development efficiency. Just-in-time software promises truly resilient systems that adapt to new environments, scale automatically to meet demand, and evolve solutions to problems we haven't yet encountered. We're not just changing how we write code, we're creating software that can rewrite itself to evolve and adapt to it’s environment, resulting in resilient systems that are more rapidly scalable than anything we could have previously imagined.
References and Notes
1 - https://deepmind.google/models/gemini-diffusion/
4 - I’ve found that resistance to code generation tools by engineers falls into two camps. The first is the camp of the artists/craftsperson, which rightfully eschews code-gen tools with the claim that the kind of code they write is novel/unique and as a result code-gen tools are not particularly useful. This is actually true, when writing novel and non-derivative code, code-gen tools don’t really help all that much. I’d assess that 98% of all code I’ve ever written in my life is derivative in nature (boilerplate, CRUD operations, well trodden UI paradigms) - ultimately, if you want to build anything, you spend much of your time on glue. As such, as they exist today the copilot style code generation tools don’t help all that much if the code being written is secondary to the thought process behind it, which is true when writing code to solve novel problems and I know a handful of folks which actually fall into this camp. The second camp are folks that are just holding on to their living or simply do not want to change the way they approach work. This camp is quickly eroding, with folks first migrating to LLMs like ChatGPT as a replacement for Stack overflow, and then eventually discovering the ability of LLMs to template high quality solutions for the questions they’re asking about their specific codebase, and then feeling increasingly confident about the solutions the LLMs spit out. As such, this camp is quickly disappearing and largely follows the Crossing the Chasm cycle of adoption, from the early adopters to the late majority. In fact, we are still in the early majority phase here - but certainly past the chasm. 5 - Convergent Evolution - https://en.wikipedia.org/wiki/Convergent_evolution
6 - I started coding young enough to remember that code used to be something you wrote down and published in a magazine (or other publication). As I grew up, coding evolved from a nerd-hobby to something folks could make a lot of money with - and so I watched as the modern software industry evolved through the years. Going from something that a bunch of us weirdos did, to a world dictated by processes, version control, and large political communities and organizations. This was rational, writing code requires a lot of knowledge, intelligence, and time to produce - so if you were going to spend all of this time and money making something, best to capture, preserve, and invest in it over the long haul. Frameworks, architectures, paradigms and best practices were developed to help essentially amortize the high and exponentially rising cost of development across the intended lifespan of a given piece of code. Increasingly, tackling something like an operating system or game engine looked like a large infrastructure project - spanning years, with complex architecture decisions that would stifle short term development velocity for longer term objectives, largely for the purpose of extending the lifetime of a given technology. While the effort was justified, it was inevitable that technologies would come in-and-out of fashion or relevance. So more often than not, the graveyard of upstarts and irrelevant code was littered with perfectly manicured code bases. Ultimately, development velocity increasingly determined how long a given technology would remain prevalent, while certain staples became unshakable standards. 7 - Language Models as Compilers: Simulating Pseudocode Execution Improves Algorithmic Reasoning in Language Models - https://arxiv.org/abs/2404.02575
8 - Neural Turing Machines - https://arxiv.org/abs/1410.5401
9 - Due to its extremely fast reproduction rate, E. Coli is a very popular target of research for genetics and generally biological functions of prokaryotic cells. It includes complex pathways for locomotion, stress response, and general biological function. So while it may give folks the “ick”, much like how C. Elegans is one of the simplest organisms with a well understood and functional connectome, and Drosophila is sought out for its extremely fast reproduction rate - E. Coli is a popular target of genetics and molecular biology research given the wealth of tools and knowledge we have about it.
9 - Principles of Neural Design - https://mitpress.mit.edu/9780262534680/principles-of-neural-design/
10 - The Vital Question - https://en.wikipedia.org/wiki/The_Vital_Question
11 - Enactivism - https://en.wikipedia.org/wiki/Enactivism
12 - Active inference and learning - https://www.sciencedirect.com/science/article/pii/S0149763416301336
13 - For myself, the most earth shaking result of The Vital Question was the realization that eukaryotic cells are the product of endosymbiosis, and the likely synergy of the combination of multiple cells which found it more evolutionarily advantageous to cooperate at the cellular level. This being one of the few examples of a clear hierarchy/abstraction forming to overcome the restrictions of an environment - which could not, from an energy / least-action perspective, allow for the arbitrary scale up of cells, with perhaps some notable exceptions such as https://en.wikipedia.org/wiki/Acetabularia
14 - gTar: The First Guitar That Anybody Can Play - https://www.kickstarter.com/projects/incident/gtar-the-first-guitar-that-anybody-can-play
15 - Autonomous Stabilization System For a Coaxial Helicopter - https://people.ece.cornell.edu/land/courses/ece4760/FinalProjects/s2006/rg242/webpage/ece%20476.htm
16 - Generative Adversarial Networks - https://arxiv.org/abs/1406.2661
17 - Reinforcement Learning: An Introduction - http://incompleteideas.net/book/the-book-2nd.html
18 - Reward is enough - https://www.sciencedirect.com/science/article/pii/S0004370221000862
19 - https://en.wikipedia.org/wiki/Universal_approximation_theorem
20 - AlphaEvolve: A Gemini-powered coding agent for designing advanced algorithms - https://deepmind.google/discover/blog/alphaevolve-a-gemini-powered-coding-agent-for-designing-advanced-algorithms/
21 - DreamCoder: Growing generalizable, interpretable knowledge with wake-sleep Bayesian program learning - https://arxiv.org/abs/2006.08381


