Cloud & AI Production Lab

Agentic AI Ontology
LangGraph, LangChain, GraphRAG

Agent-style AI for Millionaire Mountain: one model gateway, a graph-run answer loop, durable human flows and a boosting knowledge graph. Every design question is resolved below, with an extended design for what comes next.

🏷Classify1🔍RetrievekNN + BM25 + RRF2🎯Confidencecheck3🧬Expandsynonyms4💬Answer5✅Groundingcheck6🔁Retry orfallback7
Building blocks

What each framework does

The three layers behind Noah and the context router.

LangChain-style model gateway

One module for every embedding and chat call.

  • Masks PII, picks model from config
  • Schema-checked output
  • Deterministic local models in tests
Details →

LangGraph flows

Request-time loops and CLI flows run as graphs.

  • Retrieve, check, retry, answer
  • Owner-directed change and steward resolve
  • Step Functions stays for gold-change and self-serve
Details →

GraphRAG

One in-process knowledge graph.

  • Documents, governed fields, systems, lineage events, definitions
  • Boosts search results, never lowers them
  • Answers carry the graph path
Details →
Workstreams

The agentic AI design, workstream by workstream

Nine workstreams. Each has a notes file, an offline test and a baseline that must keep holding.

Foundation

Baseline and offline tests

  • Answer-hash baseline
  • One-click offline test run
  • Every difference must be intended
Details →

One model gateway

Chat and embeddings in one module

  • PII masked before every call
  • Number and code check, then grounding check
  • Local deterministic mode for tests
Details →

Answer loop as a graph

Retrieve, check, retry, answer

  • 3 attempts, 0.75 threshold
  • Cache hit = zero model calls
  • Low confidence opens a steward item
Details →

Durable human flows

Pause, decide, verify the fix

  • Interrupt and resume on DynamoDB
  • Self-approval refused
  • Original question re-asked after the fix
Details →

GraphRAG as a boost

One knowledge graph

  • Lineage, catalog, glossary, articles
  • Boost raises, never lowers
  • Blast radius for a changed column
Details →

Config-driven rules

Scoped definitions

  • Versioned routing rules
  • Most specific scope wins
  • Conflict banner on disagreement
Details →

Feedback learning

Ratings become labels

  • Weights clamped to 0.15-0.55
  • Live only after the offline gate
  • Daily quality monitor
Details →

Platform hygiene

Small items in parallel

  • SSM parameters, alarms to one topic
  • Backup with second-region copy
  • Athena cap, Iceberg compaction
Details →

Containers and graph benchmark lab

Three phases

  • Neo4j, Memgraph, ArangoDB on one box
  • Fargate load generators, S3 export
  • Disposable EKS for cluster engines
Details →
Design decisions

What was chosen, and why

Each question from the original outline now has an answer.

Language for the agent layer

Chosen: Node.js

  • LangGraph.js, LangChain, @langchain/aws
  • One runtime for every Lambda
Details →

Where durable human flows live

Chosen: split by job

  • Step Functions: gold-change, self-serve
  • LangGraph.js: request loops, approvals
Details →

Checkpointer store

Chosen: DynamoDB

  • Serverless, no idle cost
  • 30-day expiry, point-in-time recovery
Details →

IaC tool for new stacks

Chosen: CloudFormation

  • Application stacks: CloudFormation
  • Labs: Terraform
Details →

Vector store

Chosen: S3 snapshot, Aurora on demand

  • S3 snapshot in memory: $0 idle
  • Aurora pgvector via one SSM switch
  • OpenSearch retired
Details →

Graph store

Chosen: Neo4j with S3 fallback

  • Neo4j Community on EC2
  • S3 adjacency export when stopped
Details →

Bedrock access

Chosen: per-model quotas

  • Haiku 4.5 and Titan V2 quotas
  • US cross-region inference profiles
Details →

Chat model

Chosen: Claude Haiku 4.5

  • Sonnet 4.6 or Nova Micro by parameter
  • IAM for the chosen model only
Details →

Model ID location

Chosen: stack parameter

  • Reviewed, rollback-able change
  • IAM follows the parameter
Details →
Roadmap vision

Extended design

Ten additions that complete the design. Click a node.

Answer qualityData and platformTyped answersschema + fallbackGuardrailshardeningQuality gatesevaluator + baselineFeedbackbias-aware retrainApproval storeTTL + recoveryKnowledge graphincremental + summariesBenchmark labLDBC workloadsVector scale-uppgvector + S3 VectorsModel capacityquotas + profilesProtectionbackup + compaction
Delivery

Order and verification

Click a node for its place in the order.

1Alone first2In parallel3Next4Then5As time allowsFoundationModel gatewayConfig-driven rulesPlatform hygieneAnswer loopDurable human flowsGraphRAGFeedback learningAPI stack changeBenchmark lab phases

Before each workstream

Safety copy.

  • S3 backup
  • Copy of changed files
Details →

After each workstream

Baseline re-run.

  • Re-run the baseline
  • Any difference must be intended and written in the notes
Details →

Live features

Switch-gated.

  • Behind switches
  • On only after the baseline holds
Details →