@trace2test/llm
v0.1.0
Published
OpenAI API and Codex CLI LLM clients for trace2test.
Downloads
26
Readme
@trace2test/llm
All M3 model calls use the LlmClient.completeJson interface. createLlmClient selects the
OpenAI Responses API when OPENAI_API_KEY is present, otherwise it uses an installed Codex
CLI through codex exec --json. Both providers validate the final value with the caller's
Zod schema and make one corrective retry after malformed JSON or a schema mismatch.
The OpenAI client defaults to gpt-5.6 and sends a strict JSON Schema response format. The
Codex client runs ephemeral, non-interactive, and read-only; it extracts the final assistant
message from Codex JSONL events before performing the same local validation.
