---
title: config | CodeWeaver Docs
description: API reference for codeweaver.providers.config
url: "https://docs.knitli.com/api/providers/config"
type: static
generatedAt: "2026-04-17T17:21:08.690Z"
---

# config
       [Open in ChatGPT](https://chatgpt.com/?q=Read%20https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F.%20I%20want%20to%20ask%20questions%20about%20it.)[Open in Claude](https://claude.ai/new?q=Read%20https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F.%20I%20want%20to%20ask%20questions%20about%20it.)[View in Markdown](/codeweaver/api/providers/config.md)       [Share on LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F)[Share on X](https://x.com/intent/tweet?url=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F&text=config)[Share on Threads](https://threads.net/intent/post?url=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F&text=config)[Share on Bluesky](https://bsky.app/intent/compose?text=config%20https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F)[Share on Facebook](https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F)[Share on Reddit](https://reddit.com/submit?url=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F&title=config)[Share on Hacker News](https://news.ycombinator.com/submitlink?u=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F&t=config)[Share on Email](mailto:?subject=config&body=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F)[Share on WhatsApp](https://wa.me/?text=config%20https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F)[Share on Telegram](https://t.me/share/url?url=https%3A%2F%2Fdocs.knitli.com%2Fcodeweaver%2Fapi%2Fproviders%2Fconfig%2F&text=config)
# `codeweaver.providers.config`
[Section titled “codeweaver.providers.config”](#codeweaverprovidersconfig)
Package-level lazy imports for codeweaver.providers.config package.

## Provider Configuration, Settings, and Options
[Section titled “Provider Configuration, Settings, and Options”](#provider-configuration-settings-and-options)
This package provides comprehensive configuration classes, types, and utilities for managing provider settings across various categories, including:

 - **Agent Providers**: Configuration for LLM-based agents.
 - **Data Providers**: Configuration for tools and data sources.
 - **Embedding Providers**: Configuration for models that generate vector embeddings.
 - **Sparse Embedding Providers**: Configuration for models that generate sparse vector embeddings.
 - **Reranking Providers**: Configuration for models that perform reranking of results.
 - **Vector Store Providers**: Configuration for vector databases and stores.

## Structure and Organization
[Section titled “Structure and Organization”](#structure-and-organization)
Each category of provider configuration, and each provider within that category, has three levels of configuration:

 1. **Provider Settings**: These are the top-level settings classes for a given category of providers (e.g. `BaseAgentProviderSettings`, `BaseEmbeddingProviderSettings`, etc.) that define the common configuration options for that category, and are subclassed by provider-specific settings classes (e.g. `AnthropicAgentProviderSettings`, `OpenAIEmbeddingProviderSettings`, etc.). The `provider` is the *service provider*, ‘who you pay’, except for local providers which are more accurately ‘what you use’. Another way to consider it is ‘who you authenticate with or need an API key for’. The following two configuration levels are contained within a given provider setting class as fields. Defined in `codeweaver.providers.config.categories` package.
 1. **Client Options**: These are configuration classes that define the options for using a specific SDK or API client to interact with a provider. This can often be different from the service provider, for example, many providers use the OpenAI SDK or have OpenAI compatible APIs — the provider is the provider, but the client is the OpenAI client. The parent `ProviderSettings` class will have this configuration in its `client_options` field. For convenience, we differentiate top-level provider settings classes by both provider and SDK, for example `AnthropicAgentProviderSettings` vs `AnthropicAzureAgentProviderSettings`, which both have an `AnthropicClientOptions` field, but the former is for directly using Anthropic as a service provider and the latter is for using Anthropic models with Azure as the service provider, which has some different configuration options and requirements. Defined in `codeweaver.providers.config.clients` package.
 1. **SDK Configuration**: These are configuration classes for *principal* method or functions calls to the underlying SDKs, which are not part of the client’s constructor (i.e. client options). The field names correspond to a common name for the function or method call, for example `embed` is the field for configuring parameters to the SDK’s embedding generation method. Defined in the `codeweaver.providers.config.sdk` package.

### A Special Case: Model Configuration
[Section titled “A Special Case: Model Configuration”](#a-special-case-model-configuration)
In most cases, either the ClientOptions or the SDK configuration will cover the configuration options for the model. However, there are some cases where the model configuration is separate or the model has its own constructor.

This is true for *all agent providers*, because it is how PydanticAI structures its agent classes and types, and we use PydanticAI for all agent provider implementations. This is the `agent_config` field in the agent provider settings classes. Since agents have no functional settings with PydanticAI, the classes for `agent_config` are in the `codeweaver.providers.config.sdk.agent` package.

The only other exception is for **Bedrock**, which for both reranking and embedding models, requires a separate model configuration class that is distinct from the client options and SDK configuration and is specific to the model family. For Bedrock, this is the `model_options` field in the top-level provider settings class, such as `BedrockEmbeddingProviderSettings`.