Update ai_engine.py
robust JSON extraction safe fallback responses guaranteed keys exist no Streamlit crash from AI layer handles messy Gemini outputs
robust JSON extraction safe fallback responses guaranteed keys exist no Streamlit crash from AI layer handles messy Gemini outputs