Add OpenAI-compatible model client

This commit is contained in:
2026-07-28 04:29:17 +00:00
parent 62b26fb29e
commit 7e94ab133b
7 changed files with 1739 additions and 8 deletions

View File

@@ -21,7 +21,7 @@ The implemented internal components consist of:
- `internal/domain`, which owns framework data values shared by later internal
components;
- `internal/defaults`, which owns application-neutral framework defaults and
constructs the default execution target; and
constructs the default execution target;
- `internal/filecatalog`, which discovers YAML files and provides source-path
helpers for filesystem and `fs.FS` consumers;
- `internal/promptdef`, which loads and validates prompt definitions from
@@ -32,17 +32,20 @@ The implemented internal components consist of:
catalog;
- `internal/prompt`, which renders prompt messages from Go templates;
- `internal/artifact`, which resolves ordinary inline and unrestricted
caller-selected file references; and
caller-selected file references;
- `internal/validate`, which validates basic, JSON, and JSON Schema output
using filesystem and `fs.FS` schema sources.
using filesystem and `fs.FS` schema sources; and
- `internal/llm`, which defines the provider-neutral generation boundary and
implements outbound OpenAI-compatible chat requests.
The defaults and renderer depend on the domain model. Prompt-definition and
profile repositories use the domain model, file catalog, and YAML decoder. The
built-in profile repository supplies an embedded `fs.FS` to the profile
package. Artifact reading uses the domain model and application-neutral
defaults. Validation uses the domain model, file catalog, and JSON Schema
implementation. Model clients, orchestration, and the public engine have not
yet been extracted.
implementation. The model client uses the domain model, application-neutral
defaults, and an injected or standard-library HTTP client. Orchestration and
the public engine have not yet been extracted.
Future framework extraction must follow this dependency direction: