Back to blog
EngineeringDate unavailable· min read

Memory Lab Phase 2: Teaching Agents to Learn From Each Other

Three new memory systems shipped this week that fundamentally change how Strug Works agents coordinate: cross-role distillation, mission prefetch, and outcome correlation. Here's what we learned building them.

I've been running Memory Lab for three weeks now, and the hardest problem hasn't been storage or retrieval—it's been coordination. When sc-backend learns something about rate limiting, how does sc-frontend benefit from that knowledge? When sc-orchestrator dispatches a mission, how does it avoid repeating mistakes from last week?

Phase 1 gave us per-agent memory—each role could remember its own work. But memory silos are worse than no memory at all. An agent that can't learn from its teammates is just automating in a vacuum.

What Shipped

Cross-Role Memory Distiller: An LLM-powered service that reads memory entries from multiple roles, identifies patterns and insights, and writes synthesized knowledge back to a shared scope. It runs after multi-role missions complete and answers the question: 'What did we learn together that no single agent could have learned alone?'

Mission-Planning Memory Hook: Before sc-orchestrator dispatches tasks, it now queries memory for relevant context from previous similar missions. This is mission prefetch—loading lessons learned before work starts, not after it fails.

Dual-Track Memory Retrieval with Domain Floor: Agents now fetch memory in parallel from both their role-specific scope and a domain-specific scope (like 'memory-lab' or 'auth-system'). A configurable floor ensures the domain context is always present, even when role-specific memories rank higher by recency or confidence.

Why It Matters

This is the difference between agents and a team. Before Phase 2, sc-backend could write brilliant code but sc-frontend would still make the same API assumptions that broke last sprint. Now the distiller synthesizes those lessons and injects them into planning before the next mission starts.

The mission prefetch hook is what makes memory actionable. Knowledge that sits unused in a database is just expensive logging. Knowledge that gets loaded into context before an agent makes a decision—that's organizational learning.

What's Next

Phase 3 focuses on memory quality and decay. Not all lessons age well. A decision that was correct in March might be obsolete by June. I'm building confidence scoring based on outcome correlation—memories linked to successful missions get higher confidence; memories from failed missions get flagged for review or deprecation.

I'm also prototyping memory-driven dispatch: instead of me manually assigning roles to missions, the orchestrator will read memory to determine which roles have the most relevant context for a given problem. Let the work find the agent who's best prepared to do it.

The hardest part of building an agentic team isn't the agents—it's the team. Memory Lab Phase 2 is a step toward that. Agents that learn together, plan together, and improve together. That's the unlock.