Skip to content

processors

Mastra stream processors wired onto the plugin’s agents.

Two complementary processors live here:

  • An input processor (stripStaleChartsProcessor) that scrubs turn-scoped chartId fields out of prior tool results replayed from Memory, so the model can’t copy a stale id into the new turn’s [chart:<id>] markers.
  • An output processor (ResultProcessor) that trims the bulky, redundant payload fields off targeted outbound stream frames before they’re serialized to the SSE client.