Package com.tnsai.tools.document.docling
Class DoclingTools
java.lang.Object
com.tnsai.tools.document.docling.DoclingTools
Function-shape toolkit for advanced document conversion through Docling.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilder for explicitly configured Docling toolkits. -
Field Summary
FieldsModifier and TypeFieldDescriptionFormats admitted by the Docling document converter. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a safe unavailable toolkit; configure MCP or CLI explicitly to enable parsing.DoclingTools(DoclingProvider provider) DoclingTools(DoclingProvider provider, FileGuardConfig guardConfig) -
Method Summary
Modifier and TypeMethodDescriptionstatic DoclingTools.Builderbuilder()doclingParse(String path) booleanReturns whether the configured MCP or subprocess provider is available.Parses a local file and returns Docling's structured output.
-
Field Details
-
DEFAULT_EXTENSIONS
Formats admitted by the Docling document converter.
-
-
Constructor Details
-
DoclingTools
public DoclingTools()Creates a safe unavailable toolkit; configure MCP or CLI explicitly to enable parsing. -
DoclingTools
-
DoclingTools
-
-
Method Details
-
builder
-
isAvailable
public boolean isAvailable()Returns whether the configured MCP or subprocess provider is available. -
parse
Parses a local file and returns Docling's structured output.- Throws:
IOException
-
doclingParse
@Tool(name="docling_parse", description="Parse a local document with Docling and return bounded Markdown. Use the direct Java parse(Path) API when tables, formulas, figures, or lossless Docling JSON are needed.", keywords={"docling","document","pdf","table","formula","ocr","parse"}, idempotent=true) public String doclingParse(@ToolParam(description="Local document path under the configured file sandbox") String path) throws IOException - Throws:
IOException
-