Skip to main content
ai.split, Split a parsed document into named sections using an LLM. Consumes ai.parse output; emits per-section page ranges and text ready for downstream ai.extract via control.parallel_map.

Configuration

Configuration goes inside the step’s with: block.
input
string
required
Template expression resolving to ai.parse output, e.g. ”{{ steps.parse.output }}”
sections
array<object>
required
Named sections to find in the document
rules
string
Optional natural-language rules appended to the system prompt. E.g. “End-of-section markers like Koniec prílohy 2 close the current section.”
provider
string
Provider ID from eigenpal.config.yaml (e.g. “openai-gpt5.4-mini”). Falls back to the tenant default LLM provider when omitted.
windowTokenBudget
integer
Override the per-window token ceiling for this step. Defaults to env SPLIT_WINDOW_TOKEN_BUDGET or 20000. Smaller windows give sharper anchors on contract-style documents (less competing context for the LLM to mis-anchor on); bump to 50k–100k when sections routinely exceed per-window page count.

Output

Sections found in the document, in page order. Absent sections are omitted.