Amélioration contraste mobile, traçabilité des IA et filtrage catalogue
Build and Push Docker Image / build-and-push (push) Successful in 35s

This commit is contained in:
xavier committed 2026-08-23 15:09:57 +02:00
1 parent 3e140d7d6f
commit 9fdb2bd73e
7 files changed
+115 -19

No files matched your search

+14
View File
@@ -0,0 +1,14 @@
import json
import re
def nettoyer_decision_router(raw_text):
try:
clean = re.sub(r'```(?:json)?\s*', '', raw_text)
clean = clean.replace('```', '').strip()
start = clean.find('{')
end = clean.rfind('}') + 1
if start != -1 and end != 0:
return json.loads(clean[start:end])
except Exception:
pass
return {"intention": "Analyse", "fournisseur": "gemini"}