ollama_repo_pack
Repo pack (writes artifact). PACK. Runs the full repo ONBOARDING job: corpus_search (if corpus given) → repo_brief → targeted ollama_extract (narrow onboarding schema: packages, entrypoints, scripts, config_files, exposed_surfaces, runtime_hints) → deterministic markdown+JSON artifact on disk. Corpus-first posture: when a corpus is given, it’s the main working surface alongside source_paths. Not repo Q&A — this is get me onboarded fast with a stable operator artifact. Response is compact; full brief + extracted facts live in the artifact.
Parameters
Section titled “Parameters”| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
source_paths |
string[] | yes | — | Files the onboarding brief should read (README, key src entries, package/manifest, docs). Required — these are the repo’s concrete source-of-truth. |
corpus |
string | no | — | Optional named corpus (e.g. ‘handbook’, ‘doctrine’) for cross-cutting architecture context. When given, queried as the pack’s main working surface alongside source_paths. |
corpus_query |
string | no | — | Corpus query (defaults to ‘repo architecture and surfaces’). |
title |
string | no | — | Short human title — used in the artifact header and filename slug. Defaults to the repo thesis head. |
artifact_dir |
string | no | — | Directory to write the repo.md + repo.json artifact pair. Defaults to ~/.ollama-intern/artifacts/repo/. |
per_file_max_chars |
integer | no | — | |
max_key_surfaces |
integer | no | — | |
max_risk_areas |
integer | no | — | |
max_read_next |
integer | no | — |
Full input schema
Section titled “Full input schema”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": { "source_paths": { "minItems": 1, "type": "array", "items": { "type": "string", "minLength": 1 }, "description": "Files the onboarding brief should read (README, key src entries, package/manifest, docs). Required — these are the repo's concrete source-of-truth." }, "corpus": { "description": "Optional named corpus (e.g. 'handbook', 'doctrine') for cross-cutting architecture context. When given, queried as the pack's main working surface alongside source_paths.", "type": "string", "pattern": "^[a-zA-Z0-9_-]+$" }, "corpus_query": { "description": "Corpus query (defaults to 'repo architecture and surfaces').", "type": "string", "minLength": 1 }, "title": { "description": "Short human title — used in the artifact header and filename slug. Defaults to the repo thesis head.", "type": "string", "minLength": 1, "maxLength": 120 }, "artifact_dir": { "description": "Directory to write the repo.md + repo.json artifact pair. Defaults to ~/.ollama-intern/artifacts/repo/.", "type": "string", "minLength": 1 }, "per_file_max_chars": { "type": "integer", "minimum": 1000, "maximum": 200000 }, "max_key_surfaces": { "type": "integer", "minimum": 1, "maximum": 20 }, "max_risk_areas": { "type": "integer", "minimum": 1, "maximum": 10 }, "max_read_next": { "type": "integer", "minimum": 1, "maximum": 15 } }, "required": [ "source_paths" ]}Envelope
Section titled “Envelope”Every tool returns the standard envelope — tier_used, model, tokens_in/tokens_out, elapsed_ms, backend provenance, warnings. See Envelope & tiers.
Source
Section titled “Source”Schema + handler: src/tools/packs/repoPack.ts · registration: src/index.ts
Back to the Tool Reference.