Documentation
¶
Overview ¶
Package catalog implements provider model discovery with a small, account-and-endpoint-scoped last-good cache and non-blocking snapshot reads.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultCachePath ¶
DefaultCachePath derives the platform cache location from the caller's environment. Keeping this explicit prevents embedded callers and tests from accidentally reading or replacing another user's model catalog.
Types ¶
type Catalog ¶
type Catalog struct {
Adapters map[string]runner.Adapter
Config config.Config
CachePath string
Now func() time.Time
}
func (*Catalog) CachedModels ¶
func (c *Catalog) CachedModels(provider, account string, runtime runner.ModelListRequest) ([]runner.ModelInfo, bool)
CachedModels returns an account-scoped snapshot without contacting the provider. It preserves the last verified availability so an interactive picker can open immediately; Origin and AgeSeconds still identify stale data.
Click to show internal directories.
Click to hide internal directories.