Query Multiple Namespaces from AWS Bedrock

I am trying to query multiple Pinecone namespaces from AWS Bedrock in a single query.

Does anyone know if it’s possible to query multiple namespaces from AWS Bedrock knowledge bases?

When I create a Bedrock knowledge base, I noticed the knowledge base to namespace relationship is 1:1 (I can only specify 1 knowledge base per namespace).

Hi @jon1, and welcome to the Pinecone community forums!

Thanks for this questions.

In Pinecone, each vector operation (query, upsert, etc.) targets only one namespace, so it’s not possible to search multiple namespaces with a single query. You might consider using parallel queries to do that.

It’d be good to hear a bit more about what you’re trying to do, and how you’d like the Bedrock/Pinecone integration to be different. For example, are you looking to store multiple knowledge bases in a single namespace of an index so that a query can search across those knowledge bases?

Jesse

1 Like

Thank you jesse! I realized as well that bedrock knowledge bases are fixed to only query 1 namespace and I see I can only query 1 namespace.

I do have use cases where I analyze the results of a query across multiple namespaces, so like the parallel query, I used the python asyncio to query multiple knowledge bases (set up to different indexes & namespaces), and then I analyze those results.