Skip to content

feat(meetings): add summary + summary_state fields to the meeting model - #15

Open
Rahulkaushik01 wants to merge 1 commit into
feat/azure-openai-credentialfrom
feat/meeting-summary-fields
Open

feat(meetings): add summary + summary_state fields to the meeting model#15
Rahulkaushik01 wants to merge 1 commit into
feat/azure-openai-credentialfrom
feat/meeting-summary-fields

Conversation

@Rahulkaushik01

Copy link
Copy Markdown
Collaborator

What & why

Adds storage for an AI-generated meeting title + summary on the shared Bot meeting
record, and exposes it in the member-facing MeetingSerializer. This is the schema slice
of the summaries feature — storage + read exposure only; generation lands in a later
phase. One summary per meeting (shared by all viewers), covering bot meetings and local
recordings alike (same model, split by session_type).

No behaviour change: every meeting starts summary=null, summary_state=pending, and
nothing generates or displays it yet.

Stacked on # (Azure OpenAI credential). Review/merge after it, or retarget to dev.

Changes (per file)

  • bots/models.pySummaryStates TextChoices (pending/generating/done/failed/skipped);
    summary (TextField, null), summary_state (CharField, choices, default pending),
    summary_generated_at (DateTimeField, null) on Bot.
  • bots/meetings_serializers.py — expose summary + summary_state as plain fields. They
    are direct columns on the already-fetched row, so the serializer's no-N+1 property is
    preserved (still guarded by TestMeetingListQueryCount).
  • bots/migrations/0096_bot_summary_bot_summary_generated_at_and_more.py — additive,
    nullable/defaulted, depends on 0095; no backfill.
  • bots/tests/test_meeting_summary_fields.py — 4 tests.

Behaviour / lifecycle

  • Fields are read-only over the API (the serializer is output-only).
  • Deletion: a full meeting delete removes the row (and its summary). Clearing the summary on
    a transcript-only wipe (delete_data) is intentionally deferred to the generation phase,
    where it ships with the code that writes summaries — harmless until then (always null).

Testing

  • makemigrations --check → No changes detected; migration applies + reverses cleanly.
  • python manage.py test bots.tests.test_meeting_summary_fields → 4 passed; meetings-list +
    journey suites → pass (no regression; query-count guard still green).
  • ruff check / ruff format --check → clean.

Notes

  • No new dependencies. No write path opened. summary_state values are named choices (no
    magic strings).

Adds AI title/summary storage on the shared Bot meeting record (one summary per
meeting, visible to every viewer) and exposes it read-only in the member-facing
MeetingSerializer. Schema + read exposure only — generation lands in a later
phase, so every meeting starts null/PENDING and behaviour is unchanged.

- bots/models.py: SummaryStates TextChoices (pending/generating/done/failed/skipped)
  + summary (TextField), summary_state (CharField, default pending),
  summary_generated_at (DateTimeField) on Bot
- bots/meetings_serializers.py: expose summary + summary_state as plain fields
  (direct columns on the already-fetched row — preserves the no-N+1 property)
- bots/migrations/0096_bot_summary_bot_summary_generated_at_and_more.py: additive,
  nullable/defaulted fields, depends on 0095
- bots/tests/test_meeting_summary_fields.py: defaults for bot + local, serializer
  exposes null summary + pending state, populated summary round-trip, and a shared
  (deduped) meeting shows the same summary to every viewer
@Rahulkaushik01
Rahulkaushik01 requested a review from hd1801 August 7, 2026 13:20
@Rahulkaushik01 Rahulkaushik01 self-assigned this Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant