// This file is @generated by prost-build.
/// Stream 0x01 — Gossip
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GossipFrame {
    #[prost(uint32, tag = "1")]
    pub r#gen: u32,
    #[prost(message, repeated, tag = "2")]
    pub peers: ::prost::alloc::vec::Vec<PeerAnnouncement>,
    /// must be exactly 32 bytes; must match QUIC peer identity
    #[prost(bytes = "vec", tag = "3")]
    pub sender_id: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct PeerAnnouncement {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub endpoint_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(enumeration = "NodeRole", tag = "2")]
    pub role: i32,
    #[prost(uint32, optional, tag = "3")]
    pub http_port: ::core::option::Option<u32>,
    #[prost(string, optional, tag = "4")]
    pub version: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].name
    #[prost(string, optional, tag = "5")]
    pub gpu_name: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.hostname
    #[prost(string, optional, tag = "6")]
    pub hostname: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.is_soc; true for system-on-chip / unified-memory hosts such as Apple Silicon and Jetson
    #[prost(bool, optional, tag = "7")]
    pub is_soc: ::core::option::Option<bool>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].vram_bytes
    #[prost(string, optional, tag = "8")]
    pub gpu_vram: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.55.0 for protobuf gossip; compatibility surface only
    #[prost(string, repeated, tag = "9")]
    pub available_models: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    /// Deprecated in v0.55.0: prefer served_model_identities and served_model_runtime
    #[prost(string, repeated, tag = "10")]
    pub serving_models: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    #[prost(string, repeated, tag = "11")]
    pub requested_models: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    #[prost(message, repeated, tag = "12")]
    pub available_model_metadata: ::prost::alloc::vec::Vec<CompactModelMetadata>,
    #[prost(message, optional, tag = "13")]
    pub experts_summary: ::core::option::Option<ExpertsSummary>,
    #[prost(uint32, optional, tag = "14")]
    pub rtt_ms: ::core::option::Option<u32>,
    /// GGUF model names (mesh catalog contribution; was JSON `models`)
    #[prost(string, repeated, tag = "15")]
    pub catalog_models: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    /// GPU VRAM in bytes
    #[prost(uint64, tag = "16")]
    pub vram_bytes: u64,
    /// how to obtain this node's model
    #[prost(string, optional, tag = "17")]
    pub model_source: ::core::option::Option<::prost::alloc::string::String>,
    /// primary serving model (backward compat; was JSON `serving`)
    #[prost(string, optional, tag = "18")]
    pub primary_serving: ::core::option::Option<::prost::alloc::string::String>,
    /// stable mesh identity (self entry only)
    #[prost(string, optional, tag = "19")]
    pub mesh_id: ::core::option::Option<::prost::alloc::string::String>,
    /// demand map entries (self entry only)
    #[prost(message, repeated, tag = "20")]
    pub demand: ::prost::alloc::vec::Vec<ModelDemandEntry>,
    /// file sizes (bytes) per GGUF model name
    #[prost(map = "string, uint64", tag = "21")]
    pub available_model_sizes: ::std::collections::HashMap<::prost::alloc::string::String, u64>,
    /// JSON-serialized EndpointAddr (includes network addresses for peer discovery)
    #[prost(bytes = "vec", tag = "22")]
    pub serialized_addr: ::prost::alloc::vec::Vec<u8>,
    /// actually routable / healthy
    #[prost(string, repeated, tag = "23")]
    pub hosted_models: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    /// false/absent when relayed from legacy JSON peers
    #[prost(bool, optional, tag = "24")]
    pub hosted_models_known: ::core::option::Option<bool>,
    #[prost(message, repeated, tag = "25")]
    pub served_model_descriptors: ::prost::alloc::vec::Vec<ServedModelDescriptor>,
    #[prost(message, repeated, tag = "26")]
    pub served_model_identities: ::prost::alloc::vec::Vec<ServedModelIdentity>,
    #[prost(message, repeated, tag = "27")]
    pub served_model_runtime: ::prost::alloc::vec::Vec<ModelRuntimeDescriptor>,
    #[prost(message, optional, tag = "28")]
    pub owner_attestation: ::core::option::Option<SignedNodeOwnership>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].mem_bandwidth_gbps
    #[prost(string, optional, tag = "29")]
    pub gpu_mem_bandwidth_gbps: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].compute_tflops_fp32
    #[prost(string, optional, tag = "30")]
    pub gpu_compute_tflops_fp32: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].compute_tflops_fp16
    #[prost(string, optional, tag = "31")]
    pub gpu_compute_tflops_fp16: ::core::option::Option<::prost::alloc::string::String>,
    /// Deprecated in v0.60.0: prefer hardware.gpus\[\].reserved_bytes
    #[prost(string, optional, tag = "32")]
    pub gpu_reserved_bytes: ::core::option::Option<::prost::alloc::string::String>,
    /// Introduced in v0.60.0; preferred structured hardware inventory
    #[prost(message, optional, tag = "33")]
    pub hardware: ::core::option::Option<HardwareInfo>,
    #[prost(uint64, optional, tag = "34")]
    pub first_joined_mesh_ts: ::core::option::Option<u64>,
    /// Advisory canonical refs this node wants the mesh to consider
    #[prost(string, repeated, tag = "35")]
    pub explicit_model_interests: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    /// Additive feature discovery for admitted subsystem protocols
    #[prost(message, repeated, tag = "37")]
    pub subprotocols: ::prost::alloc::vec::Vec<MeshSubprotocol>,
    #[prost(uint32, optional, tag = "40")]
    pub latency_ms: ::core::option::Option<u32>,
    #[prost(enumeration = "LatencySource", tag = "41")]
    pub latency_source: i32,
    #[prost(uint32, optional, tag = "42")]
    pub latency_age_ms: ::core::option::Option<u32>,
    #[prost(bytes = "vec", optional, tag = "43")]
    pub latency_observer_id: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MeshSubprotocol {
    /// e.g. "skippy-stage"
    #[prost(string, tag = "1")]
    pub name: ::prost::alloc::string::String,
    /// subprotocol major version
    #[prost(uint32, tag = "2")]
    pub major: u32,
    /// e.g. "artifact-transfer"
    #[prost(string, repeated, tag = "3")]
    pub features: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MeshSubprotocolOpen {
    #[prost(uint32, tag = "1")]
    pub gen: u32,
    /// e.g. "skippy-stage"
    #[prost(string, tag = "2")]
    pub name: ::prost::alloc::string::String,
    /// subprotocol major version
    #[prost(uint32, tag = "3")]
    pub major: u32,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct HardwareInfo {
    /// True for system-on-chip / unified-memory hosts such as Apple Silicon and Jetson
    #[prost(bool, optional, tag = "1")]
    pub is_soc: ::core::option::Option<bool>,
    #[prost(string, optional, tag = "2")]
    pub hostname: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(message, repeated, tag = "3")]
    pub gpus: ::prost::alloc::vec::Vec<GpuInfo>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct GpuInfo {
    #[prost(string, optional, tag = "1")]
    pub name: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "2")]
    pub vram_bytes: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "3")]
    pub reserved_bytes: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "4")]
    pub mem_bandwidth_gbps: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "5")]
    pub compute_tflops_fp32: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "6")]
    pub compute_tflops_fp16: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct SignedNodeOwnership {
    #[prost(uint32, tag = "1")]
    pub version: u32,
    #[prost(string, tag = "2")]
    pub cert_id: ::prost::alloc::string::String,
    #[prost(string, tag = "3")]
    pub owner_id: ::prost::alloc::string::String,
    /// 32 bytes
    #[prost(bytes = "vec", tag = "4")]
    pub owner_sign_public_key: ::prost::alloc::vec::Vec<u8>,
    /// 32 bytes
    #[prost(bytes = "vec", tag = "5")]
    pub node_endpoint_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(uint64, tag = "6")]
    pub issued_at_unix_ms: u64,
    #[prost(uint64, tag = "7")]
    pub expires_at_unix_ms: u64,
    #[prost(string, optional, tag = "8")]
    pub node_label: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "9")]
    pub hostname_hint: ::core::option::Option<::prost::alloc::string::String>,
    /// Ed25519 signature over canonical claim bytes
    #[prost(bytes = "vec", tag = "10")]
    pub signature: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ServedModelDescriptor {
    #[prost(message, optional, tag = "1")]
    pub identity: ::core::option::Option<ServedModelIdentity>,
    #[prost(message, optional, tag = "2")]
    pub capabilities: ::core::option::Option<ModelCapabilities>,
    #[prost(message, optional, tag = "3")]
    pub topology: ::core::option::Option<ModelTopology>,
    #[prost(bool, optional, tag = "4")]
    pub capabilities_known: ::core::option::Option<bool>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ServedModelIdentity {
    #[prost(string, tag = "1")]
    pub model_name: ::prost::alloc::string::String,
    #[prost(bool, tag = "2")]
    pub is_primary: bool,
    #[prost(enumeration = "ModelSourceKind", tag = "3")]
    pub source_kind: i32,
    #[prost(string, optional, tag = "4")]
    pub canonical_ref: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "5")]
    pub repository: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "6")]
    pub revision: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "7")]
    pub artifact: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "8")]
    pub local_file_name: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "9")]
    pub identity_hash: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ModelCapabilities {
    #[prost(enumeration = "CapabilityLevel", tag = "1")]
    pub vision: i32,
    #[prost(enumeration = "CapabilityLevel", tag = "2")]
    pub reasoning: i32,
    #[prost(enumeration = "CapabilityLevel", tag = "3")]
    pub tool_use: i32,
    #[prost(bool, tag = "4")]
    pub moe: bool,
    #[prost(bool, tag = "5")]
    pub multimodal: bool,
    #[prost(enumeration = "CapabilityLevel", tag = "6")]
    pub audio: i32,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ModelTopology {
    #[prost(message, optional, tag = "1")]
    pub moe: ::core::option::Option<ModelMoeInfo>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ModelRuntimeDescriptor {
    #[prost(string, tag = "1")]
    pub model_name: ::prost::alloc::string::String,
    #[prost(string, optional, tag = "2")]
    pub identity_hash: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(uint32, optional, tag = "3")]
    pub context_length: ::core::option::Option<u32>,
    #[prost(bool, tag = "4")]
    pub ready: bool,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ModelMoeInfo {
    #[prost(uint32, tag = "1")]
    pub expert_count: u32,
    #[prost(uint32, tag = "2")]
    pub used_expert_count: u32,
    #[prost(uint32, optional, tag = "3")]
    pub min_experts_per_node: ::core::option::Option<u32>,
    #[prost(string, optional, tag = "4")]
    pub source: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "5")]
    pub ranking_source: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(uint32, repeated, tag = "6")]
    pub ranking: ::prost::alloc::vec::Vec<u32>,
    #[prost(uint32, optional, tag = "7")]
    pub ranking_prompt_count: ::core::option::Option<u32>,
    #[prost(uint32, optional, tag = "8")]
    pub ranking_tokens: ::core::option::Option<u32>,
    #[prost(string, optional, tag = "9")]
    pub ranking_layer_scope: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "10")]
    pub ranking_origin: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct CompactModelMetadata {
    #[prost(string, tag = "1")]
    pub model_key: ::prost::alloc::string::String,
    #[prost(uint32, tag = "2")]
    pub context_length: u32,
    #[prost(uint32, tag = "3")]
    pub vocab_size: u32,
    #[prost(uint32, tag = "4")]
    pub embedding_size: u32,
    #[prost(uint32, tag = "5")]
    pub head_count: u32,
    #[prost(uint32, tag = "6")]
    pub layer_count: u32,
    #[prost(uint32, tag = "7")]
    pub feed_forward_length: u32,
    #[prost(uint32, tag = "8")]
    pub key_length: u32,
    #[prost(uint32, tag = "9")]
    pub value_length: u32,
    #[prost(string, tag = "10")]
    pub architecture: ::prost::alloc::string::String,
    #[prost(string, tag = "11")]
    pub tokenizer_model_name: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "12")]
    pub special_tokens: ::prost::alloc::vec::Vec<SpecialToken>,
    #[prost(float, tag = "13")]
    pub rope_scale: f32,
    #[prost(float, tag = "14")]
    pub rope_freq_base: f32,
    #[prost(bool, tag = "15")]
    pub is_moe: bool,
    #[prost(uint32, tag = "16")]
    pub expert_count: u32,
    #[prost(uint32, tag = "17")]
    pub used_expert_count: u32,
    /// GGUF quantization type string (e.g. "Q4_K_M")
    #[prost(string, tag = "18")]
    pub quantization_type: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct SpecialToken {
    #[prost(string, tag = "1")]
    pub name: ::prost::alloc::string::String,
    #[prost(uint32, tag = "2")]
    pub token_id: u32,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ExpertsSummary {
    #[prost(uint32, tag = "1")]
    pub total_experts: u32,
    #[prost(uint32, tag = "2")]
    pub expert_count_used: u32,
    #[prost(uint32, repeated, tag = "3")]
    pub top_expert_ids: ::prost::alloc::vec::Vec<u32>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ModelDemandEntry {
    #[prost(string, tag = "1")]
    pub model_name: ::prost::alloc::string::String,
    #[prost(uint64, tag = "2")]
    pub last_active: u64,
    #[prost(uint64, tag = "3")]
    pub request_count: u64,
}
/// Stream 0x03 — Tunnel Map
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct TunnelMap {
    #[prost(bytes = "vec", tag = "1")]
    pub owner_peer_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(message, repeated, tag = "2")]
    pub entries: ::prost::alloc::vec::Vec<TunnelEntry>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct TunnelEntry {
    #[prost(bytes = "vec", tag = "1")]
    pub target_peer_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(bytes = "vec", optional, tag = "2")]
    pub relay_peer_id: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
    #[prost(uint32, tag = "3")]
    pub tunnel_port: u32,
}
/// Stream 0x05 — Route Table
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct RouteTableRequest {
    /// 0 or exactly 32 bytes (passive callers may omit)
    #[prost(bytes = "vec", tag = "1")]
    pub requester_id: ::prost::alloc::vec::Vec<u8>,
    /// must equal NODE_PROTOCOL_GENERATION; rejected otherwise
    #[prost(uint32, tag = "2")]
    pub r#gen: u32,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct RouteTable {
    #[prost(message, repeated, tag = "1")]
    pub entries: ::prost::alloc::vec::Vec<RouteEntry>,
    /// stable mesh identity — passive/client callers learn this here
    #[prost(string, optional, tag = "2")]
    pub mesh_id: ::core::option::Option<::prost::alloc::string::String>,
    /// must equal NODE_PROTOCOL_GENERATION; caller rejects mismatches
    #[prost(uint32, tag = "3")]
    pub r#gen: u32,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct RouteEntry {
    /// exactly 32 bytes (peer public key)
    #[prost(bytes = "vec", tag = "1")]
    pub endpoint_id: ::prost::alloc::vec::Vec<u8>,
    /// model being served (empty if node is not actively serving)
    #[prost(string, tag = "2")]
    pub model: ::prost::alloc::string::String,
}
/// Stream 0x06 — Peer Down
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct PeerDown {
    /// exactly 32 bytes; the peer being reported as unreachable
    #[prost(bytes = "vec", tag = "1")]
    pub peer_id: ::prost::alloc::vec::Vec<u8>,
    /// must equal NODE_PROTOCOL_GENERATION; rejected otherwise
    #[prost(uint32, tag = "2")]
    pub r#gen: u32,
}
/// Stream 0x07 — Peer Leaving
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct PeerLeaving {
    /// exactly 32 bytes; must match the QUIC sender identity
    #[prost(bytes = "vec", tag = "1")]
    pub peer_id: ::prost::alloc::vec::Vec<u8>,
    /// must equal NODE_PROTOCOL_GENERATION; rejected otherwise
    #[prost(uint32, tag = "2")]
    pub r#gen: u32,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct NodeConfigSnapshot {
    /// config schema version (currently 1)
    #[prost(uint32, tag = "1")]
    pub version: u32,
    #[prost(message, optional, tag = "2")]
    pub gpu: ::core::option::Option<NodeGpuConfig>,
    #[prost(message, repeated, tag = "3")]
    pub models: ::prost::alloc::vec::Vec<NodeModelEntry>,
    #[prost(message, repeated, tag = "4")]
    pub plugins: ::prost::alloc::vec::Vec<NodePluginEntry>,
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct NodeGpuConfig {
    #[prost(enumeration = "GpuAssignment", tag = "1")]
    pub assignment: i32,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct ConfiguredModelRef {
    #[prost(string, tag = "1")]
    pub declared_ref: ::prost::alloc::string::String,
    #[prost(string, optional, tag = "2")]
    pub source_kind: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, optional, tag = "3")]
    pub revision: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct NodeModelEntry {
    #[prost(string, tag = "1")]
    pub model: ::prost::alloc::string::String,
    #[prost(string, optional, tag = "2")]
    pub mmproj: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(uint32, optional, tag = "3")]
    pub ctx_size: ::core::option::Option<u32>,
    #[prost(string, optional, tag = "4")]
    pub gpu_id: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(message, optional, tag = "5")]
    pub model_ref: ::core::option::Option<ConfiguredModelRef>,
    #[prost(message, optional, tag = "6")]
    pub mmproj_ref: ::core::option::Option<ConfiguredModelRef>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct NodePluginEntry {
    #[prost(string, tag = "1")]
    pub name: ::prost::alloc::string::String,
    #[prost(bool, optional, tag = "2")]
    pub enabled: ::core::option::Option<bool>,
    #[prost(string, optional, tag = "3")]
    pub command: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(string, repeated, tag = "4")]
    pub args: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlEnvelope {
    /// must equal NODE_PROTOCOL_GENERATION
    #[prost(uint32, tag = "1")]
    pub r#gen: u32,
    #[prost(message, optional, tag = "2")]
    pub handshake: ::core::option::Option<OwnerControlHandshake>,
    #[prost(message, optional, tag = "3")]
    pub request: ::core::option::Option<OwnerControlRequest>,
    #[prost(message, optional, tag = "4")]
    pub response: ::core::option::Option<OwnerControlResponse>,
    #[prost(message, optional, tag = "5")]
    pub error: ::core::option::Option<OwnerControlError>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlHandshake {
    #[prost(message, optional, tag = "1")]
    pub ownership: ::core::option::Option<SignedNodeOwnership>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlRequest {
    #[prost(uint64, tag = "1")]
    pub request_id: u64,
    #[prost(message, optional, tag = "2")]
    pub get_config: ::core::option::Option<OwnerControlGetConfigRequest>,
    #[prost(message, optional, tag = "3")]
    pub watch_config: ::core::option::Option<OwnerControlWatchConfigRequest>,
    #[prost(message, optional, tag = "4")]
    pub apply_config: ::core::option::Option<OwnerControlApplyConfigRequest>,
    #[prost(message, optional, tag = "5")]
    pub refresh_inventory: ::core::option::Option<OwnerControlRefreshInventoryRequest>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlResponse {
    #[prost(uint64, tag = "1")]
    pub request_id: u64,
    #[prost(message, optional, tag = "2")]
    pub get_config: ::core::option::Option<OwnerControlGetConfigResponse>,
    #[prost(message, optional, tag = "3")]
    pub watch_config: ::core::option::Option<OwnerControlWatchConfigResponse>,
    #[prost(message, optional, tag = "4")]
    pub apply_config: ::core::option::Option<OwnerControlApplyConfigResponse>,
    #[prost(message, optional, tag = "5")]
    pub refresh_inventory: ::core::option::Option<OwnerControlRefreshInventoryResponse>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlError {
    #[prost(enumeration = "OwnerControlErrorCode", tag = "1")]
    pub code: i32,
    #[prost(string, tag = "2")]
    pub message: ::prost::alloc::string::String,
    #[prost(uint64, optional, tag = "3")]
    pub request_id: ::core::option::Option<u64>,
    #[prost(uint64, optional, tag = "4")]
    pub current_revision: ::core::option::Option<u64>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlGetConfigRequest {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub requester_node_id: ::prost::alloc::vec::Vec<u8>,
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "2")]
    pub target_node_id: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlGetConfigResponse {
    #[prost(message, optional, tag = "1")]
    pub snapshot: ::core::option::Option<OwnerControlConfigSnapshot>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlWatchConfigRequest {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub requester_node_id: ::prost::alloc::vec::Vec<u8>,
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "2")]
    pub target_node_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(bool, tag = "3")]
    pub include_snapshot: bool,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlWatchConfigResponse {
    #[prost(message, optional, tag = "1")]
    pub accepted: ::core::option::Option<OwnerControlWatchAccepted>,
    #[prost(message, optional, tag = "2")]
    pub snapshot: ::core::option::Option<OwnerControlConfigSnapshot>,
    #[prost(message, optional, tag = "3")]
    pub update: ::core::option::Option<OwnerControlConfigUpdate>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlWatchAccepted {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub target_node_id: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlApplyConfigRequest {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub requester_node_id: ::prost::alloc::vec::Vec<u8>,
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "2")]
    pub target_node_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(uint64, tag = "3")]
    pub expected_revision: u64,
    #[prost(message, optional, tag = "4")]
    pub config: ::core::option::Option<NodeConfigSnapshot>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlApplyConfigResponse {
    #[prost(bool, tag = "1")]
    pub success: bool,
    #[prost(uint64, tag = "2")]
    pub current_revision: u64,
    #[prost(bytes = "vec", tag = "3")]
    pub config_hash: ::prost::alloc::vec::Vec<u8>,
    #[prost(string, optional, tag = "4")]
    pub error: ::core::option::Option<::prost::alloc::string::String>,
    #[prost(enumeration = "ConfigApplyMode", tag = "5")]
    pub apply_mode: i32,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlRefreshInventoryRequest {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub requester_node_id: ::prost::alloc::vec::Vec<u8>,
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "2")]
    pub target_node_id: ::prost::alloc::vec::Vec<u8>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlRefreshInventoryResponse {
    #[prost(message, optional, tag = "1")]
    pub snapshot: ::core::option::Option<OwnerControlConfigSnapshot>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlConfigSnapshot {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub node_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(uint64, tag = "2")]
    pub revision: u64,
    /// SHA-256 of canonical proto bytes (32 bytes)
    #[prost(bytes = "vec", tag = "3")]
    pub config_hash: ::prost::alloc::vec::Vec<u8>,
    #[prost(message, optional, tag = "4")]
    pub config: ::core::option::Option<NodeConfigSnapshot>,
    #[prost(string, optional, tag = "5")]
    pub hostname: ::core::option::Option<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct OwnerControlConfigUpdate {
    /// exactly 32 bytes
    #[prost(bytes = "vec", tag = "1")]
    pub node_id: ::prost::alloc::vec::Vec<u8>,
    #[prost(uint64, tag = "2")]
    pub revision: u64,
    /// SHA-256 of canonical proto bytes (32 bytes)
    #[prost(bytes = "vec", tag = "3")]
    pub config_hash: ::prost::alloc::vec::Vec<u8>,
    #[prost(message, optional, tag = "4")]
    pub config: ::core::option::Option<NodeConfigSnapshot>,
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum CapabilityLevel {
    Unspecified = 0,
    None = 1,
    Likely = 2,
    Supported = 3,
}
impl CapabilityLevel {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "CAPABILITY_LEVEL_UNSPECIFIED",
            Self::None => "CAPABILITY_LEVEL_NONE",
            Self::Likely => "CAPABILITY_LEVEL_LIKELY",
            Self::Supported => "CAPABILITY_LEVEL_SUPPORTED",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "CAPABILITY_LEVEL_UNSPECIFIED" => Some(Self::Unspecified),
            "CAPABILITY_LEVEL_NONE" => Some(Self::None),
            "CAPABILITY_LEVEL_LIKELY" => Some(Self::Likely),
            "CAPABILITY_LEVEL_SUPPORTED" => Some(Self::Supported),
            _ => None,
        }
    }
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ModelSourceKind {
    Unspecified = 0,
    Catalog = 1,
    HuggingFace = 2,
    LocalGguf = 3,
    DirectUrl = 4,
    Unknown = 5,
}
impl ModelSourceKind {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "MODEL_SOURCE_KIND_UNSPECIFIED",
            Self::Catalog => "MODEL_SOURCE_KIND_CATALOG",
            Self::HuggingFace => "MODEL_SOURCE_KIND_HUGGING_FACE",
            Self::LocalGguf => "MODEL_SOURCE_KIND_LOCAL_GGUF",
            Self::DirectUrl => "MODEL_SOURCE_KIND_DIRECT_URL",
            Self::Unknown => "MODEL_SOURCE_KIND_UNKNOWN",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "MODEL_SOURCE_KIND_UNSPECIFIED" => Some(Self::Unspecified),
            "MODEL_SOURCE_KIND_CATALOG" => Some(Self::Catalog),
            "MODEL_SOURCE_KIND_HUGGING_FACE" => Some(Self::HuggingFace),
            "MODEL_SOURCE_KIND_LOCAL_GGUF" => Some(Self::LocalGguf),
            "MODEL_SOURCE_KIND_DIRECT_URL" => Some(Self::DirectUrl),
            "MODEL_SOURCE_KIND_UNKNOWN" => Some(Self::Unknown),
            _ => None,
        }
    }
}
/// Shared enum
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum NodeRole {
    Unspecified = 0,
    Worker = 1,
    Host = 2,
    Client = 3,
}
impl NodeRole {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "NODE_ROLE_UNSPECIFIED",
            Self::Worker => "WORKER",
            Self::Host => "HOST",
            Self::Client => "CLIENT",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "NODE_ROLE_UNSPECIFIED" => Some(Self::Unspecified),
            "WORKER" => Some(Self::Worker),
            "HOST" => Some(Self::Host),
            "CLIENT" => Some(Self::Client),
            _ => None,
        }
    }
}
/// Latency source type for peer latency data
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum LatencySource {
    Unspecified = 0,
    Direct = 1,
    Estimated = 2,
    Unknown = 3,
}
impl LatencySource {
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "LATENCY_SOURCE_UNSPECIFIED",
            Self::Direct => "DIRECT",
            Self::Estimated => "ESTIMATED",
            Self::Unknown => "UNKNOWN",
        }
    }
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "LATENCY_SOURCE_UNSPECIFIED" => Some(Self::Unspecified),
            "DIRECT" => Some(Self::Direct),
            "ESTIMATED" => Some(Self::Estimated),
            "UNKNOWN" => Some(Self::Unknown),
            _ => None,
        }
    }
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum GpuAssignment {
    Unspecified = 0,
    Auto = 1,
    Pinned = 2,
}
impl GpuAssignment {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "GPU_ASSIGNMENT_UNSPECIFIED",
            Self::Auto => "GPU_ASSIGNMENT_AUTO",
            Self::Pinned => "GPU_ASSIGNMENT_PINNED",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "GPU_ASSIGNMENT_UNSPECIFIED" => Some(Self::Unspecified),
            "GPU_ASSIGNMENT_AUTO" => Some(Self::Auto),
            "GPU_ASSIGNMENT_PINNED" => Some(Self::Pinned),
            _ => None,
        }
    }
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum ConfigApplyMode {
    Unspecified = 0,
    Staged = 1,
    Live = 2,
    Noop = 3,
}
impl ConfigApplyMode {
    /// String value of the enum field names used in the ProtoBuf definition.
    ///
    /// The values are not transformed in any way and thus are considered stable
    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "CONFIG_APPLY_MODE_UNSPECIFIED",
            Self::Staged => "CONFIG_APPLY_MODE_STAGED",
            Self::Live => "CONFIG_APPLY_MODE_LIVE",
            Self::Noop => "CONFIG_APPLY_MODE_NOOP",
        }
    }
    /// Creates an enum from field names used in the ProtoBuf definition.
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "CONFIG_APPLY_MODE_UNSPECIFIED" => Some(Self::Unspecified),
            "CONFIG_APPLY_MODE_STAGED" => Some(Self::Staged),
            "CONFIG_APPLY_MODE_LIVE" => Some(Self::Live),
            "CONFIG_APPLY_MODE_NOOP" => Some(Self::Noop),
            _ => None,
        }
    }
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
#[repr(i32)]
pub enum OwnerControlErrorCode {
    Unspecified = 0,
    BadRequest = 1,
    Unauthorized = 2,
    RevisionConflict = 3,
    ControlUnsupported = 4,
    ControlEndpointRequired = 5,
    ControlUnavailable = 6,
    UnknownCommand = 7,
    LegacyJsonUnsupported = 8,
    InvalidHandshake = 9,
    TargetNodeMismatch = 10,
}
impl OwnerControlErrorCode {
    pub fn as_str_name(&self) -> &'static str {
        match self {
            Self::Unspecified => "OWNER_CONTROL_ERROR_CODE_UNSPECIFIED",
            Self::BadRequest => "OWNER_CONTROL_ERROR_CODE_BAD_REQUEST",
            Self::Unauthorized => "OWNER_CONTROL_ERROR_CODE_UNAUTHORIZED",
            Self::RevisionConflict => "OWNER_CONTROL_ERROR_CODE_REVISION_CONFLICT",
            Self::ControlUnsupported => "OWNER_CONTROL_ERROR_CODE_CONTROL_UNSUPPORTED",
            Self::ControlEndpointRequired => "OWNER_CONTROL_ERROR_CODE_CONTROL_ENDPOINT_REQUIRED",
            Self::ControlUnavailable => "OWNER_CONTROL_ERROR_CODE_CONTROL_UNAVAILABLE",
            Self::UnknownCommand => "OWNER_CONTROL_ERROR_CODE_UNKNOWN_COMMAND",
            Self::LegacyJsonUnsupported => "OWNER_CONTROL_ERROR_CODE_LEGACY_JSON_UNSUPPORTED",
            Self::InvalidHandshake => "OWNER_CONTROL_ERROR_CODE_INVALID_HANDSHAKE",
            Self::TargetNodeMismatch => "OWNER_CONTROL_ERROR_CODE_TARGET_NODE_MISMATCH",
        }
    }
    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
        match value {
            "OWNER_CONTROL_ERROR_CODE_UNSPECIFIED" => Some(Self::Unspecified),
            "OWNER_CONTROL_ERROR_CODE_BAD_REQUEST" => Some(Self::BadRequest),
            "OWNER_CONTROL_ERROR_CODE_UNAUTHORIZED" => Some(Self::Unauthorized),
            "OWNER_CONTROL_ERROR_CODE_REVISION_CONFLICT" => Some(Self::RevisionConflict),
            "OWNER_CONTROL_ERROR_CODE_CONTROL_UNSUPPORTED" => Some(Self::ControlUnsupported),
            "OWNER_CONTROL_ERROR_CODE_CONTROL_ENDPOINT_REQUIRED" => {
                Some(Self::ControlEndpointRequired)
            }
            "OWNER_CONTROL_ERROR_CODE_CONTROL_UNAVAILABLE" => Some(Self::ControlUnavailable),
            "OWNER_CONTROL_ERROR_CODE_UNKNOWN_COMMAND" => Some(Self::UnknownCommand),
            "OWNER_CONTROL_ERROR_CODE_LEGACY_JSON_UNSUPPORTED" => Some(Self::LegacyJsonUnsupported),
            "OWNER_CONTROL_ERROR_CODE_INVALID_HANDSHAKE" => Some(Self::InvalidHandshake),
            "OWNER_CONTROL_ERROR_CODE_TARGET_NODE_MISMATCH" => Some(Self::TargetNodeMismatch),
            _ => None,
        }
    }
}
