Skip to content

Configuration

One YAML file, loaded by load_config; every value has a default, and validation rejects an inconsistent file. The reasoning behind each value is in section 2 of the low-level design.

retold.config

Typed configuration loading and validation for Retold.

RetoldConfig dataclass

flags

flags() -> dict[str, Any]

Return the feature and calibration values persisted with each search.

StoreConfig dataclass

EmbeddingConfig dataclass

RerankerConfig dataclass

ranking property

ranking: str

The candidate-ranking configuration in one word: rrf_only or the enabled mode.

RetrievalConfig dataclass

RewriteConfig dataclass

TriggerConfig dataclass

Who calls memory_search. The retrieval pipeline is identical in every mode; only the caller changes.

GateConfig dataclass

AutoGateConfig dataclass

Stricter gate settings used only for a host-issued retrieval request.

DenseFloorConfig dataclass

Per-type cosine floors. Long episodic summaries score lower against short queries than short facts do.

FreshnessConfig dataclass

IngestionConfig dataclass

EquivalenceConfig dataclass

EvidenceConfig dataclass

Minimum evidence length and entailment score required for a direct claim.

PolicyConfig dataclass

SourceRankConfig dataclass

SessionsConfig dataclass

ConfigError

Bases: ValueError

Raised when a Retold configuration is invalid.

load_config

load_config(path: str | Path | None = None) -> RetoldConfig

Load defaults, optionally applying a nested YAML mapping from path.