AIToday
Large Language ModelsAI Business & IndustryAmazon AI BlogPublished: Sep 5, 2026, 04:00 JST

AWS Bedrock Custom Knowledge Base Solution for Utility Bills

Send on LINE
AWS Bedrock Custom Knowledge Base Solution for Utility Bills

3 Key Points

  1. What happened

    AWS published a guide to build a custom knowledge base on Amazon Bedrock that uses Amazon Textract to extract text from complex PDFs and images of utility bills. The solution is deployed via AWS CloudFormation and includes Lambda functions, an S3 bucket, an OpenSearch Serverless cluster, and a Bedrock knowledge base.

  2. Why it matters

    A customer service team that tried feeding raw utility bills directly into a RAG model found the LLM missed key details, hallucinated incorrect information, and performed inconsistently across PDF, DOCX, TXT, HTML, and XLSX formats. Preprocessing with Amazon Textract cleans and tags the data so the LLM can reliably pull account numbers, billing details, and payment instructions.

  1. What to watch

    The solution’s value hinges on whether Textract preprocessing truly eliminates LLM hallucinations across all listed formats, not just the tested PDFs and images. Watch whether the Amazon Nova Micro model’s performance in the test step holds up in production on the GitHub code.

Ask AI

Ask the AI about this article. Questions and answers are published on this page

Context & Analysis

This solution addresses the pain point of customer service teams that handle thousands of utility bills each month. The core issue is that feeding raw documents into a RAG model leads to missing details and hallucinations, as the authors demonstrated with the customer's initial attempt. By adding Amazon Textract as a preprocessing layer, the extracted data is cleaned, enriched, and labeled, making it easier for the LLM to retrieve accurate information.

The deployment relies on AWS services like CloudFormation for infrastructure, Lambda for automated processing, and S3 for storage. The solution automatically parses uploaded files, converts them to TXT format, and syncs them into a Bedrock knowledge base.

For production, the authors recommend enabling Amazon Bedrock Guardrails to filter harmful content and redact sensitive information, plus grounding validation to check that responses are supported by the documents. This highlights the importance of safeguards when using RAG in real-world scenarios.

FAQ
Which file formats can Amazon Textract handle in this solution?
Amazon Textract can extract text from PDF, DOCX, TXT, HTML, XLSX, and PNG files, including multi-page PDFs and tables.
What problem did the customer originally encounter with a RAG solution?
The customer initially loaded raw utility bills into a RAG model, but the LLM missed critical details like due dates and account numbers, hallucinated information, and performed inconsistently across different document formats.
How is the solution deployed?
The deployment runs the shell script 'custom_kb_deployment_setup.sh', which creates an AWS CloudFormation stack that provisions Lambda functions, an S3 bucket, an OpenSearch Serverless cluster, and a Bedrock knowledge base.
Amazon AI BlogRead Original Article
Send on LINE

AI news that matters for your work, delivered every morning.

Pick your industry and the AI tools you use, and get news related to your work every day.

By signing up you agree to the Terms of Service and Privacy Policy.

Free · 30 seconds with Google · unsubscribe anytimeWhat is AIToday? →

Related Articles

Next articleNvidia bags Hugging Face for almost $13 billion