mirror of
https://github.com/zhenxun-org/zhenxun_bot.git
synced 2025-12-15 14:22:55 +08:00
* ✨ feat(llm): 实现LLM服务模块,支持多提供商统一接口和高级功能 * 🎨 Ruff * ✨ Config配置类支持BaseModel存储 * 🎨 代码格式化 * 🎨 代码格式化 * 🎨 格式化代码 * ✨ feat(llm): 添加 AI 对话历史管理 * ✨ feat(llmConfig): 引入 LLM 配置模型及管理功能 * 🎨 Ruff --------- Co-authored-by: fccckaug <xxxmio123123@gmail.com> Co-authored-by: HibiKier <45528451+HibiKier@users.noreply.github.com> Co-authored-by: HibiKier <775757368@qq.com> Co-authored-by: fccckaug <xxxmcsmiomio3@gmail.com> Co-authored-by: webjoin111 <455457521@qq.com>
27 lines
642 B
Python
27 lines
642 B
Python
"""
|
||
LLM 适配器模块
|
||
|
||
提供不同LLM服务商的API适配器实现,统一接口调用方式。
|
||
"""
|
||
|
||
from .base import BaseAdapter, OpenAICompatAdapter, RequestData, ResponseData
|
||
from .factory import LLMAdapterFactory, get_adapter_for_api_type, register_adapter
|
||
from .gemini import GeminiAdapter
|
||
from .openai import OpenAIAdapter
|
||
from .zhipu import ZhipuAdapter
|
||
|
||
LLMAdapterFactory.initialize()
|
||
|
||
__all__ = [
|
||
"BaseAdapter",
|
||
"GeminiAdapter",
|
||
"LLMAdapterFactory",
|
||
"OpenAIAdapter",
|
||
"OpenAICompatAdapter",
|
||
"RequestData",
|
||
"ResponseData",
|
||
"ZhipuAdapter",
|
||
"get_adapter_for_api_type",
|
||
"register_adapter",
|
||
]
|