Public Member Functions | |
| None | __init__ (self, int capacity) |
| None | clear (self) |
| IntentCacheValue|None | get (self, IntentCacheKey key) |
| None | put (self, IntentCacheKey key, IntentCacheValue value) |
Public Attributes | |
| capacity | |
LRU cache for intent recognition results.
Definition at line 152 of file default_agent.py.
| None homeassistant.components.conversation.default_agent.IntentCache.__init__ | ( | self, | |
| int | capacity | ||
| ) |
Initialize cache.
Definition at line 155 of file default_agent.py.
| None homeassistant.components.conversation.default_agent.IntentCache.clear | ( | self | ) |
Clear the cache.
Definition at line 180 of file default_agent.py.
| IntentCacheValue | None homeassistant.components.conversation.default_agent.IntentCache.get | ( | self, | |
| IntentCacheKey | key | ||
| ) |
Get value for cache or None.
Definition at line 160 of file default_agent.py.
| None homeassistant.components.conversation.default_agent.IntentCache.put | ( | self, | |
| IntentCacheKey | key, | ||
| IntentCacheValue | value | ||
| ) |
Put a value in the cache, evicting the least recently used item if necessary.
Definition at line 169 of file default_agent.py.
| homeassistant.components.conversation.default_agent.IntentCache.capacity |
Definition at line 158 of file default_agent.py.