How aws-solutions-library-samples/qnabot-on-aws works
QnABot on AWS is a multi-channel, multilingual conversational support product with a Content Designer for managing its question bank and settings. The main user flow runs from a chat or voice channel through Lex and Bot Fulfillment, which searches OpenSearch and can use language services, Bedrock, Kendra, and streaming; interaction logs support later analysis. The graph also shows administration, content ingestion, integrations, and core fulfillment internals. Runtime links are grounded in the README or shown source references; unsampled subsystem details are represented only where the README documents them.
Main entry points: fulfillment/index.js Bot Fulfillment · es_query.js Question search · router.js Admin tools · master/index.js Content Lambda
Components 30
Content administration
- Content Designer
source/website/js/components/designer/index.vue - Admin tools
source/website/js/lib/router.js
Content and search
- Content API
source/templates/master/routes/index.js - Content Lambda
source/templates/master/index.js - Question bank
- Settings store
- Content import
source/lambda/import/index.js - Content export
source/lambda/export/index.js - Embedding models
source/lambda/es-proxy-layer/lib/bedrock/bedrockClient.js
Conversation runtime
- Bot Fulfillment
source/lambda/fulfillment/index.js - Query middleware
source/lambda/fulfillment/lib/middleware/3_query.js - Lex router
source/lambda/fulfillment/lib/middleware/lexRouter.js - Language handling
source/lambda/fulfillment/lib/middleware/multilanguage.js - Specialty bots
source/lambda/fulfillment/lib/middleware/specialtyBotRouter.js - Question search
source/lambda/es-proxy-layer/lib/es_query.js - Query builder
source/lambda/es-proxy-layer/lib/esbodybuilder.js - QID matching
source/lambda/es-proxy-layer/lib/fulfillment-event/qid.js - Kendra FAQ lookup
source/lambda/es-proxy-layer/lib/fulfillment-event/runKendraQuery.js - Kendra query
source/lambda/es-proxy-layer/lib/kendraQuery.js - Kendra client
source/lambda/es-proxy-layer/lib/kendraClient.js - Amazon Bedrock
- Amazon Kendra
- Language services
Channels and operations
- Chat and voice
source/website/js/client.vue - Amazon Lex
source/templates/master/lex/fulfillment.js - Streaming WebSocket
source/lambda/streaming/index.js - Kinesis Firehose
- S3 analytics
Other components
- Administrator
- Chat user
Connections 34
- Administrator → Content Designer: manages content
README.md - Content Designer → Content API: saves questions
README.md - Admin tools → Content Designer: routes to
source/website/js/lib/router.js - Admin tools → Content import: routes to import
- Admin tools → Content export: routes to export
source/website/js/lib/router.js - Admin tools → Settings store: routes to settings
source/website/js/lib/router.js - Content API → Content Lambda: invokes
README.md - Content Lambda → Question bank: writes questions
README.md - Content Lambda → Settings store: writes settings
README.md - Content Lambda → Embedding models: requests embeddings
README.md - Embedding models → Question bank: embeds content
README.md - Chat user → Chat and voice: asks question
README.md - Chat and voice → Amazon Lex: sends interaction
README.md - Amazon Lex → Bot Fulfillment: forwards request
README.md - Bot Fulfillment → Query middleware: processes request
- Query middleware → Lex router: routes query
source/lambda/fulfillment/lib/middleware/3_query.js - Lex router → Language handling: uses language handling
source/lambda/fulfillment/lib/middleware/lexRouter.js - Lex router → Specialty bots: routes specialty bot
source/lambda/fulfillment/lib/middleware/lexRouter.js - Query middleware → Specialty bots: invokes router
source/lambda/fulfillment/lib/middleware/3_query.js - Bot Fulfillment → Question search: searches questions
README.md - Question search → Query builder: builds query
source/lambda/es-proxy-layer/lib/es_query.js - Question search → QID matching: checks QID
source/lambda/es-proxy-layer/lib/es_query.js - Question search → Question bank: searches index
README.md - Bot Fulfillment → Language services: translates requests
README.md - Bot Fulfillment → Amazon Bedrock: uses LLM features
README.md - Bot Fulfillment → Kendra FAQ lookup: checks FAQ fallback
- Kendra FAQ lookup → Kendra query: runs lookup
source/lambda/es-proxy-layer/lib/fulfillment-event/runKendraQuery.js - Kendra FAQ lookup → Kendra client: determines language
source/lambda/es-proxy-layer/lib/fulfillment-event/runKendraQuery.js - Kendra query → Question search: retrieves QID match
source/lambda/es-proxy-layer/lib/kendraQuery.js - Kendra query → Kendra client: uses client
source/lambda/es-proxy-layer/lib/kendraQuery.js - Kendra query → Amazon Kendra: queries index
README.md - Bot Fulfillment → Streaming WebSocket: streams response
README.md - Bot Fulfillment → Kinesis Firehose: sends logs
README.md - Kinesis Firehose → S3 analytics: delivers records
README.md