Skip to content

Python API

Generated from the docstrings at build time, one page per module. The names most programs need are importable from schemacast itself:

Name What it is
SchemaCaster, CastResult, EpisodeResult the pipeline over many episodes, and what it returns (cast)
Episode, read_episodes the input (episode)
load_schema a graflo schema or manifest from YAML or JSON (schema_io)
save_cast a cast on disk (output)
write_cast, load_connection, WriteReport (graflo's ContainerWriteReport) resolving against a database and writing through graflo's write_record_graphs (write)
Grounding, TextSpan, UnmappedText where an assertion was read, and what no type covers (ground)
JsonlQuarantineSink, MemoryQuarantineSink where left-out items go (sink)
SchemaCastSettings, LLMSettings, CacheSettings settings (config)

The steps of a cast are modules of their own: select, prompt, extract, validate and repair; resolution is graflo's graflo.link.resolve. The model client is llm, and the benchmark bench.