1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
//! # ggen-domain - Domain Logic Layer
//!
//! This crate contains all domain/business logic for ggen, completely separated
//! from CLI concerns. It provides pure business logic functions that can be used
//! by CLI, web APIs, or other interfaces.
//!
//! ## Architecture
//!
//! - **No CLI dependencies**: This crate has ZERO dependencies on clap or clap-noun-verb
//! - **Infrastructure dependencies**: Uses ggen-core, ggen-ai, ggen-marketplace for operations
//! - **Async by default**: Domain functions are async for non-blocking operations
//!
//! ## Module Organization
//!
//! Domain logic is organized by functional area:
//! - `ai` - AI operations (code analysis, generation)
//! - `graph` - Graph operations (RDF loading, SPARQL queries)
//! - `marketplace` - Marketplace operations (search, install, publish)
//! - `template` - Template operations (generate, lint, render)
//! - `project` - Project operations (create, generate, plan)
//! - `hook` - Hook management
//! - `utils` - Utility functions
//! - `rdf` - RDF metadata operations
//! - `audit` - Security auditing
//! - `ci` - CI/CD operations
//! - `shell` - Shell completion generation
// Poka-Yoke: Prevent warnings at compile time - compiler enforces correctness
// AHI (Autonomic Hyper-Intelligence) subsystem
// AHI Type-System Hardening (Phase 1-5)
// Makes governance impossible-to-violate at compile time
// Phase 1: Type-indexed actions (Risk, TickBudget, Mutation)
// Phase 3: Capability-based effects
// Phase 4: Proof-carrying decisions
// Phase 2: MAPE-K typestate + causality // Phase 5: Lock-free snapshots + conflict-free aggregation
// Re-export commonly used types for convenience
pub use ;