# trumank/kismet-analyzer architecture

> Architecture diagram of the GitHub repository trumank/kismet-analyzer, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/trumank/kismet-analyzer
- Repository: https://github.com/trumank/kismet-analyzer

## Overview

KismetAnalyzer is a command-line tool for analyzing and manipulating cooked Unreal Engine assets. Its main workflow accepts asset paths or directories, generates bytecode control-flow graphs and class hierarchies, then writes browser-viewable output; it also offers JSON export and asset import/function-copy operations. The graph preserves these documented product branches and the bytecode-summary, rendering, and DOT layers. Some command-handler details are outside the excerpts, so those relationships are omitted where they cannot be evidenced.

Main entry points: [`Program.cs`](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs) (CFG generation), [`SummaryGenerator.cs`](https://github.com/trumank/kismet-analyzer/blob/master/SummaryGenerator.cs) (Bytecode summaries), [`Rendering.cs`](https://github.com/trumank/kismet-analyzer/blob/master/Rendering.cs) (Text renderers), [`Dot.cs`](https://github.com/trumank/kismet-analyzer/blob/master/Dot.cs) (DOT and HTML graph model)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_commands["CLI workflows"]
  node_program["Command handlers<br/>[Program.cs]"]
  node_asset_inputs["Asset inputs"]
  node_cfg_workflow["CFG generation<br/>[Program.cs]"]
  node_json_workflow["JSON export<br/>[Program.cs]"]
  node_hierarchy["Class hierarchy<br/>[Program.cs]"]
end

subgraph group_analysis["Bytecode analysis"]
  node_summary["Bytecode summaries"]
  node_kismet["Bytecode operations<br/>[Kismet.cs]"]
end

subgraph group_output["Graph output"]
  node_rendering["Text renderers<br/>[Rendering.cs]"]
  node_dot["DOT and HTML graph model<br/>[Dot.cs]"]
  node_outputs["Generated output"]
end

subgraph group_assets["Asset manipulation"]
  node_asset_edit["Asset copy and merge<br/>[Program.cs]"]
end

node_user(("CLI user"))
node_graphviz{{"Graphviz"}}
node_asset_files["Unreal assets"]

node_user -->|"runs commands"| node_program
node_asset_inputs -->|"supplies assets"| node_cfg_workflow
node_cfg_workflow -->|"generates CFGs"| node_summary
node_cfg_workflow -->|"generates hierarchy"| node_hierarchy
node_program -->|"copies bytecode"| node_kismet
node_summary -->|"builds graph"| node_dot
node_summary -->|"renders labels"| node_rendering
node_rendering -->|"uses HTML helpers"| node_dot
node_cfg_workflow -->|"renders SVG"| node_graphviz
node_cfg_workflow -->|"writes CFG output"| node_outputs
node_json_workflow -->|"writes JSON"| node_outputs
node_asset_files -->|"provides assets"| node_asset_edit
node_asset_edit -->|"writes modified assets"| node_asset_files

click node_program "https://github.com/trumank/kismet-analyzer/blob/master/Program.cs"
click node_cfg_workflow "https://github.com/trumank/kismet-analyzer/blob/master/Program.cs"
click node_json_workflow "https://github.com/trumank/kismet-analyzer/blob/master/Program.cs"
click node_hierarchy "https://github.com/trumank/kismet-analyzer/blob/master/Program.cs"
click node_summary "https://github.com/trumank/kismet-analyzer/blob/master/SummaryGenerator.cs"
click node_kismet "https://github.com/trumank/kismet-analyzer/blob/master/Kismet.cs"
click node_rendering "https://github.com/trumank/kismet-analyzer/blob/master/Rendering.cs"
click node_dot "https://github.com/trumank/kismet-analyzer/blob/master/Dot.cs"
click node_asset_edit "https://github.com/trumank/kismet-analyzer/blob/master/Program.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_program,node_asset_inputs,node_cfg_workflow,node_json_workflow,node_hierarchy,node_user toneBlue
class node_summary,node_kismet toneAmber
class node_rendering,node_dot,node_outputs toneMint
class node_asset_edit toneRose
class node_graphviz,node_asset_files toneIndigo
```

## Components

### CLI workflows

- [Command handlers](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs): `Program.cs`
- **Asset inputs**
- [CFG generation](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs): `Program.cs`
- [JSON export](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs): `Program.cs`
- [Class hierarchy](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs): `Program.cs`

### Bytecode analysis

- [Bytecode summaries](https://github.com/trumank/kismet-analyzer/blob/master/SummaryGenerator.cs): `SummaryGenerator.cs`
- [Bytecode operations](https://github.com/trumank/kismet-analyzer/blob/master/Kismet.cs): `Kismet.cs`

### Graph output

- [Text renderers](https://github.com/trumank/kismet-analyzer/blob/master/Rendering.cs): `Rendering.cs`
- [DOT and HTML graph model](https://github.com/trumank/kismet-analyzer/blob/master/Dot.cs): `Dot.cs`
- **Generated output**

### Asset manipulation

- [Asset copy and merge](https://github.com/trumank/kismet-analyzer/blob/master/Program.cs): `Program.cs`

### Other components

- **CLI user**
- **Graphviz**
- **Unreal assets**

## Connections

- CLI user → Command handlers: runs commands (evidence: `README.md`)
- Asset inputs → CFG generation: supplies assets (evidence: `README.md`)
- CFG generation → Bytecode summaries: generates CFGs (evidence: `README.md`)
- CFG generation → Class hierarchy: generates hierarchy (evidence: `README.md`)
- Command handlers → Bytecode operations: copies bytecode (evidence: `Program.cs`)
- Bytecode summaries → DOT and HTML graph model: builds graph (evidence: `SummaryGenerator.cs`)
- Bytecode summaries → Text renderers: renders labels (evidence: `SummaryGenerator.cs`)
- Text renderers → DOT and HTML graph model: uses HTML helpers (evidence: `Rendering.cs`)
- CFG generation → Graphviz: renders SVG (evidence: `Program.cs`)
- CFG generation → Generated output: writes CFG output (evidence: `README.md`)
- JSON export → Generated output: writes JSON (evidence: `Program.cs`)
- Unreal assets → Asset copy and merge: provides assets (evidence: `README.md`)
- Asset copy and merge → Unreal assets: writes modified assets (evidence: `Program.cs`)
