Events
Async event bus для pub/sub паттерна.
Установка
uv pip install viai-kit-core-events
Использование
from viai_kit.core.events import EventBus
bus = EventBus()
@bus.on("user.created")
async def handle_user_created(data):
print(f"User created: {data}")
await bus.emit("user.created", {"id": 123, "name": "John"})