output.base
Base output generator.
Defines the abstract interface for output generators and common data structures (OutputArtifact, AgentResult).
AgentResult Objects
@dataclass
class AgentResult()
The structured result of an agent run, ready for output generation.
final_output
Markdown-formatted final output from the agent.
structured_data
Optional structured data (tables, metrics) for template rendering.
charts
Chart specifications (e.g., echarts options) embedded in the output.
metadata
Additional metadata about the agent run.
OutputArtifact Objects
@dataclass
class OutputArtifact()
A generated output artifact.
type
"pdf", "html", "csv", "notebook"
url
URL or file path where the artifact is stored.
BaseOutputGenerator Objects
class BaseOutputGenerator(ABC)
Abstract base class for output generators.
generate
@abstractmethod
async def generate(agent_result: AgentResult) -> OutputArtifact
Generate output from an agent result.
Parameters
agent_result : AgentResult The structured result from an agent run.
Returns
OutputArtifact The generated artifact with URL/path and metadata.
cleanup
async def cleanup() -> None
Clean up temporary resources.