Skip to content

_yaml

_yaml

Minimal YAML loader — vendored from terok.lib.util.yaml.

Only the load function is needed by terok-agent (for frontmatter parsing and config stack loading). Round-trip dump is not required here.

load(text)

Round-trip load from a YAML string, preserving comments and order.

Source code in src/terok_agent/_util/_yaml.py
def load(text: str) -> Any:
    """Round-trip load from a YAML string, preserving comments and order."""
    return _yaml.load(text)