Hassassistant / openai_response

Custom component to integrate OpenAI's ChatGPT into Home Assistant
76 stars 15 forks source link

Multiple enhancements #6

Closed Olen closed 1 year ago

Olen commented 1 year ago

Also includes some code cleanup and docstrings etc. to keep VSCode from complaining too much.

Olen commented 1 year ago

There is a problem somewhere.
I get a bunch of these

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/decorators.py", line 26, in _handle_async_response
    await func(hass, connection, msg)
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 351, in handle_get_services
    descriptions = await async_get_all_descriptions(hass)
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 603, in async_get_all_descriptions
    domain_yaml = loaded[domain]
KeyError: 'wake_on_lan'

Need to investigate

Olen commented 1 year ago

Found the bug. DOMAIN needs to be the same as the integration name.

NOW it seems to be working fine

Hassassistant commented 1 year ago

awesome work Olen. I would love to spend time tweaking and testing this but I have had no time since first releasing this. Appreciate your work and effort greatly.

Jokod commented 10 months ago

Since OpenAI has removed the 'text-davinci-003' model, it becomes essential to address the change in using the 'gpt-3.5-turbo' model.

Without this, the plugin does not work without having to tinker with the sensor.py.

Thank you.