hass-core/homeassistant/components/conversation/agent.py
Marc Mueller 9b9b553521
Disable no-self-use [pylint] (#70641)
* Disable no-self-use

* Remove disable comments
2022-04-25 07:41:01 -07:00

30 lines
776 B
Python

"""Agent foundation for conversation integration."""
from __future__ import annotations
from abc import ABC, abstractmethod
from homeassistant.core import Context
from homeassistant.helpers import intent
class AbstractConversationAgent(ABC):
"""Abstract conversation agent."""
@property
def attribution(self):
"""Return the attribution."""
return None
async def async_get_onboarding(self):
"""Get onboard data."""
return None
async def async_set_onboarding(self, shown):
"""Set onboard data."""
return True
@abstractmethod
async def async_process(
self, text: str, context: Context, conversation_id: str | None = None
) -> intent.IntentResponse:
"""Process a sentence."""