World Dynamics (Forrester, 1971): a classic hand-designed model of population, resources, and pollution. Now just ask:
* WORLD DYNAMICS W5 1 L P.K = P.J + (DT)*(BR.JK - DR.JK) 1.1 N P = PI 1.2 C PI = 1.65E9 2 R BR.KL = P.K * CLIP(BRN, BRN1, SWT1, TIME.K) * BRFM.K * BRMM.K * BRCM.K * BRPM.K 2.2 C BRN = 0.04 2.3 C BRN1 = 0.04 2.4 C SWT1 = 1970 3 A BRMM.K = TABHL(BRMMT, MSL.K, 0, 5, 1) 3.1 T BRMMT = 1.2 / 1 / 0.85 / 0.75 / 0.7 / 0.7 4 A MSL.K = ECIR.K / ECIRN 4.1 C ECIRN = 1 5 A ECIR.K = CIR.K * (1 - CIAF.K) * NREM.K / (1 - CIAFN) 6 A NREM.K = TABLE(NREMT, NRFR.K, 0, 1, 0.25) 6.1 T NREMT = 0 / 0.15 / 0.5 / 0.85 / 1 7 A NRFR.K = NR.K / NRI 8 L NR.K = NR.J + (DT)*(-NRUR.JK) 8.1 N NR = NRI 8.2 C NRI = 900E9 9 R NRUR.KL = P.K * CLIP(NRUN, NRUN1, SWT2, TIME.K) * NRMM.K 9.1 C NRUN = 1 9.2 C NRUN1 = 1 9.3 C SWT2 = 1970 NOTE EQUATION 42 CONNECTS HERE FROM EQ. 4 TO EQ. 9 10 R DR.KL = P.K * CLIP(DRN, DRN1, SWT3, TIME.K) * DRMM.K * DRPM.K * DRFM.K * DRCM.K 10.2 C DRN = 0.028 10.3 C DRN1 = 0.028 10.4 C SWT3 = 1970 11 A DRMM.K = TABHL(DRMMT, MSL.K, 0, 5, 0.5) 11.1 T DRMMT = 3 / 1.8 / 1 / 0.8 / 0.7 / 0.6 / 0.53 / 0.5 / 0.5 / 0.5 / 0.5 12 A DRPM.K = TABLE(DRPMT, POLR.K, 0, 60, 10) 12.1 T DRPMT = 0.92 / 1.3 / 2 / 3.2 / 4.8 / 6.8 / 9.2 13 A DRFM.K = TABHL(DRFMT, FR.K, 0, 2, 0.25) 13.1 T DRFMT = 30 / 3 / 2 / 1.4 / 1 / 0.7 / 0.6 / 0.5 / 0.5 14 A DRCM.K = TABLE(DRCMT, CR.K, 0, 5, 1) 14.1 T DRCMT = 0.9 / 1 / 1.2 / 1.5 / 1.9 / 3 15 A CR.K = P.K / (LA * PDN) 15.1 C LA = 135E6 15.2 C PDN = 26.5 16 A BRCM.K = TABLE(BRCMT, CR.K, 0, 5, 1) 16.1 T BRCMT = 1.05 / 1 / 0.9 / 0.7 / 0.6 / 0.55 17 A BRFM.K = TABHL(BRFMT, FR.K, 0, 4, 1) 17.1 T BRFMT = 0 / 1 / 1.6 / 1.9 / 2 18 A BRPM.K = TABLE(BRPMT, POLR.K, 0, 60, 10) 18.1 T BRPMT = 1.02 / 0.9 / 0.7 / 0.4 / 0.25 / 0.15 / 0.1 19 A FR.K = FPCI.K * FCM.K * FPM.K * CLIP(FC, FC1, SWT7, TIME.K) / FN 19.1 C FC = 1 19.2 C FC1 = 1 19.3 C FN = 1 19.4 C SWT7 = 1970 20 A FCM.K = TABLE(FCMT, CR.K, 0, 5, 1) 20.1 T FCMT = 2.4 / 1 / 0.6 / 0.4 / 0.3 / 0.2 21 A FPCI.K = TABHL(FPCIT, CIRA.K, 0, 6, 1) 21.1 T FPCIT = 0.5 / 1 / 1.4 / 1.7 / 1.9 / 2.05 / 2.2 22 A CIRA.K = CIR.K * CIAF.K / CIAFN 22.1 C CIAFN = 0.3 23 A CIR.K = CI.K / P.K 24 L CI.K = CI.J + (DT)*(CIG.JK - CID.JK) 24.1 N CI = CII 24.2 C CII = 0.4E9 25 R CIG.KL = P.K * CIM.K * CLIP(CIGN, CIGN1, SWT4, TIME.K) 25.1 C CIGN = 0.05 25.2 C CIGN1 = 0.05 25.3 C SWT4 = 1970 26 A CIM.K = TABHL(CIMT, MSL.K, 0, 5, 1) 26.1 T CIMT = 0.1 / 1.0 / 1.8 / 2.4 / 2.8 / 3 27 R CID.KL = CI.K * CLIP(CIDN, CIDN1, SWT5, TIME.K) 27.1 C CIDN = 0.025 27.2 C CIDN1 = 0.025 27.3 C SWT5 = 1970 28 A FPM.K = TABLE(FPMT, POLR.K, 0, 60, 10) 28.1 T FPMT = 1.02 / 0.9 / 0.65 / 0.35 / 0.2 / 0.1 / 0.05 29 A POLR.K = POL.K / POLS 29.1 C POLS = 3.6E9 30 L POL.K = POL.J + (DT)*(POLG.JK - POLA.JK) 30.1 N POL = POLI 30.2 C POLI = 0.2E9 31 R POLG.KL = P.K * CLIP(POLN, POLN1, SWT6, TIME.K) * POLCM.K 31.1 C POLN = 1 31.2 C POLN1 = 1 31.3 C SWT6 = 1970 32 A POLCM.K = TABHL(POLCMT, CIR.K, 0, 5, 1) 32.1 T POLCMT = 0.05 / 1 / 3 / 5.4 / 7.4 / 8 33 R POLA.KL = POL.K / POLAT.K 34 A POLAT.K = TABLE(POLATT, POLR.K, 0, 60, 10) 34.1 T POLATT = 0.6 / 2.5 / 5 / 8 / 11.5 / 15.5 / 20 35 L CIAF.K = CIAF.J + (DT/CIAFT)*(CFIFR.J * CIQR.J - CIAF.J) 35.1 N CIAF = CIAFI 35.2 C CIAFI = 0.2 35.3 C CIAFT = 15 36 A CFIFR.K = TABHL(CFIFRT, FR.K, 0, 2, 0.5) 36.1 T CFIFRT = 1 / 0.6 / 0.3 / 0.15 / 0.1 37 A QL.K = QLS * QLM.K * QLC.K * QLF.K * QLP.K 37.1 C QLS = 1 38 A QLM.K = TABHL(QLMT, MSL.K, 0, 5, 1) 38.1 T QLMT = 0.2 / 1 / 1.7 / 2.3 / 2.7 / 2.9 39 A QLC.K = TABLE(QLCT, CR.K, 0, 5, 0.5) 39.1 T QLCT = 2 / 1.3 / 1 / 0.75 / 0.55 / 0.45 / 0.38 / 0.3 / 0.25 / 0.22 / 0.2 40 A QLF.K = TABHL(QLFT, FR.K, 0, 4, 1) 40.1 T QLFT = 0 / 1 / 1.8 / 2.4 / 2.7 41 A QLP.K = TABLE(QLPT, POLR.K, 0, 60, 10) 41.1 T QLPT = 1.04 / 0.85 / 0.6 / 0.3 / 0.15 / 0.05 / 0.02 NOTE EQUATION 42 LOCATED BETWEEN EQ. 4 AND 9. 42 A NRMM.K = TABHL(NRMMT, MSL.K, 0, 10, 1) 42.1 T NRMMT = 0 / 1 / 1.8 / 2.4 / 2.9 / 3.3 / 3.6 / 3.8 / 3.9 / 3.95 / 4 NOTE INPUT FROM EQN. 38 AND 40 TO EQN. 35 43 A CIQR.K = TABHL(CIQRT, QLM.K / QLF.K, 0, 2, 0.5) 43.1 T CIQRT = 0.7 / 0.8 / 1 / 1.5 / 2 43.5 C DT = 0.2 43.6 C LENGTH = 2100 43.7 N TIME = 1900 NOTE NOTE CONTROL CARDS NOTE 44 A PRTPER.K = CLIP(PRTP1, PRTP2, PRSWT, TIME.K) 44.1 C PRTP1 = 0 44.2 C PRTP2 = 0 44.3 C PRSWT = 0 45 A PLTPER.K = CLIP(PLTP1, PLTP2, PLSWT, TIME.K) 45.1 C PLTP1 = 4 45.2 C PLTP2 = 4 45.3 C PLSWT = 0 PLOT P=P(0,8E9)/POLR=2(0,40)/CI=C(0,20E9)/QL=Q(0,2)/NR=N(0,1000E9) PLOT FR=F,MSL=M,QLC=4,QLP=5(0,2)/C1AF=A(.2,.6) RUN ORIG
The established alternative: the same model as 178 lines of DYNAMO (Forrester, 1971).
The catch. Predicting how feedback structure produces emergent behavior is a central open problem in ALife.
So designing a system to exhibit a target emergent behavior is exceptionally hard.
Formalisms include agent-based models, cellular automata, discrete-time dynamic graphs; this work uses ODEs.
State vector x of meaningful stocks (populations, resources), vector field f, initial values x0 at t0. When f follows a known, simple form, analytical techniques such as the Laplace transform apply.
With nonlinear feedback the field integrates with the first-order Euler method, requiring only that f be computable. Many complex systems admit no analytical solution.
Systems thinking that supports policy design and strategic decision-making.
L P.K = P.J + (DT)*(BR.JK - DR.JK)
Outdated syntax or proprietary visual interfaces: both limit their usability with LLMs.
Modeling still requires expert-defined variables and relationships: someone must already know which stocks matter and how they connect.
Ford 1998 / Berard 2010 / Zagonel 2002
The relationship between structure and emergent behavior is often unclear. Goal-directed design = inverting an opaque map.
Schoenberg 2019 / Guneralp 2004 / Barlas 1996
Established languages require labor-intensive workflows; feedback relationships navigated by hand. This limits adoption exactly where insight is needed most.
MIT roadmaps 1998 / Hines 1996 / Sterman 2000
Tree search with a strong model
LLMs as evolutionary operators in ALife
Everything interesting hides in Score, LlmEditor, LlmJudge: the next three moves.
Holds all 20 classical systems we study: World Dynamics + 19 from Modeling Dynamic Biological Systems (20 to 69 integrated variables each).
1# (1) initialization 2dt = 0.01 3t0 = 0.0 4tf = 120.0 5K = 100.0 6R = 0.1 7N = 10.08 9t = t0 10while t <= tf + 1e-12: 1112 # (2) intermediate computations 13 carrying_capacity_factor = 1.0 - N / K 14 growth_rate = R * N * carrying_capacity_factor1516 # (3) derivative evaluations 17 dN = growth_rate # dN = R * N * (1 - N/K)1819 # (4) Euler integration 20 N = N + dt * dN 21 t += dt
1 init# ====================== BEGIN STATE ========================= # STATE VARIABLES - integrated over time (must define derivatives below) P = 1.65e9 # population (people) # NECESSARY NR = 900e9 # natural resources (natural resource units) # NECESSARY CI = 0.4e9 # capital investment (capital units) # NECESSARY POL = 0.2e9 # pollution (pollution units) # NECESSARY CIAF = 0.2 # capital-investment-in-agriculture fraction # NECESSARY # ======================= END STATE ==========================2 intermediate # ... about 40 helper lines elided (multipliers, rates, flows) ...3 derivatives # State derivatives dP = BR - DR dNR = -NRUR dCI = CIG - CID dPOL = POLG - POLA dCIAF = (1 / 15) * (CFIFR * CIQR - CIAF)4 Euler # --------------- Euler integration (engine; do not edit) --------------- P = P + dt * dP NR = NR + dt * dNR CI = CI + dt * dCI POL = POL + dt * dPOL CIAF = CIAF + dt * dCIAF
Extensive comments help humans and LLMs alike; the same four-part shape holds for all 20 systems.
Editor (variation operator): structural edits (add/remove state variables, rewire feedback, rewrite equations), guided by strategy, goal, and the parent's analysis.
①→② the Editor writes a new system; running it produces a fresh execution record.
Judge (fitness function): reads the record; returns a bounded score and an analysis that feeds the next edit. A generate-and-evaluate loop, in the spirit of evolutionary computation.
LLM JudgeANALYZE SIMULATION RESULTS FOR TREE-BASED OPTIMIZATIONGOAL: {goal}CURRENT CODE: {code}SIMULATION RESULTS: {csv_data}TREE CONTEXT: {tree_context}=== For your reference === Format for code in tree context: shows only the differences in each reference node compared to current code; lines starting with "+" show what the reference node has instead Consider: how well this variant achieves the goal; performance relative to ALL other nodes (calibrated scoring); meaningful progress in the search space SCORING GUIDELINES: ABSOLUTE PERFORMANCE SCORING (depth-constrained) Primary Principle: score how well this code achieves the goal, regardless of other nodes 7 bands + depth cap, next slide Use the tree context to keep scoring well-calibrated relative to all explored alternatives === Task ===REASONING: [a brief summary in the first 200 characters, then detailed reasoning about goal achievement] SCORE: [numerical score based on the scoring guidelines]
LLM EditorSUGGEST CODE MODIFICATIONS FOR TREE SEARCH OPTIMIZATIONGOAL: {goal}CURRENT CODE: {code}SIMULATION RESULTS: {csv_data}TREE CONTEXT: {tree_context}=== For your reference === Format for code in tree context: same diff format as the Judge Focus on: parameters within the marked BEGIN/END edit sections; state variables, constants, simulation configuration; derivative equations and helper expressions; table values and time-dependent inputs; learning from tree context outcomes When you modify: start from EVERYTHING in CURRENT CODE; change only between BEGIN/END markers; do not touch imports, wrappers, loop structure, or OUTPUT Tree Search Strategy: your position in the tree; performance patterns; the diversification strategy; other nodes' outcomes SCORING GUIDELINES: same rubric and depth cap === Task ===REASONING: [the modification strategy in the first 200 characters, then reasoning and expected improvement] SELF_ASSESSED_SCORE: [numerical score for the expected result] MODIFIED_CODE: [complete Python, edited only between BEGIN/END]
Tree context carries the analysis and scores of all nodes, including the selected one; the expansion strategy is injected into it.
Primary principle: score how well this code achieves the optimization goal, regardless of other nodes in the tree.
Within this limit, high scores are encouraged when performance truly merits them.
Preliminary studies: without tree context, the expansion process fails to produce meaningful improvements.
Generalized UCT selection (upper confidence bound applied to trees)
The same loop, in evolutionary vocabulary
| MCTS | Evolutionary computation |
|---|---|
| search tree T | structured candidate population |
| node u with system P_u | candidate system |
| LLM Editor | variation operator |
| LLM Judge | fitness function |
| UCT score, argmax over V_exp | selection |
| re-expand until c_v reaches tau | niche preservation, unlike vanilla MCTS |
alpha adjusts the amount of exploration; tau controls the expansion count. A node is expandable iff , and CEDAR sets
, so a saturated node leaves the race. The cap "prevents overexpansion in vast action spaces like code modification and expensive LLM calls".
gamma > 0 controls the preference for deeper nodes: every extra level adds gamma to the score, so a promising branch keeps being refined.
Why these two, from the appendix
In our runs , set empirically.
Eq. 2 / LLM Editor as a learned transition kernel
Eq. 3 / LLM Judge as a learned value function
Each expansion draws one strategy uniformly from the fixed set and injects its instruction into the Editor's tree context.
| Strategy | LLM instruction |
|---|---|
| breakthrough | Make significant, high-impact changes designed to achieve major performance improvements |
| aggressive | Make bold structural or algorithmic changes |
| amplify | Identify and significantly increase the most promising parameters or mechanisms |
| exploratory | Try completely different parameter combinations |
| targeted | Focus on specific high-impact parameters identified from analysis |
| contrarian | Try approaches opposite to current trends or patterns |
| balanced | Make moderate parameter changes with good risk/reward ratio |
| conservative | Make small, incremental parameter adjustments |
World Dynamics (Forrester 1971) in DYNAMO, plus 19 systems from Modeling Dynamic Biological Systems (Hannon and Ruth) in STELLA, converted into our representation: 20 systems, 20 to 69 integrated variables each.
| Variables | Mean | Max | Range |
|---|---|---|---|
| Integrated | 29.4 | 69 | 20 to 69 |
| Helpers | 10.9 | 12 | 10 to 12 |
Two uses: models to optimize toward goals, and ground truths that produce reference records.
Why this is hard for World Dynamics, three reasons from the paper:
With such interdependencies among variables, a single change can trigger cascading effects multiple time steps away.
A vague goal decomposes into subgoals that can compete: increasing population typically requires greater resource consumption.
The baseline is a published system strong enough to sit near a Pareto frontier: pushing one subgoal often comes at the expense of the others.

Editor and Judge responses along the best path, LLM-summarized (Table 3 in the paper)
| node | LLM Editor | LLM Judge |
|---|---|---|
| 0 | (No editor response for root, which is the initial system given as is.) | Unsustainable overshoot behavior - 69% resource depletion, 46x pollution increase |
| 1 | Breakthrough approach - 25-40% efficiency improvements targeting 6-8 score | Sustainable progress - population to 5.46B, 30% resources remaining, controlled pollution |
| 9 | Exploratory approach - radical efficiency through enhanced capital productivity | Paradigm shift - 7.0B population, 78% resource conservation, near-zero pollution |
| 11 | Ultra-aggressive conservation - pushing toward exceptional 9.5+ performance | Breakthrough sustainability - 3.2x population, 36% resource depletion, 90% pollution improvement |
| 17 | Revolutionary breakthrough - 75% resource reduction, 90% pollution control, 300% capital productivity | Best-in-tree performance - 6.3x population, 59% resource conservation, exceptional pollution control |
| 24 | Extreme efficiency breakthrough - 95% resource conservation, 98% pollution reduction, 15x capital productivity | Holy grail achievement - 6.4x population growth with only 19.9% resource depletion |
# baseline World Dynamics, before the edit: the four helper tables the winning edit (Claude run, node 24) re-tuned106NRMM = graph(107 MSL, ((0, 0), (1, 1), (2, 1.8), (3, 2.4), (4, 2.9), (5, 3.3), (6, 3.6), (7, 3.8), (8, 3.9), (9, 3.95), (10, 4))108) # natural-resource-from-material multiplier111CIM = graph(MSL, ((0, 0.1), (1, 1.0), (2, 1.8), (3, 2.4), (4, 2.8), (5, 3))) # capital-investment multiplier114POLCM = graph(CIR, ((0, 0.05), (1, 1), (2, 3), (3, 5.4), (4, 7.4), (5, 8))) # pollution-from-capital multiplier115POLAT = graph(116 POLR, ((0, 0.6), (10, 2.5), (20, 5), (30, 8), (40, 11.5), (50, 15.5), (60, 20))117) # pollution-absorption time
Resource use per unit of material living standard. Judge: "ultra-low resource usage through NRMM reduction".
Pollution generated per unit of capital. Judge: "revolutionary pollution control through POLCM reduction".
Capital investment multiplier. Judge: "massive capital productivity increase through enhanced CIM values".
Pollution absorption time: "POLAT values 2-3x higher than parent nodes, enabling rapid pollution cleanup".
Population grows from 1.65B to 10.57B (6.4x); natural resources decline only 19.9% (from 900B to 720B); pollution 3.6B units by 2100 (vs 200M baseline), representing a controlled 18x increase.
dt = 0.1 # time step size t0 = 0.0 # start time tf = 3500.0 # end time POPULATION = 2.0 # NECESSARY SUM_POP = 0.0 # NECESSARY BIRTHS = 0.07 * POPULATION NOMINAL_DR = (exp(-0.01 * t) * 0.03 + 0.01) * 1 + 0.04 * 0 DR_DISTRIBUTION = normal(NOMINAL_DR, 0.005 * POPULATION) DR_DIST_CONTROL = DR_DISTRIBUTION if (DR_DISTRIBUTION >= 0.01 and DR_DISTRIBUTION <= 1) else 0.01 DEATH_RATE = ( (DR_DIST_CONTROL if DR_DIST_CONTROL > NOMINAL_DR else NOMINAL_DR) * 1 + 0 * DR_DIST_CONTROL + 0 * NOMINAL_DR ) DEATHS = DEATH_RATE * POPULATION dPOPULATION = BIRTHS - DEATHS
Two constant rates, no structure
Adds a population-dependent death rate
The ground truth's own formulae: pure parameter fitting
Optuna: 100 trials per variant. Metrics: L1 and DTW (via the dtaidistance library), Sakoe-Chiba band w = 250, 7.1% of the 3500 steps, inside the recommended 5 to 10%.
Task: fit the record of a stochastic population model, starting from a bare skeleton. Optuna gets 100 trials and up to the full ground-truth equations: strictly more prior structure than CEDAR.
| Method | Formulae | L1 ↓ | DTW ↓ |
|---|---|---|---|
| Optuna | none | 29.06 | 5503.68 |
| Optuna | simple | 26.01 | 4927.94 |
| Optuna | full | 3.71 | 477.52 |
| CEDAR (Claude) | none | 3.29 | 757.21 |
| CEDAR (GPT-5.1) | none | 2.22 | 433.13 |
Without formulae, Optuna collapses to near-constant populations; CEDAR tracks the peaks and dips within ground-truth variability.
Vs. Optuna (full): Claude wins on L1 only; GPT-5.1 wins on both metrics.
10 random seeds of the ground truth: the stochastic death rate makes the volatility intrinsic; CEDAR's record (previous slide) generally falls within this band.
DR_DISTRIBUTION = normal(NOMINAL_DR, 0.005 * POPULATION)
The death rate is sampled at every time step from a normal distribution parameterized by the current population, so peaks and dips are not in sync across runs: the volatility is an intrinsic property of the system, not an artifact of the optimizer.
| Method | Formulae | L1 ↓ | DTW ↓ |
|---|---|---|---|
| Optuna (Run 1) | full | 3.71 | 477.52 |
| Optuna (Run 2) | full | 4.26 | 605.05 |
| CEDAR (GPT-5.1) | none | 2.22 | 433.13 |
In theory, with full formulae access and enough trials, Optuna could approach the ground truth system's parameters. In practice it does not perfectly match the dynamics. Two factors:
| Work | What it searches | Why it differs |
|---|---|---|
| I-MCTS (Liang 2025) | AutoML hyperparameters | Hyperparameters, not iterative temporal dynamics |
| LATS (Zhou 2024) | Discrete task graphs | Task graphs, not iterative temporal dynamics |
| GIF-MCTS, LLM-SRBench | Short sequences | Short sequences vs multi-thousand-step dynamics |
| EvoPrompt, PromptBreeder, DSPy | Prompts | Need demonstrations; none in online exploration |
| LLMs for system dynamics (Liu 2024; Luo 2025; Liu and Keith 2025) | Predictors of behavior unknown to the optimizer | Smaller systems: up to 4 variables and 12 steps |
| CEDAR (ours) | Complex systems as runnable Python | 20 systems, 20 to 69 variables, a 3500-step record |
Also nearby: LLMs with MCTS for automated scientific discovery (AI Scientist-v2), artificial life discovery (ASAL), and runnable code for reasoning (Katz 2024).
Limits
Next
Yingtao Tian / Sakana AI / [email protected] / @alanyttian
