Historian
Turn long sessions into a usable record.
Incremental historian artifacts preserve what changed, why it changed and which evidence closed the work. Later agents can recover the decision without reconstructing thousands of turns.
The method behind the system
BlueShop tests whether agents can understand, change and validate one persistent distributed system when durable context, narrow authority, executable specifications, observable failures and hard evidence gates surround the model.
The research object is not the storefront. It is the engineering environment that allows different models and agents to understand, change and validate one persistent distributed system.
Can autonomous AI agents build, debug and evolve a complex software system when intent is explicit, authority is constrained and every important claim must survive executable evidence?
E-commerce supplies realistic pressure: money, identity, inventory races, state machines, event delivery, search, analytics, privacy and cross-service change.
Autonomy means an agent can carry a bounded engineering objective through investigation, implementation and verification. It does not mean removing human intent or pretending generated work is correct by default.
Authority follows the task
The primary agent coordinates the objective and retains the whole-system context. Specialists receive narrow, non-overlapping work and return evidence rather than independent product direction.
Coordinated engineering work
Exploration is delegated when the question spans several modules or naming conventions. Exact file and symbol work stays in the coordinator when delegation would add more context transfer than value.
Independent workstreams use separate repository worktrees when they could collide. A specialist does not silently broaden scope into adjacent systems.
Review is intentionally separated from authorship for large changes. Findings are resolved against source rather than accepted by authority.
Long-running waits are moved out of the main reasoning loop. Watchers report terminal status, failed gates and relevant logs instead of encouraging manual polling.
The experiment is not “how many models appeared in telemetry.” It is whether the engineering environment can route work: deep reasoning where uncertainty is broad, fast variants where the task is narrow, and independent review where risk is high—while spending context on decisions rather than repetition.
| Role in the environment | When it is used | What must still constrain it |
|---|---|---|
| Coordination and implementation | Cross-service change, long diagnosis and delivery loops | Ownership, acceptance criteria and CI/deploy evidence |
| Exploration and specialist review | Ambiguous boundaries, security, architecture and evidence challenges | Findings resolved against source, not model authority |
| Alternative providers under the same harness | Compatibility checks and real project exposure beyond one vendor | Identical tools, rules and gates—not a separate process |
| Fast or lightweight variants | Focused reads, classification, simple checks and watcher-style waits | No skipping of the evidence path for “small” tasks |
| Value | Metric | Meaning |
|---|---|---|
| 273,673 / 275,914 | Metered assistant messages (99.2%) | Messages with non-zero local token telemetry |
| 1,588,401,797 | Uncached input tokens | Prompt input processed outside provider cache reads |
| 35,470,031,235 | Cache-read tokens | Stable prompt content reused from provider caches |
| 247,004,119 | Cache-write tokens | Prompt content written into provider caches |
| 74,475,565 | Model-output tokens | Generated output, including delegated work |
| 20,121,640 | Reasoning-output tokens | Separately reported internal reasoning tokens |
| 95.7% | Prompt-token cache-read share | cache reads / (cache reads + uncached input) |
| ~50,862 | Estimated unretained input tokens | Uncached prompt input extrapolated from a comparable period |
| ~5,138,760,832 | Estimated unretained cache-read tokens | Reused prompt content in the estimated period |
| ~226,579,700 | Estimated unretained cache-write tokens | Prompt content cached during the estimated period |
| ~17,032,794 | Estimated unretained output tokens | Generated output in the estimated period |
Source: local OpenCode telemetry for BlueShop project worktrees, 2026-04-09 through 2026-07-22. The 95.7% figure is a reuse ratio, not a claim that caching reduced cost or work by 95.7%. Earlier local history is unavailable; its activity is an approximate extrapolation from a comparable retained month, not a measured total.
A token-efficient working set
THE ENGINEERING ENVIRONMENT
The remaining sections explain the current harness around the model rather than treating the model as the whole system.
The agent is given structured ways to understand and modify the project. Raw shell access is not the default answer to every question.
Memory without carrying every token forever
Historian
Incremental historian artifacts preserve what changed, why it changed and which evidence closed the work. Later agents can recover the decision without reconstructing thousands of turns.
Dreamer roles
Review, retrospective, documentation and memory-mapping roles can revisit accumulated work when deeper synthesis is useful. They are deliberate reflection tools, not an invented always-running agent platform.
Feedback must arrive early enough to change the work, but every check has a cost. BlueShop widens evidence with risk instead of running every tool after every edit.
Use the cheapest feedback that can disprove the change
Proportional feedback
Fast checks stay close to the edit. Expensive integration, mutation, load and live acceptance checks are reserved for the boundaries they can actually protect.
Batch and parallelize
Coherent changes are checked together, heavy work runs in parallel on K3s runners and watchers return only terminal failures. The foreground agent keeps reasoning instead of polling or thrashing.
| Method | How it constrains agent behavior | Failure it reduces |
|---|---|---|
| Domain-Driven Design | Use business language, explicit ownership, aggregates and state transitions | Editing the wrong service or flattening domain decisions into data plumbing |
| TDD | Make the defect executable before changing production behavior | Symptom patches and regressions without a durable check |
| BDD | Express acceptance as visible Given/When/Then behavior | Implementation passing while the stakeholder journey is still wrong |
| Root-cause-first diagnosis | Trace every shared caller and collect runtime evidence | Retries, longer waits or local guards hiding a distributed defect |
| Minimal solution discipline | Reuse existing patterns and write the smallest correct diff | Speculative abstractions and AI-generated boilerplate |
| Architecture fitness functions | Make package, reactive and dependency rules executable | Slow architectural drift invisible in one review |
Five current personas exercise BlueShop as business actors through the MCP Gateway. They demonstrate constrained agency rather than unrestricted automation.
Observe, decide, act once, verify
| Persona | Useful autonomy | Boundary |
|---|---|---|
| Customer | Browse, manage cart, place orders and interact with owned commerce state | Customer identity and customer-safe MCP capabilities |
| Catalog manager | Inspect and govern products, categories and merchandising relations | Catalog-manager OAuth scope and role |
| Marketing manager | Observe campaigns and perform bounded campaign actions | Marketing capability allowlist and mutation budget |
| Logistician | Observe shipment work and advance legal delivery transitions | Logistics lifecycle and role scope |
| Support manager | Inspect queues, claim work and progress support cases | Support role, customer privacy and ticket state machine |
BlueShop combines fast local development with cluster and live-system validation. Each layer can reject the current hypothesis and return better evidence to the same agent context.
Hybrid local, cluster and live feedback
Local speed
Semantic code search, diagnostics and focused behavior checks keep the edit loop short. The agent does not wait for a remote pipeline to discover a type error or a broken invariant it could prove locally.
Cluster truth
K3s runners provide parallel compute for wider gates. The deployed system then exposes identity, event, persistence, scheduling and observability behavior that a local test cannot reproduce.
Models extend a codebase faster when the codebase teaches them how it works. Repeated architectural building blocks reduce entropy, shrink the search space and provide trustworthy examples for the next change.
Make the right path discoverable, not merely documented.
DDD and ubiquitous language remove competing names. Repeated structure, typed contracts, semantic search and architecture checks reveal the current path directly. Documentation keeps the map, rationale and non-discoverable constraints; it does not duplicate the implementation in a giant agent prompt.
The architectural compounding loop
Low entropy
The agent can compare several existing implementations, identify the stable shape and spend its reasoning budget on the new domain behavior instead of rediscovering project conventions.
High entropy
When every module solves the same concern differently, retrieval returns contradictory examples. Work slows down until the shared pattern is recovered and the exceptional code is refactored.
An AI-friendly system is easy to understand. An AI-resilient system remains safe when the agent misunderstands it.
Five failures changed the engineering system. Open a case to see the signal, the evidence that contradicted the first explanation and the correction that remained afterward.
Evidence. Traces, artifacts and database timestamps showed active products and customer profiles being changed or deleted by another run.
Durable correction. Active-run protection, owned fixtures and serialization only around truly global campaign mutations kept the remaining suites parallel.
Evidence. Kubernetes had already reserved nearly all allocatable memory and CPU through requests, while actual usage remained much lower.
Durable correction. Requests and quota were right-sized while burst limits remained available; concurrent pipelines then used the reclaimed capacity without becoming unschedulable.
Evidence. The shutdown script stopped containers before Kubernetes could terminate stateful workloads in order, interrupting a Vault file write.
Durable correction. Vault, PostgreSQL, Kafka, ClickHouse, Elasticsearch and their volumes now drain before K3s stops. Two complete power cycles proved recovery.
Evidence. The exact dashboard SQL scanned the deduplicated stream twice, joined served and clicked tuples and aggregated the result again.
Durable correction. Raw-fact aggregation reduced the same query to 394 ms and 68.97 MiB while preserving the product-level answer.
Evidence. Source validation found no current Argo Workflows/Events agent platform or matching manifests.
Durable correction. The false canonical and presentation references were deleted. Current AI documentation now describes only the local agent, MCP, context and engineering systems that actually exist.
Result
BlueShop demonstrates a practical direction for autonomous software engineering: models with durable context, constrained authority, composable tools, explicit methods and a feedback loop strong enough to expose their mistakes.
Continue to the technical architecture · See the applied commerce result · Return to the site map