Skip to content

ollama_summarize_deep

Summarize (deep). Digest of long input with optional focus. Pass EXACTLY ONE of: text (raw content in hand), source_path (single file — server reads + chunks, Claude never pre-reads), or source_paths[] (multiple files). The path-based shapes save Claude context — the whole point of delegating summarization. Carries source_preview for fabrication spot-checks. FRAME CONTRACT (optional): pass frame (the question / section purpose this digest is FOR — distinct from focus, which is emphasis WITHIN an in-frame source). Sources that don’t address the frame are dropped from the digest and listed under unaddressed_sources; if NO source addresses it, summary=‘’ and frame_addressed: false. Omitting frame preserves the legacy result shape.

Parameter Type Required Default Description
text string no Raw text to digest. Use this when you already have the content in hand.
source_path string no A single file path to read + chunk server-side. Shortcut for source_paths: [one] — use whichever reads more naturally. Closes adoption SEAM #2 (large single-file summaries no longer force Claude to pre-read the file).
source_paths any no File paths to read + chunk server-side. Use this instead of text to save Claude context — the tool reads the files, Claude never sees the raw content.
focus string no Optional aspect to emphasize (e.g. ‘combat doctrine’, ‘auth flow’).
frame string no The question / section purpose / topic this digest is FOR — distinct from focus, which is emphasis within an in-frame source. When supplied, sources that don’t address the frame are dropped from the digest and listed under unaddressed_sources instead. If NO source addresses the frame, summary is empty.
max_words integer no Target digest length in words (default 250).
per_file_max_chars integer no Chars to read per file when source_paths is used (default 40k).
model string no Optional per-call model override. When provided, overrides the tool’s tier-resolved model for this call. The tier’s timeout (TIER_TIMEOUT_MS) still applies. On timeout, fallback uses the tier-resolved model, NOT the override. Use for receipt-backed orchestration that requires explicit model identity (e.g., research-os reviewer profiles).

The JSON Schema below is generated from the same zod schema the server validates against at the wire — it cannot drift from runtime behavior.

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"text": {
"description": "Raw text to digest. Use this when you already have the content in hand.",
"type": "string",
"minLength": 1
},
"source_path": {
"description": "A single file path to read + chunk server-side. Shortcut for `source_paths: [one]` — use whichever reads more naturally. Closes adoption SEAM #2 (large single-file summaries no longer force Claude to pre-read the file).",
"type": "string",
"minLength": 1
},
"source_paths": {
"description": "File paths to read + chunk server-side. Use this instead of `text` to save Claude context — the tool reads the files, Claude never sees the raw content."
},
"focus": {
"description": "Optional aspect to emphasize (e.g. 'combat doctrine', 'auth flow').",
"type": "string"
},
"frame": {
"description": "The question / section purpose / topic this digest is FOR — distinct from `focus`, which is emphasis within an in-frame source. When supplied, sources that don't address the frame are dropped from the digest and listed under `unaddressed_sources` instead. If NO source addresses the frame, summary is empty.",
"type": "string"
},
"max_words": {
"description": "Target digest length in words (default 250).",
"type": "integer",
"minimum": 20,
"maximum": 1500
},
"per_file_max_chars": {
"description": "Chars to read per file when source_paths is used (default 40k).",
"type": "integer",
"minimum": 1000,
"maximum": 200000
},
"model": {
"description": "Optional per-call model override. When provided, overrides the tool's tier-resolved model for this call. The tier's timeout (TIER_TIMEOUT_MS) still applies. On timeout, fallback uses the tier-resolved model, NOT the override. Use for receipt-backed orchestration that requires explicit model identity (e.g., research-os reviewer profiles).",
"type": "string",
"minLength": 1
}
}
}

Every tool returns the standard envelope — tier_used, model, tokens_in/tokens_out, elapsed_ms, backend provenance, warnings. See Envelope & tiers.

Schema + handler: src/tools/summarizeDeep.ts · registration: src/index.ts


Back to the Tool Reference.