This commit is contained in:
2026-07-27 16:42:04 +02:00
parent 45a7704ea6
commit 018b751723
23 changed files with 2327 additions and 635 deletions

View File

@@ -280,7 +280,18 @@ const buildHealthPrompt = (language, plantContext) => {
`- "analysisSummary": 6 to 9 precise sentences in ${getLanguageLabel(language)} describing visible condition, symptom pattern, likely root cause, urgency, confidence limits, and what the owner should monitor next.`,
'- "likelyIssues": 2 to 4 items, sorted by confidence descending. Each item:',
' - "title": concise issue name (e.g. "Overwatering / Root Rot Risk")',
' - "confidence": float 0.050.99 reflecting visual certainty',
// Kalibrierung analog zur Arterkennung (buildScanPrompt). Ohne diese Skala
// war "confidence" eine freie Zahl ohne definierte Bedeutung — die App zeigt
// sie aber als Prozentwert an und die Onboarding-Copy verspricht, dass wir
// Unsicherheit ehrlich ausweisen. Die Skala macht dieses Versprechen einloesbar.
' - "confidence": float 0.050.99 reflecting visual certainty for THIS issue,',
' independent of the other issues (these are NOT probabilities and must NOT sum to 1). Calibrate it:',
' - 0.85-0.99: the visual signs are unambiguous and typical for this issue.',
' - 0.65-0.84: very likely, but one or two confirming signs are not visible in the photo.',
' - 0.40-0.64: plausible, yet other causes fit the same visible signs equally well.',
' - Below 0.40: weak signal; list it only if ruling it out matters for the owner.',
' - Do not inflate confidence to appear decisive. If the photo cannot settle it,',
' a value below 0.65 is the correct and expected answer.',
' - "details": 24 sentence detailed explanation of what you observe visually, what causes it, and what happens if untreated. Be specific — mention leaf color, location, pattern.',
`- "actionsNow": 5 to 8 specific, actionable steps for the next 2448 hours. Each step must be a complete sentence with concrete instructions (e.g. amounts, durations, techniques). Written in ${getLanguageLabel(language)}.`,
`- "plan7Days": 7 to 10 day-by-day or milestone care steps for the coming week. Each step should specify timing and expected outcome. Written in ${getLanguageLabel(language)}.`,