Expand description
Typed project configuration shared by Harn’s CLI and language tooling.
harn.toml can carry many sections. This loader exposes the generic
[fmt], [lint], and [eval.fleets] policy used by every frontend and
walks up from an input file looking for the nearest manifest.
Recognized keys (snake_case, Cargo-style):
[fmt]
line_width = 100
# By default, section-header separators follow line_width.
# Set separator_width to force a fixed width.
[lint]
disabled = ["unused-import"]
require_file_header = false
require_docstrings = false
require_public_api_types = false
complexity_threshold = 25
persona_step_allowlist = ["legacy_helper"]
template_variant_branch_threshold = 3
# Reusable fleets consumed by `harn eval prompt --fleet-name <name>`.
[eval.fleets.frontier]
models = ["claude-opus-4-7", "gpt-5", "gemini-2.5-pro"]
[eval.fleets.local]
models = ["ollama:qwen3.5", "ollama:llama4"]Structs§
- Eval
Config [eval]section ofharn.toml. Reserves a[eval.fleets.<name>]table keyed by fleet name; each entry lists the model selectors (alias orprovider:model) consumed byharn eval prompt --fleet-name <name>.- Eval
Fleet - FmtConfig
- Harn
Config - Generic
harn.tomlview shared by the CLI, LSP, and future frontends. - Lint
Config
Enums§
- Config
Error - Lint
Severity - Canonical severity used by project lint configuration and lint diagnostics.
Functions§
- load_
for_ path - Walks up from
startto find the nearestharn.tomlvia the sharedmanifest_walkwalk. ReturnsOk(HarnConfig::default())if none is found. ReturnsErron parse failure so callers can surface the problem rather than silently ignore malformed config.