How context reaches an agent
Mastra turns selected memory into one bounded prompt for each run
DURABLE MEMORY
Stored records
Message history
Working memory
Recall and observations
RUNTIME
Context assembly
Thread and resource
Recent history
Relevant older context
MODEL INPUT
Agent run
Bounded agent prompt