Skip to content
ComPDF
DemoFAQ
New Release

Open-Source PDF SDK & AI Document Processing

Get the full self-hosted SDK and AI document processing on GitHub. One-click deploy to quickly build your document workflows.

Layout Analysis

Overview

Layout Analysis detects the layout structure of a PDF page and helps improve output quality for complex pages.

Use enableAiLayout to enable or disable AI layout analysis.

Sample

js
sdk.setDocumentAIModel("/path/to/documentai.model", -1);

const options = {
  enableAiLayout: true
};

const result = sdk.startPDFToWord(inputFilePath, "", outputFilePath, options);