Skip to main content

Crate loopsmith_core

Crate loopsmith_core 

Source
Expand description

Config model and validation for loopsmith.

A loop config is the A–H model from the template:

  • A information — static context handed to every node
  • B pre_execution — the “do it manually first” work list
  • C goals — named objectives in natural language
  • D validations — how a goal is checked, per goal or overall
  • E success — what counts as success, per goal or overall
  • F stop_gates — the four layered exits
  • G schedules — time or event triggers
  • H constraints — limits applied per node or globally

Validation exists to make the corpus rule enforceable: a goal without a machine-checkable validation is the single most common way loops fail, so the config is rejected rather than run.

Re-exports§

pub use md::parse_md;
pub use md::render_md;
pub use validate::validate;
pub use validate::Issue;
pub use validate::Severity;
pub use validate::ValidationReport;
pub use config::*;

Modules§

config
The A–H config model, one module per section.
md
Markdown-native config: the same A–J model, written as a document.
validate
A–J validation.

Enums§

CoreError

Functions§

is_markdown
Whether a path should be read as a markdown config.
load
Load a config from Markdown, YAML, or JSON.
load_validated
Load and validate in one step, treating any error-severity issue as fatal.
parse_str
Parse config text, trying YAML first (a superset of JSON in practice) and falling back to strict JSON so both error messages survive to the caller.