A production-ready, high-throughput AWS Lambda that processes South African tender messages from multiple sources via Amazon SQS (FIFO) and generates intelligent summaries using Anthropic Claude 3 Sonnet via Amazon Bedrock. It continuously polls the source queue, validates and enriches messages with AI-generated summaries, and publishes results to a write queue—while safely routing failures to a DLQ. Built for reliability, observability, and smart prompt management through AWS Parameter Store.
- Sources: eTenders, Eskom, Transnet, SARS, SANRAL (government and utility)
- AI Model: Anthropic Claude 3 Sonnet via Amazon Bedrock
- Prompts: Dynamic, source-specific prompts managed in AWS Parameter Store
- Queues: AIQueue (input), TagQueue (success), FailedQueue (errors)
- Focus: Quality AI summaries, speed, resilience, clear monitoring
- ✨ Features
- 🧭 Architecture (Simple View)
- 💡 Why SQS + Lambda + Bedrock + Parameter Store?
- 🧩 What's Inside (Project Structure)
- ⚙️ Configuration
- 🚀 Quick Start
- 🧠 How It Works
- 📦 Tech Stack
- 🗂️ Message Models (At a Glance)
- 📮 Queues
- 📈 Monitoring & Metrics
- 🛡️ Error Handling & Recovery
- ⚡ Performance & Scaling
- 🔒 Security
- 🧪 Testing
- 📦 Deployment
- 🧰 Troubleshooting
- 🗺️ Roadmap
- 🚀 High throughput: continuous polling + batch processing (up to 10 messages)
- 🧠 Advanced AI Summarization: Uses Anthropic Claude 3 Sonnet via Amazon Bedrock
- 🎯 Source-specific Prompts: Fetches tailored instructions from AWS Parameter Store
- 🔄 Multi-source support: eTenders, Eskom, Transnet, SARS, SANRAL (easy to add more)
- ⚙️ External Prompt Management: Update AI instructions without code deployments
- ⚡ Efficient Caching: In-memory prompt caching reduces API calls
- 🧯 Safe-by-default: DLQ routing, partial-batch success, Bedrock throttling handling
- 🧭 Observable: structured logs, clear metrics, error context
- 🧩 JSON-friendly: case-insensitive and camelCase support
Tender Scrapers
↓
TenderQueue (TenderQueue.fifo)
↓
Deduplication Lambda
├─ Check RDS Database (duplicate validation)
└─ Route based on deduplication results
↓
AIQueue (AIQueue.fifo)
↓
AI Summary Lambda (AILambda)
├─ Message Factory (eTenders, Eskom, Transnet, SARS, SANRAL)
├─ Prompt Service ← AWS Parameter Store (dynamic prompts)
├─ Bedrock Service → Amazon Bedrock (Claude 3 Sonnet)
├─ Message Processor (validate → AI summarize)
└─ SQS Service (I/O)
├─ TagQueue (TagQueue.fifo) ← success + AI summaries
└─ FailedQueue (FailedQueue.fifo) ← errors/DLQ
↓
AI Tagging Lambda
├─ Apply relevant tags based on content
└─ Route tagged messages
↓
WriteQueue (WriteQueue.fifo)
↓
Final Processing → RDS Database
- Resilient by design: retries, visibility timeouts, and DLQs
- Pay-per-use: scales with load, no idle cost
- Intelligent Processing: State-of-the-art AI summaries via Claude 3 Sonnet
- Flexible Prompts: External prompt management allows quick iterations
- Simple ops model: logs + metrics in CloudWatch, minimal moving parts
- Easy extension: add new sources via the Message Factory pattern
Sqs_AI_Lambda/
├── Function.cs # Lambda entry point with continuous polling
├── Models/
│ ├── TenderMessageBase.cs # Base model with AISummary property
│ ├── ETenderMessage.cs # eTenders model
│ ├── EskomTenderMessage.cs # Eskom model
│ ├── TransnetTenderMessage.cs # Transnet model
│ ├── SarsTenderMessage.cs # SARS model
│ ├── SanralTenderMessage.cs # SANRAL model
│ ├── SupportingDocument.cs # Attachments
│ └── QueueMessage.cs # Internal SQS wrapper
├── Services/
│ ├── MessageProcessor.cs # Business pipeline with AI integration
│ ├── MessageFactory.cs # Creates typed messages by MessageGroupId
│ ├── BedrockSummaryService.cs # Claude 3 Sonnet integration with retries
│ ├── PromptService.cs # Parameter Store prompt management
│ └── SqsService.cs # SQS operations
├── Interfaces/
│ ├── IMessageProcessor.cs
│ ├── IMessageFactory.cs
│ ├── IBedrockSummaryService.cs
│ ├── IPromptService.cs
│ └── ISqsService.cs
├── Converters/
│ └── StringOrNumberConverter.cs # Flexible type conversion
├── aws-lambda-tools-defaults.json # Deployment config
└── README.md
Create these String parameters in AWS Systems Manager Parameter Store:
/TenderSummary/Prompts/System # General instructions for Claude 3
/TenderSummary/Prompts/eTenders # eTenders-specific prompts
/TenderSummary/Prompts/Eskom # Eskom-specific prompts
/TenderSummary/Prompts/Transnet # Transnet-specific prompts
/TenderSummary/Prompts/SARS # SARS-specific prompts
/TenderSummary/Prompts/SANRAL # SANRAL-specific prompts
SOURCE_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/AIQueue.fifo"
TAG_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/TagQueue.fifo"
FAILED_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/FailedQueue.fifo"- SQS:
ReceiveMessage,DeleteMessage,GetQueueAttributes,SendMessage - Bedrock:
bedrock:InvokeModel(Claude 3 Sonnet model ARN) - Parameter Store:
ssm:GetParameter(on/TenderSummary/Prompts/*) - CloudWatch Logs:
logs:CreateLogGroup,logs:CreateLogStream,logs:PutLogEvents
- Ingest (continuous polling, small time budget safety)
while (context.RemainingTime > TimeSpan.FromSeconds(30))
{
var messages = await PollMessagesFromQueue(10);
if (!messages.Any()) break;
await ProcessMessageBatch(messages);
}- Route & Create (by MessageGroupId, now supports 5 sources)
var result = groupIdLower switch
{
"etenderscrape" or "etenderlambda" => CreateETenderMessage(body, groupId),
"eskomtenderscrape" or "eskomlambda" => CreateEskomTenderMessage(body, groupId),
"transnettenderscrape" or "transnetlambda" => CreateTransnetTenderMessage(body, groupId),
"sarstenderscrape" or "sarslambda" => CreateSarsTenderMessage(body, groupId),
"sanraltenderscrape" or "sanrallambda" => CreateSanralTenderMessage(body, groupId),
_ => HandleUnsupportedMessageGroup(groupId)
};- Fetch Prompts (cached from Parameter Store)
var systemPrompt = await _promptService.GetPromptAsync("System");
var sourcePrompt = await _promptService.GetPromptAsync(sourceType);- AI Summarization (Claude 3 Sonnet via Bedrock)
var summary = await _bedrockService.GenerateSummaryAsync(message, systemPrompt, sourcePrompt);
message.AISummary = summary;- Process & Tag
- Adds lifecycle tags (Processed, AI-Enhanced, handler name, UTC timestamp)
- Output (transactional)
- Success → TagQueue + delete from AIQueue
- Error → FailedQueue (DLQ) + keep in AIQueue for retry
- Runtime: .NET 8 (LTS)
- Compute: AWS Lambda
- AI Model: Anthropic Claude 3 Sonnet (via Amazon Bedrock)
- Configuration: AWS Systems Manager Parameter Store
- Messaging: Amazon SQS (FIFO)
- Serialization: System.Text.Json
- Logging/DI: Microsoft.Extensions.*
NuGet (excerpt):
<PackageReference Include="Amazon.Lambda.Core" Version="2.5.0" />
<PackageReference Include="Amazon.Lambda.Serialization.SystemTextJson" Version="2.4.4" />
<PackageReference Include="Amazon.Lambda.SQSEvents" Version="2.2.0" />
<PackageReference Include="AWSSDK.SQS" Version="4.0.1.2" />
<PackageReference Include="AWSSDK.BedrockRuntime" Version="3.7.400.3" />
<PackageReference Include="AWSSDK.SimpleSystemsManagement" Version="3.7.400.3" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.8" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="9.0.8" />Shared fields: title, description, tenderNumber, reference, contact info, province, supportingDocs, tags, AISummary
- eTenders: id, status, datePublished, dateClosing, url
- Eskom: source, publishedDate?, closingDate?
- Transnet: institution, category, location, contactPerson
- SARS: briefingSession, dates
- SANRAL: category, region, fullNoticeText
Base model excerpt:
public abstract class TenderMessageBase
{
public string Title { get; set; } = string.Empty;
public string Description { get; set; } = string.Empty;
public string TenderNumber { get; set; } = string.Empty;
public List<SupportingDocument> SupportingDocs { get; set; } = new();
public List<string> Tags { get; set; } = new();
public string? AISummary { get; set; } = null; // Generated by Claude 3 Sonnet
public abstract string GetSourceType();
}| Queue | Purpose | URL | Groups (examples) | Notes |
|---|---|---|---|---|
| AIQueue | Incoming tender messages | AIQueue.fifo | etenderscrape, eskomtenderscrape, transnettenderscrape, sarstenderscrape, sanraltenderscrape | Retention 5d |
| TagQueue | AI-enhanced messages | TagQueue.fifo | Source-based grouping | Includes AI summaries + tags |
| FailedQueue | Error recovery | FailedQueue.fifo | Error-type grouping | Enriched error info |
Full URLs:
SOURCE_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/AIQueue.fifo"
TAG_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/TagQueue.fifo"
FAILED_QUEUE_URL="https://sqs.us-east-1.amazonaws.com/211635102441/FailedQueue.fifo"Watch these:
- Lambda: Invocations, Duration, Errors, Throttles
- SQS: ApproximateNumberOfMessages (queue depth)
- Bedrock: Model invocation metrics, throttling events
- Parameter Store: GetParameter API calls
Structured log example:
{
"level": "Information",
"message": "AI summary generated",
"properties": {
"SourceType": "SANRAL",
"TenderNumber": "RFP-2025-001",
"SummaryLength": 247,
"BedrockDuration": 1.2
}
}Custom metric-style logs:
_logger.LogInformation("Batch done - Processed: {Processed}, AI-Enhanced: {Enhanced}, Failed: {Failed}, Duration: {Duration}ms",
successCount, aiEnhancedCount, failedCount, processingDuration);- Bedrock throttling: Automatic retries with exponential backoff
- Prompt fetching failures: Graceful degradation, detailed logging
- AI processing errors: Messages routed to DLQ with context
- Automatic retries via visibility timeout + Lambda retry behavior
- Enriched error payloads for fast diagnosis
Redrive example:
aws sqs start-message-move-task \
--source-arn arn:aws:sqs:us-east-1:211635102441:FailedQueue.fifo \
--destination-arn arn:aws:sqs:us-east-1:211635102441:AIQueue.fifo- Prompt caching: Reduces Parameter Store API calls
- Bedrock concurrency control: Prevents overwhelming the AI service
- ReadyToRun to reduce cold starts
- Batch operations for send/delete
- Async/await throughout the pipeline
- Keep JSON compact (camelCase, no indentation)
Scaling:
- Concurrency scales with demand and Bedrock capacity
- Typical: dozens of AI-enhanced messages/minute per Lambda
- Cost: pay-per-invocation + Bedrock token usage
Data handling:
- TLS in transit, SSE at rest on SQS and Parameter Store
- Public tender data only
- IAM least-privilege for Bedrock and Parameter Store access
- Full audit trail via CloudWatch
Prompt security:
- Parameter Store provides secure configuration management
- Prompts can be updated without code deployments
- Version control for prompt changes
This section covers three deployment methods for the AI Lambda Function (Tender Summarization Service). Choose the method that best fits your workflow and infrastructure preferences.
Before deploying, ensure you have:
- AWS CLI configured with appropriate credentials 🔑
- .NET 8 SDK installed locally
- AWS SAM CLI installed (for SAM deployment)
- Access to AWS Lambda, SQS, Bedrock, Parameter Store, and CloudWatch services ☁️
- Visual Studio 2022 or VS Code with C# extensions (for AWS Toolkit deployment)
- Claude 3 Sonnet model access in AWS Bedrock
Deploy directly through Visual Studio using the AWS Toolkit extension.
- Install AWS Toolkit for Visual Studio 2022
- Configure AWS Profile with your credentials in Visual Studio
- Open Solution containing
Sqs_AI_Lambda.csproj
- Right-click the project in Solution Explorer
- Select "Publish to AWS Lambda" from the context menu
- Configure Lambda Settings:
- Function Name:
AILambda - Runtime:
.NET 8 - Handler:
Sqs_AI_Lambda::Sqs_AI_Lambda.Function::FunctionHandler - Memory:
512 MB - Timeout:
900 seconds(15 minutes)
- Function Name:
- Set Environment Variables:
FAILED_QUEUE_URL=https://sqs.{region}.amazonaws.com/{account-id}/FailedQueue.fifo SOURCE_QUEUE_URL=https://sqs.{region}.amazonaws.com/{account-id}/AIQueue.fifo TAG_QUEUE_URL=https://sqs.{region}.amazonaws.com/{account-id}/TagQueue.fifo - Configure IAM Role with required permissions:
- SQS:
ReceiveMessage,DeleteMessage,GetQueueAttributes,SendMessage - Bedrock:
bedrock:InvokeModelfor Claude 3 Sonnet - Parameter Store:
ssm:GetParameteron/TenderSummary/Prompts/* - CloudWatch Logs: Standard logging permissions
- SQS:
- Set up SQS Trigger manually after deployment
Create these parameters before deployment:
# System prompt for Claude 3 Sonnet
aws ssm put-parameter \
--name "/TenderSummary/Prompts/System" \
--value "You are an AI assistant specialized in analyzing South African tender documents..." \
--type "String"
# Source-specific prompts
aws ssm put-parameter \
--name "/TenderSummary/Prompts/eTenders" \
--value "Focus on government procurement requirements..." \
--type "String"
aws ssm put-parameter \
--name "/TenderSummary/Prompts/Eskom" \
--value "Emphasize power generation and electrical infrastructure..." \
--type "String"
aws ssm put-parameter \
--name "/TenderSummary/Prompts/Transnet" \
--value "Highlight logistics and transportation aspects..." \
--type "String"
aws ssm put-parameter \
--name "/TenderSummary/Prompts/SARS" \
--value "Focus on tax administration and revenue services..." \
--type "String"
aws ssm put-parameter \
--name "/TenderSummary/Prompts/SANRAL" \
--value "Emphasize road infrastructure and highway projects..." \
--type "String"- Test the function using the AWS Toolkit test feature
- Monitor logs through CloudWatch integration
- Verify Bedrock integration and prompt retrieval
- Test SQS message processing
Use AWS SAM for infrastructure-as-code deployment with the provided template.
# Install AWS SAM CLI
pip install aws-sam-cli
# Install .NET 8 SDK
# Download from https://dotnet.microsoft.com/download/dotnet/8.0
# Verify installations
sam --version
dotnet --version# Build the .NET 8 application
dotnet build -c Release
# Build the SAM application
sam build
# Deploy with guided configuration (first time)
sam deploy --guided
# Follow the prompts:
# Stack Name: ai-lambda-stack
# AWS Region: us-east-1 (or your preferred region)
# Parameter FailedQueueURL: https://sqs.{region}.amazonaws.com/{account-id}/FailedQueue.fifo
# Parameter SourceQueueURL: https://sqs.{region}.amazonaws.com/{account-id}/AIQueue.fifo
# Parameter TagQueueURL: https://sqs.{region}.amazonaws.com/{account-id}/TagQueue.fifo
# Confirm changes before deploy: Y
# Allow SAM to create IAM roles: Y
# Save parameters to samconfig.toml: YThe template already includes the required environment variables:
# Already configured in AILambda.yaml
Environment:
Variables:
FAILED_QUEUE_URL: https://sqs.us-east-1.amazonaws.com/{account-id}/FailedQueue.fifo
SOURCE_QUEUE_URL: https://sqs.us-east-1.amazonaws.com/{account-id}/AIQueue.fifo
TAG_QUEUE_URL: https://sqs.us-east-1.amazonaws.com/{account-id}/TagQueue.fifo# Create all required prompts before deploying
./scripts/setup-parameters.sh # Create this script with parameter creation commands# Quick deployment after initial setup
dotnet build -c Release
sam build && sam deploy# Test function locally (requires Docker)
sam local invoke AILambda
# Start local SQS simulation
sam local start-api- ✅ Complete infrastructure management including SQS queues
- ✅ Environment variables defined in template
- ✅ IAM permissions automatically configured for Bedrock and Parameter Store
- ✅ Easy rollback capabilities
- ✅ CloudFormation integration
- ✅ SQS trigger automatically configured
Automated deployment using GitHub Actions workflow for production environments.
-
GitHub Repository Secrets:
AWS_ACCESS_KEY_ID: Your AWS access key AWS_SECRET_ACCESS_KEY: Your AWS secret key AWS_REGION: us-east-1 (or your target region) -
Pre-existing Lambda Function: The workflow updates an existing function, so deploy initially using Method 1 or 2.
-
Parameter Store Setup: Ensure all prompts are configured in Parameter Store.
-
Create Release Branch:
# Create and switch to release branch git checkout -b release # Make your changes to the .NET code # Commit changes git add . git commit -m "feat: update AI prompt processing logic" # Push to trigger deployment git push origin release
-
Automatic Deployment: The workflow will:
- Checkout the code
- Set up .NET 8 SDK
- Install AWS Lambda Tools
- Build and package the Lambda function using
Sqs_AI_Lambda.csproj - Configure AWS credentials
- Update the existing Lambda function code
- Maintain existing configuration (environment variables, triggers, etc.)
You can also trigger deployment manually:
- Go to Actions tab in your GitHub repository
- Select "Deploy .NET Lambda to AWS" workflow
- Click "Run workflow"
- Choose the
releasebranch - Click "Run workflow" button
- ✅ Automated CI/CD pipeline
- ✅ Consistent deployment process
- ✅ Audit trail of deployments
- ✅ Easy rollback to previous commits
- ✅ No local environment dependencies
- ✅ Automatic .NET build and packaging
Regardless of deployment method, verify the following:
Ensure these environment variables are properly set:
# Verify environment variables via AWS CLI
aws lambda get-function-configuration \
--function-name AILambda \
--query 'Environment.Variables'Expected output:
{
"FAILED_QUEUE_URL": "https://sqs.us-east-1.amazonaws.com/{account-id}/FailedQueue.fifo",
"SOURCE_QUEUE_URL": "https://sqs.us-east-1.amazonaws.com/{account-id}/AIQueue.fifo",
"TAG_QUEUE_URL": "https://sqs.us-east-1.amazonaws.com/{account-id}/TagQueue.fifo"
}Verify all required prompts exist:
# Check system prompt
aws ssm get-parameter --name "/TenderSummary/Prompts/System"
# Check source-specific prompts
aws ssm get-parameter --name "/TenderSummary/Prompts/eTenders"
aws ssm get-parameter --name "/TenderSummary/Prompts/Eskom"
aws ssm get-parameter --name "/TenderSummary/Prompts/Transnet"
aws ssm get-parameter --name "/TenderSummary/Prompts/SARS"
aws ssm get-parameter --name "/TenderSummary/Prompts/SANRAL"Verify Claude 3 Sonnet access:
# List available foundation models
aws bedrock list-foundation-models --region us-east-1
# Test model access (if needed)
aws bedrock invoke-model \
--model-id anthropic.claude-3-sonnet-20240229-v1:0 \
--body '{"messages":[{"role":"user","content":"Test"}],"max_tokens":100}' \
--cli-binary-format raw-in-base64-out \
response.jsonEnsure the SQS trigger is properly configured:
# List event source mappings
aws lambda list-event-source-mappings \
--function-name AILambda
# Verify batch size and queue configuration
aws lambda get-event-source-mapping \
--uuid [event-source-mapping-uuid]After deployment, test the function thoroughly:
# Send test message to source queue
aws sqs send-message \
--queue-url https://sqs.us-east-1.amazonaws.com/{account-id}/AIQueue.fifo \
--message-body '{
"title": "Test Tender for Infrastructure Development",
"description": "This is a test tender for AI processing",
"tenderNumber": "TEST-001",
"source": "eTenders"
}' \
--message-group-id "etenderscrape" \
--message-deduplication-id "test-$(date +%s)"
# Monitor function execution
aws logs tail /aws/lambda/AILambda --follow# Invoke function to test prompt retrieval
aws lambda invoke \
--function-name AILambda \
--payload '{"Records":[]}' \
response.json
# Check response for prompt loading logs
cat response.json- ✅ Function executes without errors
- ✅ CloudWatch logs show successful prompt retrieval from Parameter Store
- ✅ Bedrock integration working (AI summaries generated)
- ✅ Messages properly routed to TagQueue with AI summaries
- ✅ No timeout or memory errors
- ✅ Proper error handling for failed messages
- ✅ SQS batch processing functioning correctly
- Duration: Function execution time for AI processing
- Error Rate: Failed AI generation operations
- Memory Utilization: RAM usage during Bedrock calls
- SQS Metrics: Message processing rates and queue depths
- Bedrock Metrics: Model invocation success rates and latencies
- Parameter Store: GetParameter API call rates
# View recent logs
aws logs tail /aws/lambda/AILambda --follow
# Search for AI processing statistics
aws logs filter-log-events \
--log-group-name /aws/lambda/AILambda \
--filter-pattern "AI-Enhanced"
# Search for prompt loading issues
aws logs filter-log-events \
--log-group-name /aws/lambda/AILambda \
--filter-pattern "Prompt loading"
# Monitor Bedrock integration
aws logs filter-log-events \
--log-group-name /aws/lambda/AILambda \
--filter-pattern "Bedrock".NET 8 Runtime Issues
Issue: Function fails to start or throws runtime errors
Solution: Ensure proper .NET 8 configuration:
- Verify the handler path:
Sqs_AI_Lambda::Sqs_AI_Lambda.Function::FunctionHandler - Check that all NuGet packages are compatible with .NET 8
- Ensure the project targets
net8.0framework - Verify all dependencies are included in the deployment package
Bedrock Access Issues
Issue: Cannot access Claude 3 Sonnet model
Solution: Verify Bedrock configuration:
- Ensure the IAM role has
bedrock:InvokeModelpermissions - Check that Claude 3 Sonnet is available in your region
- Verify model ARN:
anthropic.claude-3-sonnet-20240229-v1:0 - Test model access using AWS CLI
- Check Bedrock service quotas and limits
Parameter Store Access Failures
Issue: Cannot retrieve prompts from Parameter Store
Solution: Debug Parameter Store configuration:
- Verify IAM role has
ssm:GetParameterpermissions on/TenderSummary/Prompts/* - Check that all required parameters exist
- Test parameter retrieval using AWS CLI
- Ensure parameter names match exactly (case-sensitive)
- Verify parameter type is "String"
SQS Message Processing Issues
Issue: Messages not being processed or routed incorrectly
Solution: Debug SQS configuration:
- Verify SQS trigger is configured with correct batch size (10)
- Check message format matches expected JSON structure
- Ensure FIFO queue attributes are properly set
- Verify MessageGroupId routing logic
- Monitor dead letter queue for failed messages
Memory and Performance Issues
Issue: Function runs out of memory or times out
Solution: Optimize function performance:
- Increase memory allocation (current: 512 MB)
- Optimize AI processing batch size
- Review Bedrock API call patterns
- Monitor prompt caching effectiveness
- Consider implementing connection pooling
Environment Variables Missing
Issue: Function cannot access required queue URLs
Solution: Set environment variables using AWS CLI:
aws lambda update-function-configuration \
--function-name AILambda \
--environment Variables='{
"FAILED_QUEUE_URL":"https://sqs.{region}.amazonaws.com/{account-id}/FailedQueue.fifo",
"SOURCE_QUEUE_URL":"https://sqs.{region}.amazonaws.com/{account-id}/AIQueue.fifo",
"TAG_QUEUE_URL":"https://sqs.{region}.amazonaws.com/{account-id}/TagQueue.fifo"
}'Workflow Deployment Fails
Issue: GitHub Actions workflow errors
Solution:
- Check repository secrets are correctly configured
- Verify .NET 8 SDK is properly installed in workflow
- Ensure AWS Lambda Tools installation succeeds
- Check that
Sqs_AI_Lambda.csprojexists in repository - Verify target Lambda function exists in AWS
- Monitor workflow logs for specific error messages
Choose the deployment method that best fits your development workflow and infrastructure requirements. SAM deployment is recommended for development environments, while workflow deployment excels for production systems requiring automated CI/CD pipelines with AI model integration.
- Missing prompts
- KeyNotFoundException → Check Parameter Store paths
- Bedrock permission denied
- AccessDeniedException → Update IAM role for Bedrock
- Model not available
- ValidationException → Verify Claude 3 Sonnet availability in region
- Throttling issues
- ThrottlingException → Monitor Bedrock quotas, retry logic handles automatically
- DLQ growth
- Investigate error patterns → fix root cause → redrive
Helpful commands:
aws logs filter-log-events --log-group-name "/aws/lambda/AILambda" --start-time $(date -d '1 hour ago' +%s)000
aws ssm get-parameter --name "/TenderSummary/Prompts/System"
aws bedrock list-foundation-models --region us-east-1
aws sqs get-queue-attributes --queue-url https://sqs.us-east-1.amazonaws.com/211635102441/AIQueue.fifo --attribute-names All- Enhanced AI: Fine-tuning models for even better summary quality
- Smart tagging: Implement content-based tagging using AI insights
- Multi-language: Support for Afrikaans and other SA languages
- Analytics: Summary quality metrics and feedback loops
Built with love, bread, and code by Bread Corporation 🦆❤️💻