类class
agentscope.credentialDeepSeekCredential
class DeepSeekCredential(CredentialBase)
源码Source
agentscope/credential/_deepseek.py:15–41DeepSeek 凭证模型。位于 agentscope.credential 包,继承自 CredentialBase。核心成员包括 get_chat_model_class。
The DeepSeek credential model. Declared in agentscope.credential. Extends CredentialBase.
属性摘要Attribute Summary
| 属性Attribute | 类型Type | 说明Description | 值Value |
|---|---|---|---|
model_config | — | 模型配置字段。 | ConfigDict(title='DeepSeek API') |
type | Literal['deepseek_credential'] | 类型字段。 | 'deepseek_credential' |
api_key | SecretStr | DeepSeek API 密钥。 | Field(description='The DeepSeek API key.') |
base_url | str | 基类 URL 用于 DeepSeek API。 | Field(default=_DEEPSEEK_BASE_URL, description='The base URL for the DeepSeek API.') |
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
def get_chat_model_class() -> Type['ChatModelBase'] | 返回DeepSeekChatModel 类。 Return the DeepSeekChatModel class. |
属性详情Attribute Detail
model_config
= ConfigDict(title='DeepSeek API')模型配置字段。
DeepSeek API
源码Source
agentscope/credential/_deepseek.py:18type
Literal['deepseek_credential'] = 'deepseek_credential'类型字段。声明为 Literal['deepseek_credential']。
The type field.
源码Source
agentscope/credential/_deepseek.py:22api_key
SecretStr = Field(description='The DeepSeek API key.')DeepSeek API 密钥。
The DeepSeek API key.
源码Source
agentscope/credential/_deepseek.py:25base_url
str = Field(default=_DEEPSEEK_BASE_URL, description='The base URL for the DeepSeek API.')基类 URL 用于 DeepSeek API。
The base URL for the DeepSeek API.
源码Source
agentscope/credential/_deepseek.py:30方法详情Method Detail
get_chat_model_class
def get_chat_model_class() -> Type['ChatModelBase']
返回DeepSeekChatModel 类。
Return the DeepSeekChatModel class.
Type['ChatModelBase']
返回类型['ChatModelBase']。Returns type chat model base.
源码Source
agentscope/credential/_deepseek.py:37–41