From code to diagrams: Agentic architecture documentation with Amazon Bedrock AgentCore
Amazon Bedrock AgentCore is used to build a serverless autonomous agent that scans .NET codebases, iteratively refines and self‑corrects, and emits up‑to‑date UML or Mermaid architecture diagrams. The agent runs inside an AWS CodePipeline triggered on each commit to an AWS CodeCommit repository, and publishes the generated diagrams and their metadata into Amazon Bedrock Knowledge Bases for semantic search. This end‑to‑end pipeline has been in production since Q1 2026 for a global interdealer broker, keeping architecture documentation continuously current. Engineers can adopt the same pattern to eliminate manual diagramming effort and maintain searchable, compliance‑ready documentation automatically.
⚡ Key Takeaways
- AgentCore analyzes .NET codebases and produces comprehensive UML/Mermaid architecture diagrams.
- AgentCore provides a serverless runtime with built‑in agent lifecycle management and automatic scaling.
- The pipeline is orchestrated by AWS CodePipeline, which is triggered on code commits to AWS CodeCommit.
- Generated diagrams and metadata are ingested into Amazon Bedrock Knowledge Bases to enable semantic search and natural‑language queries.
Automating diagram generation removes a high‑touch manual step, ensuring architecture views stay accurate for onboarding, incident response, and audit compliance without extra engineering overhead.
✅ Practical Steps
- Deploy the autonomous documentation agent in an AWS CodePipeline that is triggered by pushes to an AWS CodeCommit repository.
- Configure the AgentCore agent to output UML/Mermaid diagrams and push the resulting files and metadata into an Amazon Bedrock Knowledge Base for searchable documentation.
Want the full story? Read the original article.
Read on AWS ML Blog ↗