team_config.py 679 B

123456789101112131415
  1. from core_db import AuditMixin, Base, EntityMixin
  2. from core_shared import JSONValue
  3. from sqlalchemy import String, Text
  4. from sqlalchemy import JSON
  5. from sqlalchemy.orm import Mapped, mapped_column
  6. class TeamConfig(EntityMixin, AuditMixin, Base):
  7. __tablename__ = "team_config"
  8. team_id: Mapped[str] = mapped_column(String(36), index=True)
  9. coordination_mode: Mapped[str] = mapped_column(String(64), default="supervisor")
  10. objective: Mapped[str | None] = mapped_column(Text, nullable=True)
  11. member_refs_json: Mapped[list[dict[str, JSONValue]]] = mapped_column(JSON, default=list)
  12. policy_json: Mapped[dict[str, JSONValue]] = mapped_column(JSON, default=dict)