"""用量记录 + Kafka 事件发布 + 配额管理（02-architecture-design.md §7, §11）.

模块：
  - UsageRecorder: Redis 记录 token 用量（按 user/school/month 维度）
  - KafkaProducer: 发布 AIUsageEvent 到 edu.ai.usage topic（派生数据豁免 Outbox）
  - QuotaEnforcer: 月度 token 预算校验，超限抛 AIQuotaExceededError

全并行模式：Redis/Kafka 不可用时降级（记录警告，不阻断主流程）。
"""

from .kafka_producer import KafkaProducer, UsageEvent
from .quota_enforcer import QuotaEnforcer, QuotaStatus
from .usage_recorder import UsageRecord, UsageRecorder

__all__ = [
    "KafkaProducer",
    "UsageEvent",
    "QuotaEnforcer",
    "QuotaStatus",
    "UsageRecorder",
    "UsageRecord",
]
