tessl install tessl/pypi-azure-ai-documentintelligence@1.0.0Azure AI Document Intelligence client library for Python - a cloud service that uses machine learning to analyze text and structured data from documents
Agent Success
Agent success rate when using this tile
76%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.19x
Baseline
Agent success rate without this tile
64%
Utility for downloading stored document analysis outputs as searchable PDFs and figure images, with optional cleanup of the stored result.
<output_dir>/<result_id>.pdf, returning the saved path in the result object. @test<output_dir>/<result_id>_figure_<index>.<image_format>, returning all saved paths in order. @testdelete_after is true, deletes the stored analysis result after all downloads succeed and reports whether deletion occurred. @test@generates
from dataclasses import dataclass
from typing import Iterable, List, Optional
@dataclass
class ExportResult:
pdf_path: Optional[str]
figure_paths: List[str]
deleted: bool
def export_analysis_assets(
client,
result_id: str,
output_dir: str,
include_pdf: bool = True,
figure_indexes: Optional[Iterable[int]] = None,
delete_after: bool = False,
image_format: str = "png",
overwrite: bool = False,
) -> ExportResult:
"""Downloads analysis outputs (searchable PDF and figure images) for a stored result ID and optionally deletes the stored result."""Provides retrieval of stored analysis results as searchable PDFs or figure images and deletion of stored results.