Documentation
¶
Overview ¶
Package engine is the stable, host-facing Eyrie API.
Hosts should prefer this package over assembling client, catalog, config, credentials, runtime, and setup packages directly. The lower-level packages remain public for backward compatibility and advanced integrations.
Engine is intentionally stateless with respect to product conversations: the host owns conversation history, tools, permissions, and checkpoints; Eyrie owns credential, catalog, selection, routing, and model transport.
Host-facing DTOs and the Provider port live in github.com/GrayCodeAI/hawk-core-contracts/llm; this package re-exports them as type aliases and *Engine implements llm.Provider (see contract_assert.go).
Index ¶
- Constants
- Variables
- func AccountForEnv(envVar string) string
- func CredentialGuidance(providerID, secret string) string
- func DefaultThinkingDisabled(providerID string) bool
- func FormatPreflight(report PreflightReport) string
- func FormatSetupError(providerID string, err error) string
- func HasSecret(ctx context.Context, envKey string) bool
- func IsCatalogCacheRequired(err error) bool
- func IsCode(err error, code ErrorCode) bool
- func MigrateEnvFileCredentials(ctx context.Context) (int, error)
- func NormalizeProviderID(providerID string) string
- func RegisterCustomGateway(gateway CustomGateway) error
- func RegisteredGatewayCount() int
- func SecretStoreName() string
- func SetSecretStoreServiceName(name string)
- func ThinkingToggleSupported(providerID string) bool
- type CatalogHealth
- type CatalogSnapshot
- type CheckStatus
- type ContentPart
- type CredentialProvider
- type CredentialResolution
- type CredentialStatus
- type CredentialStorageReport
- type CustomGateway
- type CustomGatewayCapabilities
- type DeploymentSummary
- type Engine
- func (e *Engine) ActiveSelection(ctx context.Context) Route
- func (e *Engine) ApplyCredentials(ctx context.Context, providerID string) (CatalogSnapshot, error)
- func (e *Engine) ApplyGatewayEnvironment(_ context.Context, providerID string)
- func (e *Engine) CanonicalModel(ctx context.Context, modelID string) string
- func (e *Engine) Catalog(ctx context.Context) (CatalogSnapshot, error)
- func (e *Engine) CatalogHealth(ctx context.Context) CatalogHealth
- func (e *Engine) ClearSelection(ctx context.Context) error
- func (e *Engine) CompactNative(ctx context.Context, req NativeCompactionRequest) (string, error)
- func (e *Engine) CredentialEnvKeys(providerID string) []string
- func (e *Engine) CredentialProviders(context.Context) []CredentialProvider
- func (e *Engine) CredentialStatus(ctx context.Context, providerID string) (CredentialStatus, error)
- func (e *Engine) DefaultModel(ctx context.Context, provider, fallback string) string
- func (e *Engine) DefaultProviderFilter(ctx context.Context) string
- func (e *Engine) DefaultThinkingDisabled(providerID string) bool
- func (e *Engine) DeploymentRoutingEnabled(override *bool) bool
- func (e *Engine) DeploymentStatus(ctx context.Context, activeModel string) (string, error)
- func (e *Engine) DeploymentSummary(ctx context.Context, activeModel string) (DeploymentSummary, error)
- func (e *Engine) EffectiveSelection(ctx context.Context, opts SelectionOptions) Selection
- func (e *Engine) GatewayDefinitions() []Gateway
- func (e *Engine) GatewayForModel(ctx context.Context, modelID string) string
- func (e *Engine) GatewayRegion(providerID string) (label string, required bool)
- func (e *Engine) Gateways(ctx context.Context) []Gateway
- func (e *Engine) Generate(ctx context.Context, req GenerateRequest) (*GenerateResponse, error)
- func (e *Engine) HasCredentialEnv(ctx context.Context, envVar string) bool
- func (e *Engine) ListLiveModels(ctx context.Context, providerID string) ([]Model, error)
- func (e *Engine) ListModels(ctx context.Context, providerID string, refresh bool) ([]Model, error)
- func (e *Engine) ListPublicModels(ctx context.Context, providerID string) ([]Model, error)
- func (e *Engine) MigrateProviderSecrets() error
- func (e *Engine) MigrateProviderSecretsContext(ctx context.Context) error
- func (e *Engine) ModelClassOf(ctx context.Context, modelID string) ModelClass
- func (e *Engine) ModelInfo(ctx context.Context, modelID string) (Model, bool, error)
- func (e *Engine) ModelNames(ctx context.Context) []string
- func (e *Engine) ModelProviders(ctx context.Context) ([]string, error)
- func (e *Engine) PreferredModel(ctx context.Context, provider string, class ModelClass, fallback string) string
- func (e *Engine) PreferredModels(ctx context.Context, primaryProvider string, class ModelClass, limit int) []string
- func (e *Engine) Preflight(ctx context.Context) PreflightReport
- func (e *Engine) PreflightWithOptions(ctx context.Context, opts PreflightOptions) PreflightReport
- func (e *Engine) PrimaryModel(ctx context.Context) string
- func (e *Engine) ProviderForModel(ctx context.Context, modelID string) string
- func (e *Engine) ProviderStateSecurityStatus() ProviderStateSecurity
- func (e *Engine) RefreshCatalog(ctx context.Context, providerID string) (CatalogSnapshot, error)
- func (e *Engine) RemoveCredential(ctx context.Context, providerID string) error
- func (e *Engine) Resolve(ctx context.Context, req SelectionRequest) (Route, error)
- func (e *Engine) ResolveCredential(ctx context.Context, secret string) CredentialResolution
- func (e *Engine) RoutingPreview(ctx context.Context, modelID string) (string, error)
- func (e *Engine) SaveCredential(ctx context.Context, providerID, secret string) (CredentialStatus, error)
- func (e *Engine) SaveCredentialEnv(ctx context.Context, envVar, secret string) error
- func (e *Engine) SetActiveModel(ctx context.Context, modelID string) error
- func (e *Engine) SetActiveProvider(ctx context.Context, providerID string) error
- func (e *Engine) SetGatewayRegion(ctx context.Context, providerID, value string) error
- func (e *Engine) SetSelection(ctx context.Context, providerID, modelID string) error
- func (e *Engine) StatePaths() StatePaths
- func (e *Engine) Stream(ctx context.Context, req GenerateRequest) (EventStreamer, error)
- func (e *Engine) SupportsNativeCompaction(ctx context.Context, provider, model string) bool
- func (e *Engine) ThinkingToggleSupported(providerID string) bool
- type Error
- type ErrorCode
- type Event
- type EventStreamer
- type Gateway
- type GenerateRequest
- type GenerateResponse
- type GenerationOptions
- type Intent
- type Limits
- type MapStore
- type Message
- type Metadata
- type Model
- type ModelClass
- type NativeCompactionRequest
- type OperationsGraphExport
- type OperationsGraphInput
- type Options
- type Preference
- type PreflightCheck
- type PreflightOptions
- type PreflightReport
- type Provider
- type ProviderStateSecurity
- type Requirements
- type Route
- type Selection
- type SelectionOptions
- type SelectionRequest
- type StatePaths
- type Stream
- type Tool
- type ToolCall
- type ToolChoice
- type ToolResult
- type Usage
Constants ¶
const ( EventRouteSelected = "route_selected" EventRouteChanged = "route_changed" EventContentDelta = "content_delta" EventThinkingDelta = "thinking_delta" EventToolCallStart = "tool_call_start" EventToolCallDelta = "tool_call_delta" EventToolCallDone = "tool_call_done" EventUsage = "usage" EventRetry = "retry" EventContinuation = "continuation" EventWarning = "warning" EventTTFT = "ttft" EventDone = "done" )
Event type names. These are the stable stream vocabulary shared by the engine and its hosts; new types are additive and hosts must safely ignore unknown ones.
Re-export preflight status constants from the contract package.
const ContractVersion = "2"
ContractVersion is the compatibility version of the host-facing API.
Variables ¶
var DefaultStore = credentials.DefaultStore
DefaultStore returns the process-wide credential store (for tests).
var SetDefaultStore = credentials.SetDefaultStore
SetDefaultStore replaces the process-wide credential store (for tests).
Functions ¶
func AccountForEnv ¶
AccountForEnv returns the keychain account name for an env var.
func CredentialGuidance ¶
CredentialGuidance returns provider-specific, non-secret setup guidance.
func DefaultThinkingDisabled ¶
DefaultThinkingDisabled reports whether a provider defaults thinking OFF when unset.
func FormatPreflight ¶
func FormatPreflight(report PreflightReport) string
func FormatSetupError ¶
FormatSetupError returns a safe provider setup hint.
func IsCatalogCacheRequired ¶
IsCatalogCacheRequired reports whether an operation needs the local model catalog to be refreshed before it can continue.
func NormalizeProviderID ¶
NormalizeProviderID resolves provider aliases to Eyrie's runtime identifier.
func RegisterCustomGateway ¶
func RegisterCustomGateway(gateway CustomGateway) error
RegisterCustomGateway registers safe OpenAI-compatible routing metadata for compatibility callers. New embedders should pass Options.CustomGateways so instances stay isolated. Registration must happen before Engine creation; each Engine snapshots the metadata and always resolves credentials through its own injected SecretStore.
func RegisteredGatewayCount ¶
func RegisteredGatewayCount() int
RegisteredGatewayCount returns the first-class provider count from the provider registry. Hosts derive provider counts from Eyrie instead of hard-coding them, so new providers require no host changes.
func SecretStoreName ¶
func SecretStoreName() string
SecretStoreName is safe presentation metadata for host UIs.
func SetSecretStoreServiceName ¶
func SetSecretStoreServiceName(name string)
SetSecretStoreServiceName overrides the OS secret-store service name (default "eyrie"). Hosts call this once at startup so existing credentials filed under their product name (e.g. "hawk") stay readable.
func ThinkingToggleSupported ¶
ThinkingToggleSupported reports whether a provider's wire protocol honors thinking toggles.
Types ¶
type CatalogHealth ¶
type CatalogHealth = llm.CatalogHealth
CatalogHealth is the host-facing catalog health report.
type CatalogSnapshot ¶
type CatalogSnapshot = llm.CatalogSnapshot
CatalogSnapshot is an immutable host-facing view of a loaded catalog. It is a type alias to the canonical llm.CatalogSnapshot so exactly one struct crosses the host boundary (matching every other type in this file).
type ContentPart ¶
type ContentPart = llm.ContentPart
ContentPart is a provider-neutral multimodal message part.
type CredentialProvider ¶
type CredentialProvider = llm.CredentialProviderOption
CredentialProvider is safe setup metadata for a configurable provider. It contains identifiers and labels only, never credential material.
type CredentialResolution ¶
type CredentialResolution = llm.CredentialResolution
CredentialResolution validates pasted input and returns provider choices. The input secret is never retained in this value.
type CredentialStatus ¶
type CredentialStatus = llm.CredentialStatus
CredentialStatus is safe to render or log; it never contains a secret.
type CredentialStorageReport ¶
type CredentialStorageReport struct {
PlatformStore string `json:"platform_store"`
Writable bool `json:"writable"`
Detail string `json:"detail,omitempty"`
Formatted string `json:"formatted,omitempty"`
}
CredentialStorageReport is safe to print and never includes secrets.
func CredentialStorage ¶
func CredentialStorage(ctx context.Context) CredentialStorageReport
type CustomGateway ¶
type CustomGateway struct {
ID string `json:"id"`
DisplayName string `json:"display_name,omitempty"`
BaseURL string `json:"base_url"`
CredentialEnv string `json:"credential_env,omitempty"`
DefaultModel string `json:"default_model,omitempty"`
MaxTokensField string `json:"max_tokens_field,omitempty"`
ContextWindow int `json:"context_window,omitempty"`
SortOrder int `json:"sort_order,omitempty"`
ChatPreference int `json:"chat_preference,omitempty"`
Capabilities *CustomGatewayCapabilities `json:"capabilities,omitempty"`
}
CustomGateway describes a user-configured OpenAI-compatible gateway. It contains only routing metadata; credential material remains in Eyrie's secret store and is discovered by CredentialEnv.
type CustomGatewayCapabilities ¶
type CustomGatewayCapabilities struct {
Streaming bool `json:"streaming,omitempty"`
Tools bool `json:"tools,omitempty"`
Vision bool `json:"vision,omitempty"`
StructuredJSON bool `json:"structured_json,omitempty"`
Reasoning bool `json:"reasoning,omitempty"`
}
CustomGatewayCapabilities declares capabilities known to be supported by a custom OpenAI-compatible gateway. A nil declaration is permissive for backward compatibility: the remote gateway remains the source of truth.
type DeploymentSummary ¶
type DeploymentSummary = llm.DeploymentSummary
DeploymentSummary is the host-facing deployment routing summary.
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
Engine is Eyrie's narrow host facade. It is safe for concurrent use when the configured SecretStore is safe for concurrent use.
func (*Engine) ActiveSelection ¶
ActiveSelection reads the persisted host selection from this Engine's state.
func (*Engine) ApplyCredentials ¶
ApplyCredentials refreshes catalog state and persists sanitized deployment routing derived from the Engine's credential store. Secret fields are never written to provider.json.
func (*Engine) ApplyGatewayEnvironment ¶
ApplyGatewayEnvironment derives process-local regional base URLs. Deprecated: invocation-scoped hosts must use Engine state directly and must not mutate process environment. This remains only for legacy callers.
func (*Engine) CanonicalModel ¶
func (*Engine) Catalog ¶
func (e *Engine) Catalog(ctx context.Context) (CatalogSnapshot, error)
Catalog returns the current cached catalog through a stable snapshot.
func (*Engine) CatalogHealth ¶
func (e *Engine) CatalogHealth(ctx context.Context) CatalogHealth
func (*Engine) ClearSelection ¶
ClearSelection removes active provider/model state without modifying credentials, deployments, or routing.
func (*Engine) CompactNative ¶
CompactNative performs provider-native compaction and returns a normalized summary. Conversation mutation remains the host's responsibility.
func (*Engine) CredentialEnvKeys ¶
func (*Engine) CredentialProviders ¶
func (e *Engine) CredentialProviders(context.Context) []CredentialProvider
CredentialProviders lists safe provider choices for setup UIs.
func (*Engine) CredentialStatus ¶
CredentialStatus reports whether a provider credential is configured.
func (*Engine) DefaultModel ¶
DefaultModel returns the catalog default for a provider.
func (*Engine) DefaultProviderFilter ¶
func (*Engine) DefaultThinkingDisabled ¶
DefaultThinkingDisabled reports whether a provider defaults thinking OFF when unset.
func (*Engine) DeploymentRoutingEnabled ¶
func (*Engine) DeploymentStatus ¶
func (*Engine) DeploymentSummary ¶
func (*Engine) EffectiveSelection ¶
func (e *Engine) EffectiveSelection(ctx context.Context, opts SelectionOptions) Selection
EffectiveSelection resolves persisted state plus optional host overrides using this Engine's injected catalog, provider config, and credential store.
func (*Engine) GatewayDefinitions ¶
GatewayDefinitions returns pure registry/custom metadata in setup UI order. It does not read credentials, provider state, or the model catalog.
func (*Engine) GatewayForModel ¶
func (*Engine) GatewayRegion ¶
GatewayRegion returns normalized region presentation for regional gateways.
func (*Engine) Gateways ¶
Gateways returns safe configuration status using this Engine's injected credential store, catalog path, and provider state path.
func (*Engine) Generate ¶
func (e *Engine) Generate(ctx context.Context, req GenerateRequest) (*GenerateResponse, error)
Generate performs a blocking generation through Eyrie's resolved transport.
func (*Engine) HasCredentialEnv ¶
HasCredentialEnv reports presence without exposing the credential value.
func (*Engine) ListLiveModels ¶
ListLiveModels queries one provider directly without reading from or writing to the catalog cache for its result set. Credentials and routing metadata come exclusively from this Engine's injected state.
func (*Engine) ListModels ¶
ListModels returns provider models through the stable facade.
func (*Engine) ListPublicModels ¶
ListPublicModels returns provider-published model metadata that does not require credentials. It never mutates the Engine catalog cache.
func (*Engine) MigrateProviderSecrets ¶
MigrateProviderSecrets imports credential fields persisted in provider state into the Engine's secret store, then atomically strips them from provider.json.
func (*Engine) MigrateProviderSecretsContext ¶
func (*Engine) ModelClassOf ¶
func (e *Engine) ModelClassOf(ctx context.Context, modelID string) ModelClass
ModelClassOf resolves a model's relative catalog cost band.
func (*Engine) ModelNames ¶
ModelNames returns canonical ids, display names, and aliases for completion.
func (*Engine) ModelProviders ¶
ModelProviders lists canonical catalog model owners and invocation-scoped custom gateway owners.
func (*Engine) PreferredModel ¶
func (e *Engine) PreferredModel(ctx context.Context, provider string, class ModelClass, fallback string) string
PreferredModel returns a provider model in the requested relative class.
func (*Engine) PreferredModels ¶
func (e *Engine) PreferredModels(ctx context.Context, primaryProvider string, class ModelClass, limit int) []string
PreferredModels returns unique cross-provider candidates in preference order.
func (*Engine) PreflightWithOptions ¶
func (e *Engine) PreflightWithOptions(ctx context.Context, opts PreflightOptions) PreflightReport
func (*Engine) PrimaryModel ¶
PrimaryModel returns Eyrie's stable best-effort catalog primary model.
func (*Engine) ProviderForModel ¶
ProviderForModel returns the canonical catalog owner or invocation-scoped custom gateway owner for a model.
func (*Engine) ProviderStateSecurityStatus ¶
func (e *Engine) ProviderStateSecurityStatus() ProviderStateSecurity
ProviderStateSecurityStatus inspects provider.json without returning values.
func (*Engine) RefreshCatalog ¶
RefreshCatalog refreshes one provider when providerID is non-empty, or all configured providers otherwise. Credentials are read from this Engine's injected store rather than a package-global store.
func (*Engine) RemoveCredential ¶
RemoveCredential deletes a provider credential from the configured store.
func (*Engine) Resolve ¶
Resolve selects a concrete provider/model and verifies known catalog requirements before transport construction.
func (*Engine) ResolveCredential ¶
func (e *Engine) ResolveCredential(ctx context.Context, secret string) CredentialResolution
ResolveCredential validates credential input and returns safe provider choices. Eyrie does not retain or return the supplied secret.
func (*Engine) RoutingPreview ¶
func (*Engine) SaveCredential ¶
func (e *Engine) SaveCredential(ctx context.Context, providerID, secret string) (CredentialStatus, error)
SaveCredential validates, stores, and probes a provider credential. The secret is persisted before the probe so a transient network failure does not discard user input. The returned error states that persistence occurred.
func (*Engine) SaveCredentialEnv ¶
SaveCredentialEnv validates and stores a legacy env-addressed credential. New callers should prefer SaveCredential(providerID, secret).
func (*Engine) SetActiveModel ¶
SetActiveModel persists a model choice and infers its serving provider from the configured catalog.
func (*Engine) SetActiveProvider ¶
SetActiveProvider persists a provider choice without requiring a model.
func (*Engine) SetGatewayRegion ¶
SetGatewayRegion persists regional gateway configuration at the Engine path.
func (*Engine) SetSelection ¶
SetSelection persists the host/user's provider and model choice in this Engine's configured state path. It does not persist credentials.
func (*Engine) StatePaths ¶
func (e *Engine) StatePaths() StatePaths
func (*Engine) Stream ¶
func (e *Engine) Stream(ctx context.Context, req GenerateRequest) (EventStreamer, error)
Stream starts a normalized streaming generation. The returned stream must be closed by the caller. The concrete type is *Stream; the signature returns EventStreamer so *Engine satisfies llm.Provider / llm.Generator.
When the concrete *Stream is nil, this returns a typed-nil EventStreamer (interface nil) so callers can check stream == nil reliably.
func (*Engine) SupportsNativeCompaction ¶
SupportsNativeCompaction reports whether the selection and configured credential store support native compaction.
func (*Engine) ThinkingToggleSupported ¶
ThinkingToggleSupported reports whether a provider's wire protocol honors thinking toggles.
type Error ¶
type Error struct {
Code ErrorCode `json:"code"`
Operation string `json:"operation,omitempty"`
Provider string `json:"provider,omitempty"`
Model string `json:"model,omitempty"`
Message string `json:"message,omitempty"`
Retryable bool `json:"retryable,omitempty"`
Cause error `json:"-"`
}
Error is the typed error returned across the host boundary.
type ErrorCode ¶
type ErrorCode string
ErrorCode is a stable, machine-readable engine failure category.
const ( ErrorInvalidRequest ErrorCode = "invalid_request" ErrorCredentialMissing ErrorCode = "credential_missing" ErrorAuthentication ErrorCode = "authentication_failed" ErrorCapabilityMismatch ErrorCode = "capability_mismatch" ErrorContextExceeded ErrorCode = "context_exceeded" ErrorRateLimited ErrorCode = "rate_limited" ErrorBudgetExceeded ErrorCode = "budget_exceeded" ErrorCancelled ErrorCode = "cancelled" ErrorInternal ErrorCode = "internal" )
type Event ¶
type Event = llm.EyrieStreamEvent
Event is a normalized model stream event. New optional fields and event types are additive; hosts must safely ignore unknown event types.
type EventStreamer ¶
type EventStreamer = llm.EventStreamer
EventStreamer is the pull-based host stream contract.
type GenerateRequest ¶
type GenerateRequest = llm.GenerateRequest
GenerateRequest is the provider-neutral request accepted by Engine.
type GenerateResponse ¶
type GenerateResponse = llm.EyrieResponse
GenerateResponse is a normalized blocking response.
type GenerationOptions ¶
type GenerationOptions = llm.GenerationOptions
GenerationOptions contains model-generation controls that have equivalent semantics across one or more provider adapters. Provider-specific wire formats remain internal to Eyrie.
type MapStore ¶
type MapStore = credentials.MapStore
MapStore is the in-memory credential store for tests (alias).
type Message ¶
type Message = llm.EyrieMessage
Message is the stable conversation DTO at the host boundary.
type Metadata ¶
Metadata provides stable correlation identifiers. Providers receive only fields that their adapter explicitly supports.
type ModelClass ¶
type ModelClass = llm.ModelClass
ModelClass is a provider-neutral relative model cost/capability band.
type NativeCompactionRequest ¶
type NativeCompactionRequest = llm.NativeCompactionRequest
NativeCompactionRequest is a provider-native compaction request.
type OperationsGraphExport ¶
type OperationsGraphExport = operationsgraph.Export
OperationsGraphExport is Eyrie's portable operations graph projection.
func BuildOperationsGraph ¶
func BuildOperationsGraph(input OperationsGraphInput) (*OperationsGraphExport, error)
BuildOperationsGraph projects route and normalized usage telemetry without exposing provider, model, request, or generated content values.
type OperationsGraphInput ¶
type OperationsGraphInput = operationsgraph.Input
OperationsGraphInput is the host-facing input for Eyrie's portable operations graph projection.
type Options ¶
type Options struct {
SecretStore credentials.Store
StateDir string
CatalogPath string
ProviderConfigPath string
// RemoteCatalogURL is the trusted published catalog source used by full
// refreshes. Empty selects Eyrie's compiled-in HTTPS catalog URL, never a
// process-environment override.
RemoteCatalogURL string
// CustomGateways is snapshotted per Engine. A non-nil empty slice
// explicitly declares that the host has no custom gateways.
CustomGateways []CustomGateway
// UseRegisteredCustomGateways opts into the deprecated process-global
// RegisterCustomGateway registry when CustomGateways is nil.
UseRegisteredCustomGateways bool
// EnableRateLimiting wraps resolved transports with an adaptive rate
// limiter that backs off when approaching provider limits. Off by default.
EnableRateLimiting bool
// RateLimitConfig configures the adaptive rate limiter. Zero value uses
// sensible defaults (10% threshold, 10s max delay).
RateLimitConfig client.AdaptiveRateLimitConfig
// EnableCaching wraps resolved transports with a semantic response cache.
// Only caches deterministic requests (temperature <= threshold). Off by
// default.
EnableCaching bool
// CacheConfig configures the response cache. Zero value uses sensible
// defaults (5min TTL, 100 entries, 0.5 temperature threshold).
CacheConfig client.CacheConfig
}
Options supplies host-owned dependencies. A zero value uses Eyrie's safe defaults. Product-specific paths are deliberately not inferred here.
type Preference ¶
type Preference = llm.Preference
Preference contains optional selection policy supplied by the host/user.
type PreflightCheck ¶
type PreflightCheck = llm.PreflightCheck
PreflightCheck is one readiness check row.
type PreflightOptions ¶
type PreflightOptions = llm.PreflightOptions
PreflightOptions configures a readiness check.
type PreflightReport ¶
type PreflightReport = llm.PreflightReport
PreflightReport is the host-facing preflight result.
type ProviderStateSecurity ¶
type ProviderStateSecurity = llm.ProviderStateSecurity
ProviderStateSecurity reports provider.json security posture (no secrets).
type Requirements ¶
type Requirements = llm.Requirements
Requirements describes capabilities that a resolved model must support.
type Route ¶
type Route = llm.ResolvedRoute
Route is the concrete model/deployment decision made by Eyrie.
type SelectionOptions ¶
type SelectionOptions = llm.SelectionOptions
SelectionOptions contains optional user or command-line overrides.
type SelectionRequest ¶
type SelectionRequest struct {
Requirements Requirements
Preference Preference
}
SelectionRequest asks Eyrie to resolve a concrete provider/model route.
type StatePaths ¶
type StatePaths = llm.StatePaths
StatePaths reports the Engine's host-owned state locations without reading or parsing either file.
type Stream ¶
type Stream struct {
// contains filtered or unexported fields
}
Stream is a normalized, pull-based event stream. Next must not be called concurrently. Close is idempotent and may be called from another goroutine.
type Tool ¶
Tool is a model-visible tool definition. Eyrie emits requests for these tools; the host remains responsible for permission checks and execution.
type ToolCall ¶
ToolCall is a normalized tool invocation.
func ParseInlineToolCalls ¶
ParseInlineToolCalls normalizes provider text-embedded tool calls into the stable engine contract. Providers that emit structured tool calls bypass this fallback.
type ToolChoice ¶
type ToolChoice = llm.ToolChoiceOption
ToolChoice controls whether and how the model may request tools.
type ToolResult ¶
type ToolResult = llm.ToolResult
ToolResult is a host-executed tool result sent back to a model.