Skip to content

Command line

lpgcast (alias text2lpg) casts text; lpgcast-bench runs the benchmark. Model settings come from the environment.

lpgcast sheet

Print what a model is shown for SCHEMA. Makes no model call.

Option Value Meaning
--schema FILE GraFlo schema or manifest (YAML or JSON). (required)
--json-schema flag Print the JSON Schema of the reply instead of the type sheet.

lpgcast select

Show the slice of SCHEMA each text would be cast against. Makes no model call. Prints one JSON line per text: the mode, the seeds and how each lane ranked them, the retrieval metrics and the slice's vertex and edge counts.

Option Value Meaning
--schema FILE GraFlo schema or manifest (YAML or JSON). (required)
--text TEXT A single text to select for.
--episodes FILE Episodes, one JSON object per line.
--sheet flag Print each slice's type sheet.

lpgcast cast

Cast EPISODES into SCHEMA and save the result under OUT. Episodes that produce nothing are quarantined and the run goes on; a misconfigured model, or a cache miss under --replay, stops it.

Option Value Meaning
--schema FILE GraFlo schema or manifest (YAML or JSON). (required)
--episodes FILE Episodes, one JSON object per line. (required)
--out DIRECTORY Directory for the graph, groundings, quarantine and manifest. (required)
--db FILE graflo connection file (YAML); the graph is written there too.
--replay flag Serve every reply from the cache; a miss stops the run. Makes no request.
--recreate-schema flag Drop and redefine the schema on the --db target first.
--concurrency INTEGER Episodes cast at once. (default 8)

lpgcast serve

Serve POST /cast over HTTP (needs the server extra). Every request needs Authorization: Bearer $LPGCAST_SERVE_API_KEY; without a key the service refuses to cast unless LPGCAST_SERVE_ALLOW_ANONYMOUS is set. Model settings come from LPGCAST_LLM_*.

Option Value Meaning
--host TEXT Address to bind; default LPGCAST_SERVE_HOST or 127.0.0.1.
--port INTEGER Port; default LPGCAST_SERVE_PORT or 8997.

lpgcast-bench

Cast and score the corpus; write JSON and Markdown reports.

Option Value Meaning
--model TEXT Model to benchmark, repeatable; the endpoint is LPGCAST_LLM_BASE_URL. Without it only the free oracle row runs. (repeatable)
--oracle / --no-oracle flag Add the oracle row: the expected graph through the whole pipeline. Free. (default True)
--split dev | test | all dev is tuned against; only test is publishable. (default all)
--family TEXT Only these families. (repeatable)
--case TEXT Only these cases, e.g. units/lab. (repeatable)
--replay flag Serve every reply from the cache; a miss stops the run.
--out DIRECTORY Where the JSON and Markdown reports go. (default bench-results)
--concurrency INTEGER (default 8)

lpgcast-bench compare

Read REPORT_B against REPORT_A, episode by episode, on the same corpus.

Option Value Meaning
REPORT_A argument
REPORT_B argument
--row-a TEXT Row of REPORT_A; default: its only row, or its only model row.
--row-b TEXT Row of REPORT_B; default as for --row-a.
--pair-by-name flag Across corpus versions, pair cases a report has no content digest for by name: you assert they did not change.
--json FILE Also write the comparison as JSON here.