vibe.structures¶
Core data structures for templates, components, and validation.
ValueSource ¶
Tracks the origin of a value in the interview data structure.
This enum is used to distinguish between different sources of data, which affects how values are treated during probing, validation, and component rendering.
ComponentType ¶
External classification of component structure.
Derived from ComponentOrganization via the component_type property. Used primarily for backwards compatibility and external APIs.
ComponentOrganization ¶
How a component is physically organized in the filesystem.
ComponentLevel ¶
Component configuration sophistication level.
Determines what features and validations apply to a component.
ProcessingPhase ¶
Template processing phase.
Distinguishes between probing (dependency tracking) and rendering (final output generation) phases of template execution.
ValidationIssue ¶
Represents a validation issue discovered during template processing.
GroupConfig ¶
Configuration for a single group in grouped interview/review mode.
Each group organizes related items (questions or requirements) together and has its own title and optional description shown in the UI.
For Interview module: groups contain questions (nested inside 'questions:') For Review module: groups contain requirements (nested inside 'requirements:')
TemplateData ¶
Template bundle metadata, compiled assets, and validation outputs.
get_component_by_alias ¶
get_component_by_alias(alias: str) -> Optional[ComponentTemplateData]
Get component by its alias (defined in template's components section).
This performs a two-step lookup: 1. Resolve alias to component_id via component_aliases dict 2. Retrieve ComponentTemplateData from loaded_components_map
Returns None if the alias is undefined or component failed to load.
get_valid_component ¶
get_valid_component(alias: str) -> Optional[ComponentTemplateData]
Get component by alias only if it's valid.
Returns None if the alias doesn't exist, component isn't loaded, or component validation_status is not 'valid'.
has_valid_component ¶
has_valid_component(alias: str) -> bool
Check if a valid component exists for the given alias.
add_validation_issue ¶
add_validation_issue(issue: ValidationIssue) -> None
Add a validation issue and immediately update validation status.
This ensures validation_status stays synchronized with validation_issues.
extend_validation_issues ¶
extend_validation_issues(issues: list[ValidationIssue]) -> None
Add multiple validation issues and update validation status once.
ComponentTemplateData ¶
Template metadata and configuration for a single component.
component_type ¶
component_type: ComponentType
Return external ComponentType derived from organization.
| Raises: |
|
|---|
ConditionContext ¶
Represents a single level of conditional context (If, For).
UsageInfo ¶
Represents a single usage point of a variable.
ComponentInstanceArgs ¶
Captured arguments for a component instance within a template.