summarize

suspend fun summarize(pages: IntRange? = null, style: PdfSummaryStyle = PdfSummaryStyle.PARAGRAPH, language: String? = null): PdfAiOutcome<PdfSummary>

Call while the app is in the foreground. AICore blocks on-device inference from the background, and the result is then PdfAiUnavailableReason.BACKGROUND_USE_BLOCKED unless a custom provider answers instead.