Skip to content

How do I troubleshoot the "Sorry, I am unable to assist you with this request" response in Amazon Bedrock Knowledge Bases?

4 minute read
0

When I query an Amazon Bedrock knowledge base, I receive the "Sorry, I am unable to assist you with this request" response.

Short description

"Sorry, I am unable to assist you with this request" is a generic response that might occur for the following reasons:

  • Empty bucket or data that isn't synced
  • Complex or unclear queries
  • Restrictive retrieval settings
  • Model limitations
  • Security filters
  • Unclear prompt templates

Resolution

Make sure that the knowledge base has the required data

If the knowledge base lacks relevant or complete data, then Amazon Bedrock can't return a result.

To troubleshoot this issue, complete the following steps:

  1. Open the Amazon Simple Storage Service (Amazon S3) console.
  2. In the navigation pane, choose General purpose buckets.
  3. Select the bucket that you linked to your knowledge base.
  4. Make sure that the bucket isn't empty and contains all the relevant documents. Also, make sure that the content aligns with your query intent.
  5. If needed, upload additional documents, and then sync the data to your Amazon Bedrock knowledge base.

Note: Prompt templates must have underlying data to generate answers. If you selected Generate responses for your query, then verify that Amazon Bedrock syncs your documents to the vector store before you run a query.

To make sure that Amazon Bedrock synced your documents to the vector store, complete the following steps:

  1. Open the Amazon Bedrock console.
  2. In the navigation pane, choose Knowledge bases.
  3. Select your knowledge base, and then choose the Data source tab.
  4. If the data source Status isn't Synced, then choose Sync.
  5. After the sync completes, retry your query.

Simplify or rephrase your query

Amazon Bedrock might not understand complex or vague queries, even when the data is available. To troubleshoot this issue, submit a simplified version of your query. It's a best practice to use direct language and specify context. For example, use "What feedback have potential customers given?" instead of "What have potential customers said?".

Adjust your retrieval settings

Retrieval settings limit the amount of data that Amazon Bedrock retrieves. If they're too restrictive, then your query might fail.

To resolve this issue, complete the following steps:

  1. Open the Amazon Bedrock console.
  2. In the navigation pane, choose Knowledge bases.
  3. Select your knowledge base, and then choose Test knowledge base.
  4. For Maximum number of source chunks, enter a number between 10 and 20 to increase the number of search results.
  5. Select Generate responses, and then check whether the knowledge base generates results.

Check for model limitations

Make sure that the foundation model that you use is suited to your data and query styles. For more information about foundation models, select a model provider from the Model providers dropdown menu on Amazon Bedrock.

To test different models, complete the following steps:

  1. Open the Amazon Bedrock console.
  2. In the navigation pane, choose Knowledge bases.
  3. Select your knowledge base, and then choose Test knowledge base.
  4. Under Retrieval and response generation, select Retrieval and response generation: data sources and model.
  5. Under Model, choose the edit icon, and then select another model.
  6. Enter a prompt in Preview to test your query with that model. Repeat steps 5-7 until you generate responses.

Check whether security filters block your query

If Amazon Bedrock considers the content in a query unsafe, then the model might reject the query. To troubleshoot this issue, test a neutral prompt, such as "Give overview of my files". If the prompt succeeds, then security filters might block your original query or data. To resolve this issue, rephrase the query. It's a best practice to use prompts that are neutral and factual. Or, remove sensitive content from your documents, and then resync the data source.

For examples and best practices, see Prompt templates and examples for Amazon Bedrock text models.

Troubleshoot further issues

To identify recurring issues, collect model invocation logs in Amazon CloudWatch Logs. Use metadata tags with queries to identify usage patterns and improve retrieval. You can track when and how often the "unable to assist you" responses occur.

Related information

Security in Amazon Bedrock