Summarizer Agent
The Summarizer Agent is a core utility designed to digest long-form text, conversations, documents, and transcripts into concise, readable summaries. It supports taking detailed bulleted notes, extracting action items, and providing high-level executive summaries.
Features
- Long-Form Text Support: Handles large contexts by chunking text and using progressive summarizing strategies.
- Structured Note Generation: Automatically extracts key takeaways, dates, people, and topics in Markdown format.
- Integrated Memory Summarizer: Feeds directly into ChatBot sessions to summarize historical conversational threads, ensuring context limits are not exceeded.
SDK Integration
You can initialize and call the Summarizer class directly in your code.
Python Code Example
from aih import Summarizer
# Initialize the Summarizer with your API Key
summarizer = Summarizer(api_key="your_aih_api_key")
# The text content to process
long_text = """
The board of directors met on July 31st, 2026. The Q2 financial revenue rose by 14%
year-over-year. The main product feature for the AIH Platform, namely VideoBot and
YouTubeBot integrations, has launched successfully, with auto-scaling tests scoring
high reliability parameters up to 1 million requests.
"""
# 1. Generate an Executive Summary
executive_summary = summarizer.summarize(long_text)
print("Summary:\n", executive_summary)
# 2. Extract bulleted study/meeting notes
meeting_notes = summarizer.generate_notes(long_text)
print("Meeting Notes:\n", meeting_notes)Parameters & Specifications
The summarize function supports customizing the length and output style:
| Parameter | Type | Default | Description |
|---|---|---|---|
max_words | number | 150 | Target word count constraint for the output summary. |
format_style | string | "paragraph" | Output format: "paragraph", "bullets", or "structured". |
temperature | number | 0.0 | Randomness level. Recommended to keep at 0.0 for high factual accuracy. |