blakeblackshear.frigate/frigate/comms/review_updater.py
Nicolas Mowen e9e3c481b2 Implement start for review item description processor (#19352)
* Add review item data transmission

* Publish review updates

* Add review item subscriber

* Basic implementation for testing review processor

* Formatting
2025-08-16 10:20:33 -05:00

31 lines
721 B
Python

"""Facilitates communication between processes."""
import logging
from .zmq_proxy import Publisher, Subscriber
logger = logging.getLogger(__name__)
class ReviewDataPublisher(
Publisher
): # update when typing improvement is added Publisher[tuple[str, float]]
"""Publishes review item data."""
topic_base = "review/"
def __init__(self, topic: str) -> None:
super().__init__(topic)
def publish(self, payload: tuple[str, float], sub_topic: str = "") -> None:
super().publish(payload, sub_topic)
class ReviewDataSubscriber(Subscriber):
"""Receives review item data."""
topic_base = "review/"
def __init__(self, topic: str) -> None:
super().__init__(topic)