# wasim-khans/kaie_technologies_agents architecture

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

- Interactive diagram: https://gitdiagram.com/wasim-khans/kaie_technologies_agents
- Repository: https://github.com/wasim-khans/kaie_technologies_agents

## Overview

KAIE is a local, versioned kit for guiding AI-assisted project work: the owner starts a session in an AI host, Luna coordinates specialists and activities, and the owner reviews recommendations and approves scope. The repository’s product is primarily its agent profiles, procedures, registries, and reusable guidance, with two dependency-free Python utilities for briefing/routing and project-local session and incident tracking. README-described capabilities are included; relationships to unsampled procedures are shown only where documented.

Main entry points: [`agents/orchestrator/AGENT.md`](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/agents/orchestrator/AGENT.md) (Luna orchestrator), [`scripts/kaie.py`](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/kaie.py) (KAIE CLI), [`scripts/studio.py`](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/studio.py) (Studio tracker), [`registry/activities.json`](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/registry/activities.json) (Activity registry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_coord["Session coordination"]
  node_luna["Luna orchestrator<br/>[AGENT.md]"]
  node_roles["Specialist roles"]
  node_manifests["Role manifests"]
  node_adapters["Platform adapters"]
end

subgraph group_activities["Activity workflows"]
  node_activities_registry["Activity registry<br/>[activities.json]"]
  node_procedures["Activity procedures"]
  node_library["Reusable library"]
end

subgraph group_guidance["Shared guidance"]
  node_skills["Skills registry<br/>[AGENTS.md]"]
  node_preferences["Owner preferences<br/>[PREFERENCES.md]"]
  node_rules["Common rules<br/>[COMMON_RULES.md]"]
end

subgraph group_runtime["Local utilities"]
  node_kaie_cli["KAIE CLI<br/>[kaie.py]"]
  node_studio_cli["Studio tracker<br/>[studio.py]"]
  node_studio_data[("Project session records")]
end

node_owner(("Project owner"))
node_host["AI host"]
node_target["Target project"]

node_owner -->|"starts session"| node_host
node_owner -->|"assigns task"| node_luna
node_host -->|"provides access"| node_luna
node_luna -->|"checks instructions"| node_target
node_luna -->|"checks skills"| node_skills
node_luna -->|"delegates work"| node_roles
node_luna -->|"ranks recommendations"| node_owner
node_owner -->|"approves scope"| node_target
node_luna -->|"resolves activities"| node_activities_registry
node_activities_registry -->|"selects procedure"| node_procedures
node_roles -->|"uses role data"| node_manifests
node_luna -->|"loads guidance"| node_preferences
node_luna -->|"loads guidance"| node_rules
node_luna -->|"reuses references"| node_library
node_host -->|"uses profiles"| node_adapters
node_owner -->|"requests briefing"| node_kaie_cli
node_kaie_cli -->|"reads role manifest"| node_manifests
node_kaie_cli -->|"reads activities"| node_activities_registry
node_owner -.->|"records session"| node_studio_cli
node_studio_cli -->|"writes records"| node_studio_data
node_studio_cli -->|"reports status"| node_owner

click node_luna "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/agents/orchestrator/AGENT.md"
click node_roles "https://github.com/wasim-khans/kaie_technologies_agents/tree/main/agents"
click node_manifests "https://github.com/wasim-khans/kaie_technologies_agents/tree/main/agents"
click node_skills "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/AGENTS.md"
click node_preferences "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/PREFERENCES.md"
click node_rules "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/rules/COMMON_RULES.md"
click node_activities_registry "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/registry/activities.json"
click node_procedures "https://github.com/wasim-khans/kaie_technologies_agents/tree/main/ops"
click node_library "https://github.com/wasim-khans/kaie_technologies_agents/tree/main/library"
click node_adapters "https://github.com/wasim-khans/kaie_technologies_agents/tree/main/adapters"
click node_kaie_cli "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/kaie.py"
click node_studio_cli "https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/studio.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_luna,node_roles,node_manifests,node_adapters toneBlue
class node_activities_registry,node_procedures,node_library toneAmber
class node_skills,node_preferences,node_rules toneMint
class node_kaie_cli,node_studio_cli,node_studio_data toneRose
class node_owner,node_host,node_target toneIndigo
```

## Components

### Session coordination

- [Luna orchestrator](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/agents/orchestrator/AGENT.md): `agents/orchestrator/AGENT.md`
- [Specialist roles](https://github.com/wasim-khans/kaie_technologies_agents/tree/main/agents): `agents`
- [Role manifests](https://github.com/wasim-khans/kaie_technologies_agents/tree/main/agents): `agents`
- [Platform adapters](https://github.com/wasim-khans/kaie_technologies_agents/tree/main/adapters): `adapters`

### Activity workflows

- [Activity registry](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/registry/activities.json): `registry/activities.json`
- [Activity procedures](https://github.com/wasim-khans/kaie_technologies_agents/tree/main/ops): `ops`
- [Reusable library](https://github.com/wasim-khans/kaie_technologies_agents/tree/main/library): `library`

### Shared guidance

- [Skills registry](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/AGENTS.md): `AGENTS.md`
- [Owner preferences](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/PREFERENCES.md): `PREFERENCES.md`
- [Common rules](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/rules/COMMON_RULES.md): `rules/COMMON_RULES.md`

### Local utilities

- [KAIE CLI](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/kaie.py): `scripts/kaie.py`
- [Studio tracker](https://github.com/wasim-khans/kaie_technologies_agents/blob/main/scripts/studio.py): `scripts/studio.py`
- **Project session records**

### Other components

- **Project owner**
- **AI host**
- **Target project**

## Connections

- Project owner → AI host: starts session (evidence: `README.md`)
- Project owner → Luna orchestrator: assigns task (evidence: `README.md`)
- AI host → Luna orchestrator: provides access (evidence: `README.md`)
- Luna orchestrator → Target project: checks instructions (evidence: `README.md`)
- Luna orchestrator → Skills registry: checks skills (evidence: `README.md`)
- Luna orchestrator → Specialist roles: delegates work (evidence: `README.md`)
- Luna orchestrator → Project owner: ranks recommendations (evidence: `README.md`)
- Project owner → Target project: approves scope (evidence: `README.md`)
- Luna orchestrator → Activity registry: resolves activities (evidence: `README.md`)
- Activity registry → Activity procedures: selects procedure (evidence: `README.md`)
- Specialist roles → Role manifests: uses role data (evidence: `README.md`)
- Luna orchestrator → Owner preferences: loads guidance (evidence: `README.md`)
- Luna orchestrator → Common rules: loads guidance (evidence: `README.md`)
- Luna orchestrator → Reusable library: reuses references (evidence: `README.md`)
- AI host → Platform adapters: uses profiles (evidence: `README.md`)
- Project owner → KAIE CLI: requests briefing (evidence: `README.md`)
- KAIE CLI → Role manifests: reads role manifest (evidence: `scripts/kaie.py`)
- KAIE CLI → Activity registry: reads activities (evidence: `scripts/kaie.py`)
- Project owner → Studio tracker: records session
- Studio tracker → Project session records: writes records (evidence: `scripts/studio.py`)
- Studio tracker → Project owner: reports status (evidence: `scripts/studio.py`)
