Repository navigation
Open
Description
The Problem
First paired benchmark against a live RimWorld colony shows agents are not helping:
Agent: 0.801 ± 0.03
Baseline: 0.830 ± 0.00
Delta: -0.029 (p = 0.37)
The unmanaged colony (RimWorld's built-in pawn AI) scores higher than our 6-agent team. The agents are net-negative — they issue actions that fail or disrupt colonist routines.
Why Agents Are Losing
1. High action failure rate
set_growing_zone→ RIMAPI 500 every time (fork bug, tracked separately)place_blueprint→ agent doesn't include x,z coordinatestoggle_power→ agent sends building_id=0 (no valid IDs in state)haul_resource→ RIMAPI rejects the job assignment
Agents propose ~14 actions per tick but only ~6 execute. The rest fail silently. Failed actions waste the tick without benefit.
2. Agents disrupt productive colonist behavior
- RimWorld's built-in AI already assigns colonists to work, eat, sleep, haul
- Our agents override work priorities, draft colonists away from tasks, reassign researchers
- If the override is wrong or the action fails, the colonist is worse off than if we'd done nothing
3. No understanding of what's already working
- Agents see a snapshot of colony state but don't know what colonists are currently doing
- They propose "set_work_priority growing=1" but the colonist is already growing
- The action succeeds but adds no value — and may disrupt the colonist's current task queue
4. 10-second tick interval means minimal game progression
- Colony runs for 10 seconds between deliberation cycles
- Not enough time for actions to have measurable impact before the next override
What Needs to Change
Fix action reliability first
- Fix
set_growing_zoneRIMAPI fork bug - Teach agents to include coordinates for blueprints
- Expose building IDs in filtered state for
toggle_power - Get execution rate from 43% to 90%+
Make agents aware of current colonist activity
- Add
current_activityorcurrent_jobto colonist state (if RIMAPI exposes it) - Agents should propose NO_ACTION when colonists are already doing the right thing
- Penalize unnecessary overrides in the scoring
Increase tick interval for meaningful progression
- Test with 30-60 second tick intervals so colony state actually changes between ticks
- Fewer but higher-quality interventions > many disruptive ones
Add "do no harm" principle to agent prompts
- System prompt: "Only propose actions that improve on the colony's current trajectory. If colonists are already productive, propose NO_ACTION."
- Weight NO_ACTION higher in the conflict resolver when no crisis exists
Success Criteria
The benchmark answer should be:
Agent: 0.85 ± 0.05
Baseline: 0.75 ± 0.03
Delta: +0.10** (p < 0.05)
Agents must demonstrably improve colony outcomes. Until then, the benchmark is failing honestly.
How to Reproduce
# Requires: RimWorld running, RIMAPI mod, LM Studio with Nemotron Nano 4B
# Save a Crashlanded colony as "rle_crashlanded_v1"
python scripts/run_scenario.py crashlanded_survival \
--provider openai --model nvidia/nemotron-3-nano-4b \
--base-url http://localhost:1234/v1 \
--no-think --ticks 10
python scripts/run_scenario.py crashlanded_survival --no-agent --ticks 10Compare the two final scores. Agent must be higher.
Metadata
Metadata
Assignees
Labels
No labels
Activity
jkbennitt commentedon Mar 25, 2026
Implementation complete
All checklist items addressed in commit b1393c6:
Fix action reliability
set_growing_zoneRIMAPI fork bug — tracked separately, not in scopeMake agents aware of current colonist activity
current_jobexposed in all 6 agent filters (was missing from DefenseCommander, SocialOverseer, ConstructionPlanner)current_jobbefore acting, and resolver prefers NO_ACTION during peacetimeIncrease tick interval
--tick-intervalCLI flag added to bothrun_scenario.pyandrun_benchmark.py(use--tick-interval 30for live game)"Do no harm" principle
Testing
What's needed to verify success criteria
Run a live paired benchmark with
--tick-interval 30 --runs 4against a real RimWorld colony to confirm agent score exceeds baseline. The code-level changes are complete — actual score improvement depends on LLM compliance with the new prompt guidance.🤖 Generated with Claude Code
Implement "do no harm" principle so agents beat unmanaged baseline (#6)
jkbennitt commentedon Mar 26, 2026
Progress: Agents now beat unmanaged baseline
Three fixes flipped the delta from negative to positive:
Fix 1: Work priority endpoint (
f4609da)The bulk endpoint
POST /api/v1/colonists/work-priorityhad a deserialization bug (Priorities list always null). Switched to the singular endpointPOST /api/v1/colonist/work-prioritywhich works. This was the #1 reason colonists wandered — every work assignment was silently failing.Fix 2: "Do no harm" principle (
b1393c6)Agents were disrupting productive colonists every tick. Now they default to NO_ACTION when things are stable and only intervene during crises, starvation risk, or mood emergencies.
Fix 3: Unpause at speed 3 (
eb13e5c)At speed 1, colonists barely start a task in the 10-second tick interval. Speed 3 gives ~3x more game time for work priorities to take effect.
Results (Crashlanded Survival, Nemotron Nano 4B, 2 paired runs)
Cohen's d = 1.0 (large effect). Not yet statistically significant (p = 0.45, N=2) — need N=4+ runs for significance.
Remaining from issue checklist
current_activityfrom RIMAPI so agents know what colonists are doingjkbennitt commentedon Mar 30, 2026
N=4 Paired Results: Nemotron 30B-A3B (OpenRouter, paid tier)
Crashlanded Survival, speed 3, 30s tick interval, detailed colonist data.
Trend is improving but not there yet
Runs 3 and 4 are near-even. The agents are learning to back off (do no harm working) but still net-negative overall.
Comparison across all runs to date
The local Nano 4B at speed 3 got +0.018 but only N=2. The 30B-A3B at N=4 got -0.021. Model matters — the 30B may be less compliant with do-no-harm prompts.
Next steps
Two paths to positive delta:
ADR-001: Colony bootstrap strategy
Phase C+D: Resolver already string-based, overhaul agent prompts (#9)
ADR-002: Map Analyst agent + spatial awareness + bootstrap playbook
jkbennitt commentedon Mar 31, 2026
Status Update — Post #10
With MapAnalyst + terrain constraints (#10 closed), agent scores are now in the 0.79-0.81 range:
Delta is borderline positive (+0.012 to +0.026 vs lower baseline).
Remaining work to consistently beat baseline
Fix data gaps: real materials, power, factions + wire equip/repair/de…
Add alerts, incident trigger, screenshots + deterministic scenarios
jkbennitt commentedon Jun 9, 2026
Status update (June 9): Phase A observability floor is merged (PRs #19, #20). Relevant to this issue:
ActionOutcomecatches RIMAPI errors with clean reasons and broadcasts "DO NOT REPEAT" to agents via CentralPost next tick. Whether this reduces repeated-error rate is the next empirical test.--no-agentruns to colony death, persisted as a.baseline.jsonscenario property), then run agents against the pinned trajectory. That replaces ad-hoc paired runs with a rigorous lift metric, which is what this issue actually needs to be judged against.jkbennitt commentedon Jun 12, 2026
v0.3.0 validation spread update (2026-06-11, 11 models, N=1): only z-ai/glm-5.1 beat the no-agent baseline (+0.028 mean, above on 7/10 ticks). Every other model — including the repeat champion grok-4.3 — landed slightly below it.
What glm-5.1 did differently was restraint: it repeatedly declined low-value actions with explicit justification (e.g. "drafting would be counterproductive" for phantom threats) instead of issuing something every tick. The failure mode it avoided is the one this issue describes: net-negative actions disrupting colonist routines.
Two implications:
Harness-side contributors fixed since the original report: growing-zone 500s (upstream #76 + overlap guard), stockpile overlap/priority (#41), action-error feedback to agents (DO-NOT-REPEAT broadcasts), parse-retry token billing (#44).