From 51fbd2c275ea9cb9380ada494ba1787651833ce3 Mon Sep 17 00:00:00 2001 From: Daniel Morrissey Date: Mon, 19 Oct 2026 12:37:09 -0600 Subject: [PATCH 1/3] feat(pysdk): Typed support for SU understanding transcript config api --- assemblyai/__init__.py | 6 ++++ assemblyai/types.py | 66 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 72 insertions(+) diff --git a/assemblyai/__init__.py b/assemblyai/__init__.py index 5bb3963..b765b61 100644 --- a/assemblyai/__init__.py +++ b/assemblyai/__init__.py @@ -74,6 +74,9 @@ SpeechUnderstandingResponse, StatusResult, SummarizationModel, + SummarizationRequest, + SummarizationResponse, + SummarizationSection, SummarizationType, SyncSpeechModel, SyncTranscriptError, @@ -183,6 +186,9 @@ def __getattr__(name: str): "SpeechUnderstandingResponse", "StatusResult", "SummarizationModel", + "SummarizationRequest", + "SummarizationResponse", + "SummarizationSection", "SummarizationType", "SyncSpeechModel", "SyncTranscriber", diff --git a/assemblyai/types.py b/assemblyai/types.py index 92377f6..a83e7e0 100644 --- a/assemblyai/types.py +++ b/assemblyai/types.py @@ -743,6 +743,24 @@ class CustomFormattingRequest(BaseModel): "Custom email format pattern (e.g., 'username@domain.com')" +class SummarizationRequest(BaseModel): + """ + Summarization configuration for speech understanding + """ + + summary_type: Literal["bullets", "paragraph"] + "The format of the summary" + + headline_length: Optional[int] = None + "Target word count for each chapter headline (5-15, default: 10)" + + approximate_chapters: Optional[int] = None + "Approximate number of chapters to split the transcript into" + + effort: Optional[Literal["low", "medium"]] = None + "How much effort to spend on this task (default: 'low')" + + class SpeechUnderstandingFeatureRequests(BaseModel): """ Speech understanding feature requests @@ -757,6 +775,9 @@ class SpeechUnderstandingFeatureRequests(BaseModel): custom_formatting: Optional[CustomFormattingRequest] = None "Custom formatting configuration" + summarization: Optional[SummarizationRequest] = None + "Summarization configuration" + class SpeechUnderstandingRequest(BaseModel): """ @@ -815,6 +836,48 @@ class TranslationResponse(BaseModel): "Status of the translation feature" +class SummarizationSection(BaseModel): + """ + A summarized section of the transcript + """ + + start: int + "Start of the section, in milliseconds" + + end: int + "End of the section, in milliseconds" + + text: Optional[str] = None + "Section summary, when summary_type is 'paragraph'" + + bullets: Optional[List[str]] = None + "Section summary, when summary_type is 'bullets'" + + headline: Optional[str] = None + "Short headline describing the section" + + +class SummarizationResponse(BaseModel): + """ + Summarization response containing the chapter summaries + """ + + status: str + "Status of the summarization feature" + + summary: Optional[List[SummarizationSection]] = None + "Per-section summaries" + + block_summary: Optional[str] = None + "Single summary covering the whole transcript" + + summary_type: Optional[Literal["bullets", "paragraph"]] = None + "The summary type that was used" + + effort: Optional[Literal["low", "medium"]] = None + "The effort level that was used" + + class SpeechUnderstandingFeatureResponses(BaseModel): """ Speech understanding feature responses grouped together @@ -829,6 +892,9 @@ class SpeechUnderstandingFeatureResponses(BaseModel): custom_formatting: Optional[CustomFormattingResponse] = None "Custom formatting results" + summarization: Optional[SummarizationResponse] = None + "Summarization results" + class SpeechUnderstandingResponse(BaseModel): """ From 9067ce07400da99670a5b366cec2077f1ebdbd54 Mon Sep 17 00:00:00 2001 From: Daniel Morrissey Date: Mon, 19 Oct 2026 13:22:00 -0600 Subject: [PATCH 2/3] Bump version --- assemblyai/__version__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assemblyai/__version__.py b/assemblyai/__version__.py index dc79f8f..81162ee 100644 --- a/assemblyai/__version__.py +++ b/assemblyai/__version__.py @@ -1 +1 @@ -__version__ = "1.6.4" +__version__ = "1.6.5" From 7b9dd725829a560dcbf91c2caadee4419a5f1cb6 Mon Sep 17 00:00:00 2001 From: Daniel Morrissey Date: Mon, 19 Oct 2026 13:30:04 -0600 Subject: [PATCH 3/3] Param description update --- assemblyai/types.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assemblyai/types.py b/assemblyai/types.py index a83e7e0..a27768b 100644 --- a/assemblyai/types.py +++ b/assemblyai/types.py @@ -755,7 +755,7 @@ class SummarizationRequest(BaseModel): "Target word count for each chapter headline (5-15, default: 10)" approximate_chapters: Optional[int] = None - "Approximate number of chapters to split the transcript into" + "Override: Approximate number of chapters to split the transcript into" effort: Optional[Literal["low", "medium"]] = None "How much effort to spend on this task (default: 'low')"