config-loading-precedence

config-loading-precedence is a skill for Claude Code, Codex from kreuzberg-dev/kreuzberg-lts. It costs 3 tokens per session (496 once invoked), scanned A, original, MIT.

A configuration guide for Kreuzberg, a document-extraction tool that reads files and turns their contents into usable text or data. It explains where configuration files are found and which settings take priority when several are provided.

In plain words
What is it for?
Use it when adding configuration, debugging unexpected extraction or server settings, or deciding how Kreuzberg should load `kreuzberg.toml`, `kreuzberg.yaml`, or `kreuzberg.json`.
Why use it?
It removes uncertainty when command-line options, JSON settings, configuration files, environment variables, and defaults conflict.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when adding configuration, debugging unexpected extraction or server settings, or deciding how Kreuzberg should load kreuzberg.toml, kreuzberg.yaml, or kreuzberg.json.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add kreuzberg-dev/kreuzberg-lts --skill config-loading-precedence
Clone the repo
git clone --depth 1 https://github.com/kreuzberg-dev/kreuzberg-lts

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for config-loading-precedence

README.md
[![agentmods](https://agentmods.dev/badge/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence/github.svg)](https://agentmods.dev/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence)
Your own site
<a href="https://agentmods.dev/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence"><img src="https://agentmods.dev/badge/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for config-loading-precedence

Your own site · 80×15
<a href="https://agentmods.dev/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence"><img src="https://agentmods.dev/badge/skills/kreuzberg-dev/kreuzberg-lts/config-loading-precedence.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 496 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00003 $0.00496
Opus 5.5 $0.00001 $0.00198
Sonnet 5.5 $0.00001 $0.00099
Haiku 4.5 $0.00000 $0.00050

Measured 1mo ago against content hash 55eb48589875, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

config-loading-precedence scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.ai-rulez/skills/config-loading-precedence/SKILL.md · 75 lines

What it actually says

priority: high

Configuration Loading & Precedence

CLI Mode Precedence (highest → lowest)

  1. Individual CLI flags (--ocr, --output-format, --chunk)
  2. Inline JSON config (--config-json or --config-json-base64)
  3. Config file (--config path.toml)
  4. Auto-discovered config (kreuzberg.{toml,yaml,json} in cwd/parents)
  5. Default values

Server/MCP Mode Precedence

  1. CLI arguments (--host, --port)
  2. Environment variables (KREUZBERG_HOST, KREUZBERG_PORT)
  3. Config file [server] section
  4. Defaults (127.0.0.1:8000)

Config File Discovery

Searches current directory and parents for kreuzberg.toml, kreuzberg.yaml, or kreuzberg.json. Stops at first match.

Inline JSON Config

Field-level merge (not whole-object replacement):

fn merge_json_into_config(base: &ExtractionConfig, json: Value) -> Result<ExtractionConfig> {
    let mut config_json = serde_json::to_value(base)?;
    // Merge fields from json into config_json
    serde_json::from_value(merged)?
}

Use --config-json-base64 for shell escaping.

Config File Formats

TOML (kreuzberg.toml):

use_cache = true
[ocr]
backend = "tesseract"
language = "eng+deu"
[security_limits]
max_archive_size = 524288000

YAML and JSON follow equivalent structure.

CLI Flag Overrides

In commands.rs: apply_extraction_overrides() applies individual flags on top of merged config.

Critical Rules

  1. CLI flags always win over config file
  2. JSON merge is field-level, not whole-object
  3. Auto-discovery stops at first config file found
  4. --config-json-base64 for shell-safe JSON passing
  5. Server config uses [server] section + extraction config
Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +6 lines 55eb48589875
  2. 3mo ago First seen · 69 lines · 3 tokens per session scan A e68a601a6b02

Subscribe to this mod's changes

config-loading-precedence is a skill published in the GitHub repository kreuzberg-dev/kreuzberg-lts (22 stars, last pushed 1mo ago), licensed MIT. It adds 3 tokens to every session and 496 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

config-loading-precedence compared with skills from other repositories

config-loading-precedence next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
config-loading-precedencekreuzberg-dev/kreuzberg-ltsSkill221mo agoMITA3Claude Code, Codex
doc-readerJansenAnalytics/claudexSkill55mo agoMITB51Claude Code, Codex
paddleocr-doc-parsingPaddlePaddle/PaddleOCRSkill93k2mo agoApache-2.0A140Claude Code, Codex
paddleocr-text-recognitionPaddlePaddle/PaddleOCRSkill93k2mo agoApache-2.0A125Claude Code, Codex
adelanding-ai/ade-cliSkill2.4k1mo agoApache-2.0A65Claude Code, Codex
document-processingericrisco/rsc-harnessSkill6824d agoMITA84Claude Code, Codex
document-processing-expertpersonamanagmentlayer/pclSkill461mo agoApache-2.0A102Claude Code