Aggregated token usage and function calling metrics by operation type.
Maps each event type within the phase to its complete aggregate metrics, including detailed token consumption breakdown with cache statistics and comprehensive function calling metrics data. This comprehensive aggregation enables deep analysis of resource utilization patterns and operation quality across the entire phase.
The partial record structure reflects that not all possible event types may occur during phase execution. Only operations that were actually performed will have entries in this mapping.
The aggregate data supports cost analysis (via token usage), reliability assessment (via function calling metrics), and optimization opportunities (via cache hit rates and failure patterns).
Results of compiling the generated Prisma schema files.
Contains the IAutoBePrismaCompileResult from processing the generated schemas through the Prisma compiler. This should always indicate successful compilation since the schemas are generated from pre-validated AST structures. The compilation results include documentation, diagrams, and dependency files ready for deployment.
Successful compilation confirms that the generated schemas will work correctly in the target database environment and integrate properly with the broader development ecosystem.
Timestamp when the event was created.
ISO 8601 formatted date-time string indicating when this event was emitted by the system. This timestamp is crucial for event ordering, performance analysis, and debugging the agent workflow execution timeline.
Format: "YYYY-MM-DDTHH:mm:ss.sssZ" (e.g., "2024-01-15T14:30:45.123Z")
Total elapsed time for the phase execution in milliseconds.
Measures the wall-clock duration from phase start to completion, encompassing all agent operations, self-healing spiral loops, compiler validations, and any retry attempts. This metric provides visibility into phase-level performance and enables identification of bottlenecks in the waterfall pipeline.
The elapsed time includes both active LLM processing and any overhead from compilation, validation, and orchestration logic. For detailed breakdown of time spent in specific operations, consult the individual operation events within the phase.
A unique identifier for the event.
The validated AST application structure containing the complete database design.
Contains the finalized AutoBePrisma.IApplication structure that represents the complete database architecture as validated AST data. This application includes all models, relationships, constraints, and business rules that have passed through the comprehensive validation process including relationship graph analysis, business logic validation, and performance optimization.
The application structure serves as the authoritative source of database design that has been verified for semantic correctness and business alignment before code generation.
Generated Prisma schema files as key-value pairs.
Contains the production-ready schema files generated through deterministic
code generation from the validated AST structure. Each key represents the
filename (following the pattern schema-{number}-{domain}.prisma) and each
value contains the actual Prisma schema content organized by business
domains.
The schemas include comprehensive documentation, optimal indexes, proper constraints, and all optimizations derived from the AST analysis, ready for immediate deployment to the target database environment.
Final state machine step counter value for the phase.
Records the terminal step number from the phase's state machine, which increments monotonically during execution and invalidates cached state when operations need to be redone. This step counter enables the frontend to detect when previously completed operations have been invalidated by spiral loop corrections, ensuring UI consistency with the actual generation state.
The step value provides a temporal marker for the phase completion, allowing correlation with intermediate operation events that share the same step number.
Unique identifier for the event type.
A literal string that discriminates between different event types in the AutoBE system. This field enables TypeScript's discriminated union feature, allowing type-safe event handling through switch statements or conditional checks.
Examples: "analyzeWrite", "prismaSchema", "interfaceOperation", "testScenario"
Event fired when the Prisma agent completes the database design process and successfully generates validated schema files.
This event represents the successful completion of the sophisticated three-tier compiler infrastructure that transforms business requirements into validated database architectures. The completion marks the transition from requirements analysis to a concrete database implementation that maintains perfect semantic integrity and syntactic correctness.
The Prisma agent's completion ensures that the database design accurately reflects business needs while providing the foundation for subsequent API development and application implementation phases.
Author
Samchon