# maketools-company/datagovernance-as-code architecture

> Architecture diagram of the GitHub repository maketools-company/datagovernance-as-code, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-20). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/maketools-company/datagovernance-as-code
- Repository: https://github.com/maketools-company/datagovernance-as-code

## Overview

DGAC is a governance-as-code tool and reference template for data domains and dbt data products. The central workflow is to declare governance and product contracts in repository files, validate them, generate derived dbt and ownership configuration, build domain products, and assemble semantic models or manifests. The README documents these capabilities; sampled implementation is concentrated in dgac/cli.py, so internal command relationships beyond the excerpts are not inferred.

Main entry points: [`dgac/cli.py`](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py) (DGAC CLI), [`domains`](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains) (Public Interfaces), [`governance/semantic/common.ossie.yaml`](https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/semantic/common.ossie.yaml) (Common Semantics), [`schemas`](https://github.com/maketools-company/datagovernance-as-code/tree/main/schemas) (Validation Schemas)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_tool["DGAC Tool"]
  node_cli["DGAC CLI<br/>[cli.py]"]
  node_validation["Governance Validation<br/>[cli.py]"]
  node_generation["Config Generation<br/>[cli.py]"]
  node_domain_setup["Domain Setup<br/>[cli.py]"]
  node_product_setup["Product Setup<br/>[cli.py]"]
  node_schemas["Validation Schemas"]
  node_dbt_build["dbt Build<br/>[cli.py]"]
end

subgraph group_hub["Central Governance"]
  node_hub_config["Hub Configuration<br/>[hub.yml]"]
  node_classification["Sensitivity Levels"]
  node_glossary["Business Glossaries"]
  node_common_semantics["Common Semantics<br/>[common.ossie.yaml]"]
end

subgraph group_domains["Domain Products"]
  node_domain_governance["Domain Governance"]
  node_product_cards["Product Cards"]
  node_dbt_models["Product Models"]
  node_public_interfaces["Public Interfaces"]
  node_contracts["Interface Contracts"]
  node_external_reads["Cross-Domain Reads"]
  node_product_semantics["Product Semantics"]
end

subgraph group_outputs["Published Outputs"]
  node_semantic_assembly["Semantic Assembly<br/>[cli.py]"]
  node_manifest["Governance Manifest<br/>[cli.py]"]
end

node_team(("Data Teams"))

node_team -->|"runs commands"| node_cli
node_cli -->|"dispatches"| node_validation
node_validation -->|"checks against"| node_schemas
node_cli -->|"dispatches"| node_generation
node_generation -.->|"reads governance"| node_hub_config
node_generation -->|"generates config"| node_domain_governance
node_cli -->|"dispatches"| node_domain_setup
node_domain_setup -->|"creates domain"| node_domain_governance
node_cli -->|"dispatches"| node_product_setup
node_product_setup -->|"creates card"| node_product_cards
node_dbt_build -->|"builds models"| node_dbt_models
node_dbt_models -->|"publishes"| node_public_interfaces
node_public_interfaces -->|"documented by"| node_contracts
node_external_reads -->|"references interface"| node_public_interfaces
node_product_semantics -->|"derives metrics"| node_common_semantics
node_semantic_assembly -->|"combines with"| node_common_semantics
node_semantic_assembly -->|"combines with"| node_product_semantics
node_cli -->|"dispatches"| node_dbt_build
node_cli -->|"dispatches"| node_semantic_assembly
node_cli -->|"dispatches"| node_manifest
node_manifest -->|"reports governance"| node_domain_governance
node_manifest -->|"reports interfaces"| node_public_interfaces
node_manifest -->|"reports consumption"| node_external_reads

click node_cli "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_validation "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_generation "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_domain_setup "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_product_setup "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_hub_config "https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/hub.yml"
click node_classification "https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/classification.yaml"
click node_glossary "https://github.com/maketools-company/datagovernance-as-code/tree/main/governance/glossary"
click node_common_semantics "https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/semantic/common.ossie.yaml"
click node_domain_governance "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_product_cards "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_dbt_models "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_public_interfaces "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_contracts "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_external_reads "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_product_semantics "https://github.com/maketools-company/datagovernance-as-code/tree/main/domains"
click node_schemas "https://github.com/maketools-company/datagovernance-as-code/tree/main/schemas"
click node_dbt_build "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_semantic_assembly "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"
click node_manifest "https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py"

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_cli,node_validation,node_generation,node_domain_setup,node_product_setup,node_schemas,node_dbt_build toneBlue
class node_hub_config,node_classification,node_glossary,node_common_semantics toneAmber
class node_domain_governance,node_product_cards,node_dbt_models,node_public_interfaces,node_contracts,node_external_reads,node_product_semantics toneMint
class node_semantic_assembly,node_manifest toneRose
class node_team toneIndigo
```

## Components

### DGAC Tool

- [DGAC CLI](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Governance Validation](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Config Generation](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Domain Setup](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Product Setup](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Validation Schemas](https://github.com/maketools-company/datagovernance-as-code/tree/main/schemas): `schemas`
- [dbt Build](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`

### Central Governance

- [Hub Configuration](https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/hub.yml): `governance/hub.yml`
- [Sensitivity Levels](https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/classification.yaml): `governance/classification.yaml`
- [Business Glossaries](https://github.com/maketools-company/datagovernance-as-code/tree/main/governance/glossary): `governance/glossary`
- [Common Semantics](https://github.com/maketools-company/datagovernance-as-code/blob/main/governance/semantic/common.ossie.yaml): `governance/semantic/common.ossie.yaml`

### Domain Products

- [Domain Governance](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Product Cards](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Product Models](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Public Interfaces](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Interface Contracts](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Cross-Domain Reads](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`
- [Product Semantics](https://github.com/maketools-company/datagovernance-as-code/tree/main/domains): `domains`

### Published Outputs

- [Semantic Assembly](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`
- [Governance Manifest](https://github.com/maketools-company/datagovernance-as-code/blob/main/dgac/cli.py): `dgac/cli.py`

### Other components

- **Data Teams**

## Connections

- Data Teams → DGAC CLI: runs commands (evidence: `README.md`)
- DGAC CLI → Governance Validation: dispatches (evidence: `README.md`)
- Governance Validation → Validation Schemas: checks against (evidence: `README.md`)
- DGAC CLI → Config Generation: dispatches (evidence: `README.md`)
- Config Generation → Hub Configuration: reads governance
- Config Generation → Domain Governance: generates config (evidence: `README.md`)
- DGAC CLI → Domain Setup: dispatches (evidence: `README.md`)
- Domain Setup → Domain Governance: creates domain (evidence: `README.md`)
- DGAC CLI → Product Setup: dispatches (evidence: `README.md`)
- Product Setup → Product Cards: creates card (evidence: `README.md`)
- dbt Build → Product Models: builds models (evidence: `README.md`)
- Product Models → Public Interfaces: publishes (evidence: `README.md`)
- Public Interfaces → Interface Contracts: documented by (evidence: `README.md`)
- Cross-Domain Reads → Public Interfaces: references interface (evidence: `README.md`)
- Product Semantics → Common Semantics: derives metrics (evidence: `README.md`)
- Semantic Assembly → Common Semantics: combines with (evidence: `README.md`)
- Semantic Assembly → Product Semantics: combines with (evidence: `README.md`)
- DGAC CLI → dbt Build: dispatches (evidence: `README.md`)
- DGAC CLI → Semantic Assembly: dispatches (evidence: `README.md`)
- DGAC CLI → Governance Manifest: dispatches (evidence: `README.md`)
- Governance Manifest → Domain Governance: reports governance (evidence: `README.md`)
- Governance Manifest → Public Interfaces: reports interfaces (evidence: `README.md`)
- Governance Manifest → Cross-Domain Reads: reports consumption (evidence: `README.md`)
