Documentation
¶
Overview ¶
Package compatmode holds shared helpers for custom-compatible backend modes.
Index ¶
- func AnthropicModelsEndpoint(d endpoint.Descriptor) (string, error)
- func AnthropicModelsEndpointPath(d endpoint.Descriptor, path string) (string, error)
- func ApplyCapabilityCeiling(be execbackend.Backend, ceiling lipapi.BackendCaps) execbackend.Backend
- func ApplyRuntimePolicy(be execbackend.Backend, cfg config.CompatibleModeConfig) (execbackend.Backend, error)
- func ApplyStaticModelInventory(be execbackend.Backend, models config.CompatibleModeModelsConfig) (execbackend.Backend, error)
- func FirstAPIKey(keys []string) string
- func OpenAIModelsEndpoint(d endpoint.Descriptor) (string, error)
- func ParseEndpoint(cfg config.CompatibleModeConfig) (endpoint.Descriptor, error)
- func ResolveEnvAPIKeys(apiKeyEnvVarRoot string) []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AnthropicModelsEndpoint ¶
func AnthropicModelsEndpoint(d endpoint.Descriptor) (string, error)
AnthropicModelsEndpoint joins the default models path for Anthropic-compatible inventory.
func AnthropicModelsEndpointPath ¶
func AnthropicModelsEndpointPath(d endpoint.Descriptor, path string) (string, error)
AnthropicModelsEndpointPath joins a validated, relative model-list path to an Anthropic-compatible base URL. It is intentionally separate from the default operation join so profile quirks cannot alter execution endpoints.
func ApplyCapabilityCeiling ¶
func ApplyCapabilityCeiling(be execbackend.Backend, ceiling lipapi.BackendCaps) execbackend.Backend
ApplyCapabilityCeiling keeps model-aware family resolution from elevating a validated profile above its declared effective capability surface.
func ApplyRuntimePolicy ¶
func ApplyRuntimePolicy(be execbackend.Backend, cfg config.CompatibleModeConfig) (execbackend.Backend, error)
ApplyRuntimePolicy attaches optional per-instance tokenizer metadata.
func ApplyStaticModelInventory ¶
func ApplyStaticModelInventory(be execbackend.Backend, models config.CompatibleModeModelsConfig) (execbackend.Backend, error)
ApplyStaticModelInventory attaches a static inventory provider when configured.
func FirstAPIKey ¶
FirstAPIKey returns the first resolved credential or empty for no-auth.
func OpenAIModelsEndpoint ¶
func OpenAIModelsEndpoint(d endpoint.Descriptor) (string, error)
OpenAIModelsEndpoint joins the models path for OpenAI-compatible inventory.
func ParseEndpoint ¶
func ParseEndpoint(cfg config.CompatibleModeConfig) (endpoint.Descriptor, error)
ParseEndpoint validates base_url for a compatible instance.
func ResolveEnvAPIKeys ¶
ResolveEnvAPIKeys reads numbered env-root keys into an independent slice for one runtime instance. Empty root yields no-auth.
Types ¶
This section is empty.