I have set the LLM credentials to use OpenAI, however general knowledge test questions are not being passed to the LLM, I just the an "unable to reach
Could you advise how it is meant to work to push general questions off to the LLM?
Thanks for your interest in Sophia.
I've tested this extensively now, and the LLM fallback is working fine. What's happening is there's an error somewhere such as incorrect model slug / API key or maybe it can't connect to the internet, or something. There's a configuration or permission issue somewhere.
The issue is Sophia isn't relaying the error back to you and instead just says it can't understand your message. This has been fixed and will be included in the upcoming v2.2 upgrade which will hopefully be out later today.
Hope that helps, and let me know if I can be of further assistance.
Warm regards, Matt
I'm on 2.2.0 and not having any luck with LLM fallback.... Here my config: LLM Trigger: ask+AI Provider: Google Model Name: gemini-3.1-flash-lite API Key: XXXXXX
Payload:
{ "license_id": "XXXXX", "mode": "", "messages": [ { "text": "Ask AI how far is the sun from the earth?", "response": "unfortunately, Unknown intent HassError has occurred.", "intents": [ { "intent": "HassError", "text": "it seems there's been a hiccup, HTTP error: 401.", "slots": {}, "device_candidates": [], "response_type": "error", "success": [], "failed": [], "error": "Unknown intent HassError" } ] } ] }Notes:
"mode": ""is empty in the payload — not sure if that's expected or a symptom of the misconfiguration.- The Home Assistant logs also show
homeassistant.helpers.intent.UnknownIntent: Unknown intent HassError— it looks like whatever handles the 401 tries to surface it via a syntheticHassErrorintent that HA's intent system doesn't recognize, so the real error (the 401) gets masked by a second, unrelated error.Any pointers on where the 401 is actually coming from (Sophia's own backend vs. the Google API call)?
Hi, I'm also getting this same error when trying use gemini-2.5-flash as my fallback LLM. Is there any way to enable sophia debug or verbose logging?
Sophia NLU 2.2 fails when using Google Gemini as the LLM fallback.
Config - Provider: Google - Model:
gemini-3.5-flash-lite- HA Core: 2026.9.4 - Sophia NLU: 2.2 - API key/model confirmed working directly viacurlTest
ask ai what is the capital of france?Result ```text intent HassError: error: Unknown intent HassError
The Gemini API key and model have been independently verified to work using a direct curl request to Google's Gemini API.
however, when I send:
ask ai what is the capital of france?
Sophia returns:
intent HassError:
error: Unknown intent HassError
response: error reported: Unknown intent HassError
The Home Assistant integration then logs:
This error originated from a custom integration.
Logger: custom_components.sophia_nlu.conversation Source: custom_components/sophia_nlu/conversation.py:531 Integration: Sophia NLU Engine
Failed to handle intent HassError
Traceback (most recent call last): File "/config/custom_components/sophia_nlu/conversation.py", line 531, in async_handle_standard_intent intent_result = await intent.async_handle( ^^^^^^^^^^^^^^^^^^^^^^^^^^ ... File "/usr/src/homeassistant/homeassistant/helpers/intent.py", line 116, in async_handle raise UnknownIntent(f"Unknown intent {intent_type}")
homeassistant.helpers.intent.UnknownIntent: Unknown intent HassError Assist pipeline trace
The Assist debug trace shows Sophia itself returning the error intent:
intent: engine: conversation.sophia_nlu language: en intent_input: ask ai what time is the FSU game this weekend? device_id: null satellite_id: null prefer_local_intents: false done: true processed_locally: false intent_output: response: speech: plain: speech: "sorry, i encountered an error: Unknown intent HassError" response_type: action_done data: success: [] failed: [] Additional investigation
I inspected conversation.py from Sophia HA integration 2.2.
The main result-processing code obtains the intent name from the Sophia/Wyoming response:
data = result.get("data", {}) intent_info = data.get("intent", {}) intent_name = intent_info.get("name", "")
Later, the standard HA intent path contains:
if ( len(devices) == 0 or "Timer" in intent_name or "List" in intent_name or intent_name in ["HassBroadcast", "HassNevermind"] ): intent_entry = await self.async_handle_standard_intent( intent_name, slots, user_input )
Because an LLM failure is returned as HassError, and there are no resolved devices, HassError is passed to:
intent.async_handle(...)
Home Assistant then correctly rejects it because HassError isn't a registered Home Assistant intent.
There also appears to be special response handling elsewhere that only excludes:
("HassRespond", "HassClarification", "HassNevermind")
and does not include HassError.
I was having issues with this feature also. I just got it to work with the help of OpenCode. I am running HA OS in a vm. I have a couple of LLM's running via llama-swap on another machine that all my agents connect to without issue but Sophia would not using the default
:8000/v1 for Other/OpenAI compatible provider. I had to add /chat/completions to the end because Sophia does not append it to the url like OpenWebUI, OpenCode, or other agents. Using :8000/v1 only returned HTTP error 404.