Create

Sign in to ReadmeX

or

How we handle your data: Privacy Policy

ReadmeX

Your AI reading companion

What would you like to catch up on?

Pick a briefing, or ask your own question.

Your community and people briefings stay personal to you.

Story

Mastra launches Trace Queries for filtering agent traces

AI summary

Mastra introduced Trace Queries, letting users of the Mastra platform and local Studio filter and find traces by fields such as time, primitive name, agent or workflow ID, status, score and feedback. The company says the same queries can be built through the CLI ([email protected] or later), the Mastra Client SDK (@mastra/[email protected] or later) and HTTP observability endpoints. Each query covers a time range of up to 31 days, combines up to 100 conditions and allows up to 8 filters on trace internals such as spans, scores and feedback; the feature works on the Mastra platform and on self-hosted projects whose observability storage uses DuckDB, PostgreSQL or ClickHouse, and existing history can be brought in via trace imports.

In-depth insight

Mastra says trace queries can reach low-level details nested deep inside a trace, such as failed tool calls, low scores or negative feedback, giving a more detailed view of what actually happened.

You can now use trace queries to filter and find traces that match specific criteria. Mastra platform and Studio now let you filter by time range, primitive type, environment, status, score, feedback, and more. You (or your coding agent) can also construct the same queries using the CLI, Mastra Client SDK, and HTTP observability endpoints.

If your trace data lives outside of Mastra, you can bring your existing history over with trace imports.

You can also let your coding agent query for traces that errored out or failed, or slow model calls, and then fix them.

Your browser does not support the video tag.

Trace queries usually match fields on the trace itself: when it ran, which agent ran it, and whether it succeeded. The detail that explains a problem often sits deeper, in a failed tool call, a low score, or thumbs-down feedback. Trace queries can reach low-level information nested deep within a trace to provide a more detailed view of what really happened.

Query syntax looks like this:

#Mastra#Mastra Studio#Mastra Client SDK#Mastra CLI#DuckDB#PostgreSQL#ClickHouse

Original · 4 min readRead the original
Group chat

No comments yet. Start the conversation.