# lavinigam-gcp/bwg-track2 architecture

> Architecture diagram of the GitHub repository lavinigam-gcp/bwg-track2, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/lavinigam-gcp/bwg-track2
- Repository: https://github.com/lavinigam-gcp/bwg-track2

## Overview

This repository packages a guided NovaSmart AI-estate governance lab: learners gather cloud evidence, apply and verify governance controls, then record and present their findings. Its main journey spans discovery and attribution (M0), identity and privilege changes (M1), connection controls (M2), prompt screening (M3), and optional evaluation (M4). Agent skills and scripts support those activities; local setup supports running the lab without a cloud VM. Source excerpts show evidence and reporting helpers, but not the underlying cloud-query or mutation commands, so those relationships are based on the README’s workflow descriptions.

Main entry points: [`lab_material/m1-instructions.md`](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m1-instructions.md) (Split identities), [`lab_material/m0-instructions.md`](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m0-instructions.md) (Discover estate), [`lab_material/m2-instructions.md`](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m2-instructions.md) (Control connections), [`lab_material/m3-instructions.md`](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m3-instructions.md) (Screen prompts)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_journey["Governance journey"]
  node_m0["Discover estate<br/>[m0-instructions.md]"]
  node_m1["Split identities<br/>[m1-instructions.md]"]
  node_m2["Control connections<br/>[m2-instructions.md]"]
  node_m3["Screen prompts<br/>[m3-instructions.md]"]
  node_m4["Measure behavior<br/>[m4-instructions.md]"]
end

subgraph group_guides["Lab guidance"]
  node_skill["Governance agent skill<br/>[SKILL.md]"]
  node_module_refs["Module reference guides"]
  node_sync["Skill synchronizer<br/>[sync_skill.py]"]
end

subgraph group_evidence["Evidence and reporting"]
  node_evidence_files["Evidence records"]
  node_entry_writer["Evidence entry writer<br/>[write_entry.py]"]
  node_facts["Show fact sheets<br/>[show_facts.py]"]
  node_show_check["Show page checker<br/>[show_check.py]"]
  node_show_record["Show evidence recorder<br/>[show_record.py]"]
  node_scorecard["Governance scorecard"]
  node_picture["Evidence illustrations<br/>[draw_picture.py]"]
  node_proof_gate["Proof checkpoint gate<br/>[proof_gate.py]"]
end

subgraph group_environment["Local environment"]
  node_setup["Local lab setup<br/>[README.md]"]
  node_setup_scripts["Setup and verification"]
end

node_learner(("Lab participant"))
node_estate{{"NovaSmart AI estate"}}
node_cloud{{"Google Cloud surfaces"}}

node_learner -->|"starts with"| node_m0
node_m0 -->|"queries estate"| node_cloud
node_cloud -->|"returns evidence"| node_m0
node_m0 -->|"progresses to"| node_m1
node_m1 -->|"changes identity"| node_cloud
node_m1 -->|"progresses to"| node_m2
node_m2 -->|"controls access"| node_cloud
node_m2 -->|"progresses to"| node_m3
node_m3 -->|"screens content"| node_cloud
node_m3 -.->|"optionally measures"| node_m4
node_learner -->|"uses guidance"| node_skill
node_skill -.->|"consults guides"| node_module_refs
node_m0 -->|"records findings"| node_evidence_files
node_m1 -->|"records changes"| node_evidence_files
node_m2 -->|"records controls"| node_evidence_files
node_m3 -->|"records screening"| node_evidence_files
node_m4 -->|"records results"| node_evidence_files
node_entry_writer -->|"appends entries"| node_evidence_files
node_facts -->|"reads latest entries"| node_evidence_files
node_show_check -->|"checks citations"| node_evidence_files
node_show_record -->|"writes show record"| node_evidence_files
node_m1 -->|"updates progress"| node_scorecard
node_picture -->|"requests image generation"| node_cloud
node_proof_gate -->|"checks checkpoints"| node_evidence_files
node_sync -->|"refreshes guide"| node_skill
node_learner -->|"prepares environment"| node_setup
node_setup -->|"provides commands"| node_setup_scripts

click node_m0 "https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m0-instructions.md"
click node_m1 "https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m1-instructions.md"
click node_m2 "https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m2-instructions.md"
click node_m3 "https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m3-instructions.md"
click node_m4 "https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m4-instructions.md"
click node_skill "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/SKILL.md"
click node_module_refs "https://github.com/lavinigam-gcp/bwg-track2/tree/main/skills/novasmart-governance-lab/references"
click node_entry_writer "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/write_entry.py"
click node_facts "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_facts.py"
click node_show_check "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_check.py"
click node_show_record "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_record.py"
click node_scorecard "https://github.com/lavinigam-gcp/bwg-track2/blob/main/bwg-lab-setup/skills/novasmart-governance-lab/scripts/update_scorecard.py"
click node_picture "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/draw_picture.py"
click node_proof_gate "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/proof_gate.py"
click node_sync "https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/sync_skill.py"
click node_setup "https://github.com/lavinigam-gcp/bwg-track2/blob/main/bwg-lab-setup/README.md"
click node_setup_scripts "https://github.com/lavinigam-gcp/bwg-track2/tree/main/bwg-lab-setup/setup"

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_m0,node_m1,node_m2,node_m3,node_m4 toneBlue
class node_skill,node_module_refs,node_sync toneAmber
class node_evidence_files,node_entry_writer,node_facts,node_show_check,node_show_record,node_scorecard,node_picture,node_proof_gate toneMint
class node_setup,node_setup_scripts toneRose
class node_learner,node_estate,node_cloud toneIndigo
```

## Components

### Governance journey

- [Discover estate](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m0-instructions.md): `lab_material/m0-instructions.md`
- [Split identities](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m1-instructions.md): `lab_material/m1-instructions.md`
- [Control connections](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m2-instructions.md): `lab_material/m2-instructions.md`
- [Screen prompts](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m3-instructions.md): `lab_material/m3-instructions.md`
- [Measure behavior](https://github.com/lavinigam-gcp/bwg-track2/blob/main/lab_material/m4-instructions.md): `lab_material/m4-instructions.md`

### Lab guidance

- [Governance agent skill](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/SKILL.md): `skills/novasmart-governance-lab/SKILL.md`
- [Module reference guides](https://github.com/lavinigam-gcp/bwg-track2/tree/main/skills/novasmart-governance-lab/references): `skills/novasmart-governance-lab/references`
- [Skill synchronizer](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/sync_skill.py): `skills/novasmart-governance-lab/scripts/sync_skill.py`

### Evidence and reporting

- **Evidence records**
- [Evidence entry writer](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/write_entry.py): `skills/novasmart-governance-lab/scripts/write_entry.py`
- [Show fact sheets](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_facts.py): `skills/novasmart-governance-lab/scripts/show_facts.py`
- [Show page checker](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_check.py): `skills/novasmart-governance-lab/scripts/show_check.py`
- [Show evidence recorder](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/show_record.py): `skills/novasmart-governance-lab/scripts/show_record.py`
- [Governance scorecard](https://github.com/lavinigam-gcp/bwg-track2/blob/main/bwg-lab-setup/skills/novasmart-governance-lab/scripts/update_scorecard.py): `bwg-lab-setup/skills/novasmart-governance-lab/scripts/update_scorecard.py`
- [Evidence illustrations](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/draw_picture.py): `skills/novasmart-governance-lab/scripts/draw_picture.py`
- [Proof checkpoint gate](https://github.com/lavinigam-gcp/bwg-track2/blob/main/skills/novasmart-governance-lab/scripts/proof_gate.py): `skills/novasmart-governance-lab/scripts/proof_gate.py`

### Local environment

- [Local lab setup](https://github.com/lavinigam-gcp/bwg-track2/blob/main/bwg-lab-setup/README.md): `bwg-lab-setup/README.md`
- [Setup and verification](https://github.com/lavinigam-gcp/bwg-track2/tree/main/bwg-lab-setup/setup): `bwg-lab-setup/setup`

### Other components

- **Lab participant**
- **NovaSmart AI estate**
- **Google Cloud surfaces**

## Connections

- Lab participant → Discover estate: starts with (evidence: `README.md`)
- Discover estate → Google Cloud surfaces: queries estate (evidence: `README.md`)
- Google Cloud surfaces → Discover estate: returns evidence (evidence: `README.md`)
- Discover estate → Split identities: progresses to (evidence: `README.md`)
- Split identities → Google Cloud surfaces: changes identity (evidence: `README.md`)
- Split identities → Control connections: progresses to (evidence: `README.md`)
- Control connections → Google Cloud surfaces: controls access (evidence: `README.md`)
- Control connections → Screen prompts: progresses to (evidence: `README.md`)
- Screen prompts → Google Cloud surfaces: screens content (evidence: `README.md`)
- Screen prompts → Measure behavior: optionally measures (evidence: `README.md`)
- Lab participant → Governance agent skill: uses guidance (evidence: `README.md`)
- Governance agent skill → Module reference guides: consults guides
- Discover estate → Evidence records: records findings (evidence: `README.md`)
- Split identities → Evidence records: records changes (evidence: `README.md`)
- Control connections → Evidence records: records controls (evidence: `README.md`)
- Screen prompts → Evidence records: records screening (evidence: `README.md`)
- Measure behavior → Evidence records: records results (evidence: `README.md`)
- Evidence entry writer → Evidence records: appends entries (evidence: `skills/novasmart-governance-lab/scripts/write_entry.py`)
- Show fact sheets → Evidence records: reads latest entries (evidence: `skills/novasmart-governance-lab/scripts/show_facts.py`)
- Show page checker → Evidence records: checks citations (evidence: `skills/novasmart-governance-lab/scripts/show_check.py`)
- Show evidence recorder → Evidence records: writes show record (evidence: `skills/novasmart-governance-lab/scripts/show_record.py`)
- Split identities → Governance scorecard: updates progress (evidence: `README.md`)
- Evidence illustrations → Google Cloud surfaces: requests image generation (evidence: `skills/novasmart-governance-lab/scripts/draw_picture.py`)
- Proof checkpoint gate → Evidence records: checks checkpoints (evidence: `skills/novasmart-governance-lab/scripts/proof_gate.py`)
- Skill synchronizer → Governance agent skill: refreshes guide (evidence: `skills/novasmart-governance-lab/scripts/sync_skill.py`)
- Lab participant → Local lab setup: prepares environment (evidence: `README.md`)
- Local lab setup → Setup and verification: provides commands (evidence: `README.md`)
