Skip to main content

Module config_adapter

Module config_adapter 

Source
Expand description

Provider configuration traits decoupled from VT Code’s dot-config storage.

Consumers can implement ProviderConfig for their own types and use the conversion helpers to build vtcode_core provider factories without depending on VT Code’s internal configuration structs.

Structs§

AdapterHooks
Shared adapter that enriches ProviderConfig conversions with WorkspacePaths, telemetry, and error-reporting hooks from vtcode-commons.
OwnedProviderConfig
Simple builder-friendly provider configuration backed by owned values.

Enums§

AdapterEvent
Telemetry event emitted when adapter hooks adjust provider configuration.

Traits§

AdapterHooksProvider
Trait that bundles the adapter hook dependencies into a single interface. This replaces the previous four-parameter generic bound (Paths, Telemetry, Reporter, Formatter) with a single trait, following the Config Trait pattern from the Rust Patterns guide (Ch 3 — Config Trait Pattern).
ProviderConfig
Trait describing the configuration required to instantiate an LLM provider.

Functions§

as_factory_config
Convert an implementor of ProviderConfig into the configuration used by the vtcode_core provider factory.
as_factory_config_with_hooks
Convert a ProviderConfig into the factory configuration using the supplied adapter hooks for workspace, telemetry, and error integration.