Goals -System refactored - Platzhaltersystem enhanced (als draft) #53

Merged
Lars merged 86 commits from develop into main 2026-03-31 11:46:48 +02:00
Showing only changes of commit 4f365e9a69 - Show all commits

View File

@ -0,0 +1,64 @@
# Test-Prompt für Phase 0b - Goal-Aware Placeholders
## Schnelltest-Prompt für Calculation Engine
**Zweck:** Validierung der 100+ Phase 0b Placeholders ohne JSON-Formatters
### Test-Prompt (in Admin UI → KI-Prompts erstellen):
```
Du bist ein Fitness-Coach. Analysiere den Fortschritt:
## Gesamtfortschritt
- Goal Progress Score: {{goal_progress_score}}/100
- Body: {{body_progress_score}}/100
- Nutrition: {{nutrition_score}}/100
- Activity: {{activity_score}}/100
- Recovery: {{recovery_score}}/100
## Kategorie-Fortschritte
- Körper: {{focus_cat_körper_progress}}% (Prio: {{focus_cat_körper_weight}}%)
- Ernährung: {{focus_cat_ernährung_progress}}% (Prio: {{focus_cat_ernährung_weight}}%)
- Aktivität: {{focus_cat_aktivität_progress}}% (Prio: {{focus_cat_aktivität_weight}}%)
## Körper-Metriken
- Gewicht 7d: {{weight_7d_median}} kg
- FM Änderung 28d: {{fm_28d_change}} kg
- LBM Änderung 28d: {{lbm_28d_change}} kg
- Rekomposition: {{recomposition_quadrant}}
## Ernährung
- Energiebilanz: {{energy_balance_7d}} kcal/Tag
- Protein g/kg: {{protein_g_per_kg}}
- Protein Adequacy: {{protein_adequacy_28d}}/100
## Aktivität
- Minuten/Woche: {{training_minutes_week}}
- Qualität: {{quality_sessions_pct}}%
- Kraft-Balance: {{ability_balance_strength}}/100
## Recovery
- HRV vs Baseline: {{hrv_vs_baseline_pct}}%
- Schlaf 7d: {{sleep_avg_duration_7d}}h
- Schlafqualität: {{sleep_quality_7d}}/100
Gib 3 konkrete Empfehlungen basierend auf den schwächsten Scores.
```
### Erwartetes Verhalten:
✅ Alle Placeholders lösen auf (numerisch oder "nicht verfügbar")
✅ Keine Python Exceptions
✅ Scores haben Werte 0-100 oder "nicht verfügbar"
### Test-Schritte:
1. Admin → KI-Prompts → "Neu erstellen"
2. Type: "base", Name: "Phase 0b Quick Test"
3. Template einfügen
4. "Test" Button → Profil wählen
5. Debug-Viewer prüfen: "Unresolved Placeholders" sollte leer sein
6. Wenn Errors: Console Log prüfen
### Bekannte Limitierungen (aktuell):
- JSON-Formatters (active_goals_json, etc.) → geben leere Arrays
- Top Goal Name → "nicht verfügbar" (needs goal_utils extension)
- Correlations → Placeholder-Werte (noch nicht echte Berechnungen)