All checks were successful
Deploy Development / deploy (push) Successful in 44s
Test Suite / pytest-backend (push) Successful in 1m19s
Test Suite / lint-backend (push) Successful in 2s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 18s
Test Suite / playwright-smoke (push) Successful in 11s
Persistierter Standard Lifecycle pro Initiative, backend/steering/ Skeleton, Attention-Refactor und Hook-Dispatch als Basis für Method Registry. Co-authored-by: Cursor <cursoragent@cursor.com>
43 lines
1.0 KiB
Python
43 lines
1.0 KiB
Python
"""Standard Lifecycle — gemeinsame Basis (AP1.0)."""
|
|
|
|
from __future__ import annotations
|
|
|
|
STANDARD_LIFECYCLE_STEPS: tuple[str, ...] = (
|
|
"intake",
|
|
"method_selection",
|
|
"structure_setup",
|
|
"planning",
|
|
"action_selection",
|
|
"assignment",
|
|
"waiting",
|
|
"result_intake",
|
|
"validation",
|
|
"review",
|
|
"adaptation",
|
|
"closure",
|
|
)
|
|
|
|
LIFECYCLE_LABELS: dict[str, str] = {
|
|
"intake": "Aufnahme",
|
|
"method_selection": "Methode wählen",
|
|
"structure_setup": "Struktur aufbauen",
|
|
"planning": "Planung",
|
|
"action_selection": "Maßnahmen auswählen",
|
|
"assignment": "Zuweisen",
|
|
"waiting": "Warten",
|
|
"result_intake": "Ergebnis aufnehmen",
|
|
"validation": "Validierung",
|
|
"review": "Review",
|
|
"adaptation": "Anpassung",
|
|
"closure": "Abschluss",
|
|
}
|
|
|
|
|
|
def lifecycle_label(state: str) -> str:
|
|
return LIFECYCLE_LABELS.get(state, state)
|
|
|
|
|
|
def validate_lifecycle_state(state: str) -> None:
|
|
if state not in STANDARD_LIFECYCLE_STEPS:
|
|
raise ValueError(f"Ungültiger Lifecycle-State: {state}")
|