acon96 / home-llm

A Home Assistant integration & Model to control your smart home using a Local LLM
490 stars 56 forks source link

Bug in recognize_intent #52

Closed markmghali closed 5 months ago

markmghali commented 5 months ago

Ran into an issue with the integration. I had it working and now it's just erroring out. I asked in home assistant voice assist and they said it was the integration

here is the core logs. Let me know what else you need I can provide:

Logger: homeassistant.components.assist_pipeline.pipeline
Source: components/assist_pipeline/pipeline.py:988
Integration: Assist pipeline (documentation, issues)
First occurred: 12:28:16 PM (2 occurrences)
Last logged: 12:35:25 PM
Unexpected error during intent recognition
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/assist_pipeline/pipeline.py", line 988, in recognize_intent
    conversation_result = await conversation.async_converse(
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/conversation/__init__.py", line 467, in async_converse
    result = await agent.async_process(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/llama_conversation/__init__.py", line 266, in async_process
    message = self._generate_system_prompt(raw_prompt)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/llama_conversation/__init__.py", line 451, in _generate_system_prompt
    args = flatten_schema(service.schema)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/llama_conversation/__init__.py", line 190, in flatten_schema
    _flatten(schema)
  File "/config/custom_components/llama_conversation/__init__.py", line 183, in _flatten
    for key, val in current_schema.schema.items():
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: unbound method dict.items() needs an argument

Thank you again

markmghali commented 5 months ago

Looks like this is related to issue #45 I am downloading the develop branch and tryingit now

acon96 commented 5 months ago

Looks like this is related to issue #45 I am downloading the develop branch and tryingit now

Yeah I need to push a new version properly to fix this bug

markmghali commented 5 months ago

closing this as I fixed this issue by using the develop branch