feat(bridge): exakte Peilung (Grad) zusätzlich zur Himmelsrichtung im Präfix

Neben "nordwestwaerts" jetzt auch die genaue Bearing-Gradzahl (0-359) —
"unterwegs nordwestwaerts (304 Grad)". Die KI nutzt, was die Frage braucht
(Pannenhilfe → Ort/km, Luftfahrt/Navigation → exakte Peilung).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-07-11 22:12:38 +02:00
co-authored by Claude Opus 4.8
parent ddb1bfac6a
commit 44982a9b3c
+10 -3
View File
@@ -1220,8 +1220,9 @@ class ARIABridge:
if anchor:
moved = _haversine_m(anchor["lat"], anchor["lon"], lat, lon)
if moved >= MIN_MOVE_M:
self._last_heading = _heading_word(
_bearing_deg(anchor["lat"], anchor["lon"], lat, lon))
_bg = _bearing_deg(anchor["lat"], anchor["lon"], lat, lon)
self._last_heading = _heading_word(_bg)
self._last_bearing = int(round(_bg)) % 360 # exakte Peilung
self._heading_anchor = {"lat": lat, "lon": lon}
else:
self._heading_anchor = {"lat": lat, "lon": lon}
@@ -1748,7 +1749,13 @@ class ARIABridge:
place = getattr(self, "_last_place_name", "")
where = f"{place} " if place else ""
heading = getattr(self, "_last_heading", "")
moving = f", unterwegs {heading}" if heading else ""
bearing = getattr(self, "_last_bearing", None)
if heading and bearing is not None:
moving = f", unterwegs {heading} ({bearing} Grad)"
elif heading:
moving = f", unterwegs {heading}"
else:
moving = ""
parts.append(
f"[Stefans aktueller Standort: {where}(GPS {float(lat):.5f}, "
f"{float(lon):.5f}){moving}. Nutze das nur wenn die Frage sich "