Skip to main content

aa_proto/
lib.rs

1//! Generated protobuf and gRPC types for Agent Assembly.
2//!
3//! This crate is the single code-generation entrypoint for all proto definitions
4//! in `proto/`. Other crates (`aa-runtime`, `aa-gateway`, …) declare this crate
5//! as a dependency — they never run their own prost/tonic codegen.
6//!
7//! # Module layout
8//!
9//! The generated modules mirror the proto package hierarchy:
10//!
11//! ```text
12//! assembly::common::v1   — shared types (AgentId, Decision, RiskTier, …)
13//! assembly::agent::v1    — lifecycle + ControlStream (paths ① ④)
14//! assembly::policy::v1   — policy check hot path (path ②)
15//! assembly::audit::v1    — async audit trail (path ③)
16//! assembly::event::v1    — internal event bus envelope (paths ⑤ ⑥)
17//! assembly::approval::v1 — human-in-the-loop approval queue
18//! assembly::topology::v1 — agent tree, lineage, and team-member queries
19//! assembly::gateway::v1  — L1 cache push-invalidation channel
20//! ```
21
22pub mod assembly {
23    pub mod common {
24        pub mod v1 {
25            tonic::include_proto!("assembly.common.v1");
26        }
27    }
28
29    pub mod agent {
30        pub mod v1 {
31            tonic::include_proto!("assembly.agent.v1");
32        }
33    }
34
35    pub mod policy {
36        pub mod v1 {
37            tonic::include_proto!("assembly.policy.v1");
38        }
39    }
40
41    pub mod audit {
42        pub mod v1 {
43            tonic::include_proto!("assembly.audit.v1");
44        }
45    }
46
47    pub mod event {
48        pub mod v1 {
49            // AuditEvent grew with AAASM-934 lineage fields; the Payload oneof
50            // variant size disparity is expected in generated code.
51            #![allow(clippy::large_enum_variant)]
52            tonic::include_proto!("assembly.event.v1");
53        }
54    }
55
56    pub mod approval {
57        pub mod v1 {
58            tonic::include_proto!("assembly.approval.v1");
59        }
60    }
61
62    pub mod topology {
63        pub mod v1 {
64            tonic::include_proto!("assembly.topology.v1");
65        }
66    }
67
68    pub mod secrets {
69        pub mod v1 {
70            tonic::include_proto!("assembly.secrets.v1");
71        }
72    }
73
74    pub mod gateway {
75        pub mod v1 {
76            tonic::include_proto!("assembly.gateway.v1");
77        }
78    }
79}