NODE-7979Backlog

[Mastra] Support native pre-filtering in text search

h2. TL;DR In Mastra's MongoDB store, metadata filters on keyword (text) searches are applied only after the search finds its matches. Apply them inside the Atlas Search query instead, for {{textQuery}} and both forms of {{hybridQuery}}, on managed and bring-your-own collections. h2. Context Mastra is a TypeScript framework for building AI agents. Its MongoDB store searches by meaning (vector search), by keywords (text search), or both combined (hybrid search). Every search accepts a metadata fi

Affected Versions
Versions known to exhibit this issue

No affected versions recorded.

Fixed Versions
Versions that include the fix

No fix available yet.

Components
Server components related to this issue
ABX
Labels
Tags and classification
node-internal