# Repo-to-Blueprint: Security Audit, DFD & Flowchart Generator

> Audits codebases for security flaws and generates deterministic, code-traced system diagrams and DFDs.

Repo-to-Blueprint: Security Audit, DFD & Flowchart Generator is a paid AI agent skill on Agensi by Kristian Carlo Rosales, in LLM Ops. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: $9 (one-time purchase)
- Creator: [Kristian Carlo Rosales](https://www.agensi.io/creators/kristian-carlo-rosales)
- Category: [LLM Ops](https://www.agensi.io/skills/llm-ops)
- Version: 1.0
- Last updated: 2026-11-30
- Security: scan passed (2026-11-30); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/repo-to-blueprint-security-audit-dfd-flowchart-generator
- Tags: llm-ops, security, documentation, code-review, python, mermaid

## About this skill

When you build an application using AI assistance, it is easy to lose track of the underlying architecture and overlook critical security flaws. This skill audits your codebase for common "vibe-coding" mistakes and generates professional system diagrams that reflect the actual implementation. It stops guesswork by mapping every architectural node directly to specific lines of code.

### What it does
- **Security Auditing** scans for hardcoded secrets, exposed environment variables, and common logic flaws with file and line references.
- **Architecture Mapping** generates system charts including DFDs, ERDs, and flowcharts based on deterministic code facts.
- **Notation Compliance** draws Data Flow Diagrams using industry-standard notations like Yourdon & DeMarco or Gane & Sarson.
- **Diagram Validation** runs syntax checks on all generated Mermaid and SVG charts to ensure they are render-ready.
- **Report Consolidation** builds a single-page HTML viewer containing the full security audit and all system diagrams.

### How it works
1. **Fact Collection** runs local Python scripts to extract routes, schemas, and potential vulnerabilities into JSON fact files.
2. **Finding Review** analyzes the facts to categorize security risks by severity while filtering out false positives.
3. **Chart Generation** draws system diagrams where every element is tagged with a source code comment for traceability.
4. **Validation and Packaging** checks diagram syntax and compiles the findings into `SECURITY_AUDIT.md`, `SYSTEM_CHARTS.md`, and an interactive HTML report.

### Frameworks & tools
This skill utilizes Python 3.9 scripts and standard library tools. It is optimized for Next.js, Express, FastAPI, Supabase, Prisma, and SQL. It generates Mermaid.js diagrams and utilizes the Mermaid CLI for render validation if available.

### Why this beats prompting it yourself
Generic prompts often hallucinate architecture or miss subtle security risks hidden in large files. This skill uses local script execution to ensure every finding and diagram node is grounded in real code facts, providing a deterministic audit that LLM context windows alone cannot replicate.

### Use cases
- Audit a project built with AI to find hidden security vulnerabilities.
- Generate technical documentation and DFDs for a legacy codebase.
- Verify that a "vibe-coded" prototype is safe for production deployment.
- Create database ERDs automatically from Prisma schemas or SQL migrations.

### Known limitations
This is a checklist of common mistakes, not a full penetration test. It cannot detect dynamic route registrations not visible to the static scanner or files over 1 MB.

## Requires

- Python 3.9+
- Optional: Git

On Windows, install Python from python.org and tick "Add python.exe to PATH". Git is optional: it lets the scan check whether .env files were committed. Reads the project folder to find routes, database schemas and risky code patterns, skipping node_modules, .git and build folders. From .env files

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the Repo-to-Blueprint: Security Audit, DFD & Flowchart Generator skill from Agensi" and describe your task.
3. Buy it on the listing or let your agent ask you first; your agent then loads it from Agensi when it needs it. Every paid skill has a money-back guarantee: https://www.agensi.io/docs/money-back-guarantee

## Frequently asked questions

### What specific problems does this skill help me solve?

This skill performs a deterministic security audit of your codebase to identify hardcoded secrets and logic flaws while generating professional system diagrams like DFDs and ERDs that are mapped directly to your source code. It is designed to help developers who use AI assistance maintain a clear understanding of their app architecture and catch common security mistakes that occur during rapid prototyping.

### What kind of reports and file formats will I receive after a scan?

The skill produces two primary Markdown reports, SECURITY_AUDIT.md and SYSTEM_CHARTS.md, along with an interactive CODEMAP_REPORT.html viewer. You also receive deterministic JSON fact files and industry standard SVG diagrams drawn in notations such as Yourdon and DeMarco or Gane and Sarson.

### Do I need to sign up for any third party services to run these audits?

You do not need any external accounts or API keys to use this skill. It requires Python 3.9 or higher and works with projects using frameworks like Next.js, Express, FastAPI, or Prisma by reading your local files and running its own collection scripts.

### Are there any types of vulnerabilities or files that this skill cannot detect?

While it is a powerful auditing tool, it is not a full penetration test and cannot detect dynamic route registrations or scan files larger than 1 MB. It serves as a checklist for common mistakes and architecture mapping rather than a guarantee that an application is perfectly secure.

### How should I phrase my request to get the most out of this skill?

You can simply ask your agent to audit your repository, generate a data flow diagram of your project, or check if your current application is ready for production. It is also effective if you specifically ask for a database ERD from your SQL migrations or Prisma schemas.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
