diff --git a/astrbot/api/provider/__init__.py b/astrbot/api/provider/__init__.py index 557273acd..9b1ade50a 100644 --- a/astrbot/api/provider/__init__.py +++ b/astrbot/api/provider/__init__.py @@ -1,5 +1,5 @@ from astrbot.core.provider import Provider, STTProvider, Personality -from astrbot.core.provider.entites import ( +from astrbot.core.provider.entities import ( ProviderRequest, ProviderType, ProviderMetaData, diff --git a/astrbot/core/pipeline/process_stage/method/llm_request.py b/astrbot/core/pipeline/process_stage/method/llm_request.py index 7b4403a75..a2bbc1c8b 100644 --- a/astrbot/core/pipeline/process_stage/method/llm_request.py +++ b/astrbot/core/pipeline/process_stage/method/llm_request.py @@ -17,7 +17,7 @@ from astrbot.core.message.message_event_result import ( from astrbot.core.message.components import Image from astrbot.core import logger from astrbot.core.utils.metrics import Metric -from astrbot.core.provider.entites import ( +from astrbot.core.provider.entities import ( ProviderRequest, LLMResponse, ToolCallMessageSegment, diff --git a/astrbot/core/pipeline/process_stage/stage.py b/astrbot/core/pipeline/process_stage/stage.py index 4c52a4a3e..f653a9fb9 100644 --- a/astrbot/core/pipeline/process_stage/stage.py +++ b/astrbot/core/pipeline/process_stage/stage.py @@ -5,7 +5,7 @@ from .method.llm_request import LLMRequestSubStage from .method.star_request import StarRequestSubStage from astrbot.core.platform.astr_message_event import AstrMessageEvent from astrbot.core.star.star_handler import StarHandlerMetadata -from astrbot.core.provider.entites import ProviderRequest +from astrbot.core.provider.entities import ProviderRequest from astrbot.core import logger diff --git a/astrbot/core/platform/astr_message_event.py b/astrbot/core/platform/astr_message_event.py index 8a7665d79..8d3bc4c59 100644 --- a/astrbot/core/platform/astr_message_event.py +++ b/astrbot/core/platform/astr_message_event.py @@ -16,7 +16,7 @@ from astrbot.core.message.components import ( ) from astrbot.core.message.message_event_result import MessageEventResult, MessageChain from astrbot.core.platform.message_type import MessageType -from astrbot.core.provider.entites import ProviderRequest +from astrbot.core.provider.entities import ProviderRequest from astrbot.core.utils.metrics import Metric from .astrbot_message import AstrBotMessage, Group from .platform_metadata import PlatformMetadata diff --git a/astrbot/core/provider/__init__.py b/astrbot/core/provider/__init__.py index f30d1ac32..ed7135fe6 100644 --- a/astrbot/core/provider/__init__.py +++ b/astrbot/core/provider/__init__.py @@ -1,5 +1,5 @@ from .provider import Provider, Personality, STTProvider -from .entites import ProviderMetaData +from .entities import ProviderMetaData __all__ = ["Provider", "Personality", "ProviderMetaData", "STTProvider"] diff --git a/astrbot/core/provider/entites.py b/astrbot/core/provider/entities.py similarity index 100% rename from astrbot/core/provider/entites.py rename to astrbot/core/provider/entities.py diff --git a/astrbot/core/provider/manager.py b/astrbot/core/provider/manager.py index a3fa65e86..9812a7e6a 100644 --- a/astrbot/core/provider/manager.py +++ b/astrbot/core/provider/manager.py @@ -2,7 +2,7 @@ import traceback import asyncio from astrbot.core.config.astrbot_config import AstrBotConfig from .provider import Provider, STTProvider, TTSProvider, Personality -from .entites import ProviderType +from .entities import ProviderType from typing import List from astrbot.core.db import BaseDatabase from .register import provider_cls_map, llm_tools diff --git a/astrbot/core/provider/provider.py b/astrbot/core/provider/provider.py index 21185d6e3..96547c5c2 100644 --- a/astrbot/core/provider/provider.py +++ b/astrbot/core/provider/provider.py @@ -3,7 +3,7 @@ from typing import List from astrbot.core.db import BaseDatabase from typing import TypedDict, AsyncGenerator from astrbot.core.provider.func_tool_manager import FuncCall -from astrbot.core.provider.entites import LLMResponse, ToolCallsResult +from astrbot.core.provider.entities import LLMResponse, ToolCallsResult from dataclasses import dataclass diff --git a/astrbot/core/provider/register.py b/astrbot/core/provider/register.py index 41a7a29d5..02d7934d1 100644 --- a/astrbot/core/provider/register.py +++ b/astrbot/core/provider/register.py @@ -1,5 +1,5 @@ from typing import List, Dict -from .entites import ProviderMetaData, ProviderType +from .entities import ProviderMetaData, ProviderType from astrbot.core import logger from .func_tool_manager import FuncCall diff --git a/astrbot/core/provider/sources/anthropic_source.py b/astrbot/core/provider/sources/anthropic_source.py index 2a73c3079..319515c52 100644 --- a/astrbot/core/provider/sources/anthropic_source.py +++ b/astrbot/core/provider/sources/anthropic_source.py @@ -11,7 +11,7 @@ from astrbot import logger from astrbot.core.provider.func_tool_manager import FuncCall from ..register import register_provider_adapter from astrbot.core.message.message_event_result import MessageChain -from astrbot.core.provider.entites import LLMResponse, ToolCallsResult +from astrbot.core.provider.entities import LLMResponse, ToolCallsResult from .openai_source import ProviderOpenAIOfficial diff --git a/astrbot/core/provider/sources/dashscope_source.py b/astrbot/core/provider/sources/dashscope_source.py index 59f2b5f98..2c4930692 100644 --- a/astrbot/core/provider/sources/dashscope_source.py +++ b/astrbot/core/provider/sources/dashscope_source.py @@ -3,7 +3,7 @@ import asyncio import functools from typing import List from .. import Provider, Personality -from ..entites import LLMResponse +from ..entities import LLMResponse from ..func_tool_manager import FuncCall from astrbot.core.db import BaseDatabase from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/dashscope_tts.py b/astrbot/core/provider/sources/dashscope_tts.py index 06b390fcd..caef7f89b 100644 --- a/astrbot/core/provider/sources/dashscope_tts.py +++ b/astrbot/core/provider/sources/dashscope_tts.py @@ -3,7 +3,7 @@ import uuid import asyncio from dashscope.audio.tts_v2 import * from ..provider import TTSProvider -from ..entites import ProviderType +from ..entities import ProviderType from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/dify_source.py b/astrbot/core/provider/sources/dify_source.py index 65fe76fce..1adb0f884 100644 --- a/astrbot/core/provider/sources/dify_source.py +++ b/astrbot/core/provider/sources/dify_source.py @@ -2,7 +2,7 @@ import astrbot.core.message.components as Comp from typing import List from .. import Provider, Personality -from ..entites import LLMResponse +from ..entities import LLMResponse from ..func_tool_manager import FuncCall from astrbot.core.db import BaseDatabase from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/edge_tts_source.py b/astrbot/core/provider/sources/edge_tts_source.py index 0eadb2190..338abe263 100644 --- a/astrbot/core/provider/sources/edge_tts_source.py +++ b/astrbot/core/provider/sources/edge_tts_source.py @@ -4,7 +4,7 @@ import edge_tts import subprocess import asyncio from ..provider import TTSProvider -from ..entites import ProviderType +from ..entities import ProviderType from ..register import register_provider_adapter from astrbot.core import logger diff --git a/astrbot/core/provider/sources/fishaudio_tts_api_source.py b/astrbot/core/provider/sources/fishaudio_tts_api_source.py index 84b4b677e..07d0c32ab 100644 --- a/astrbot/core/provider/sources/fishaudio_tts_api_source.py +++ b/astrbot/core/provider/sources/fishaudio_tts_api_source.py @@ -4,7 +4,7 @@ from pydantic import BaseModel, conint from httpx import AsyncClient from typing import Annotated, Literal from ..provider import TTSProvider -from ..entites import ProviderType +from ..entities import ProviderType from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/gemini_source.py b/astrbot/core/provider/sources/gemini_source.py index 4ce775fa0..851396e1f 100644 --- a/astrbot/core/provider/sources/gemini_source.py +++ b/astrbot/core/provider/sources/gemini_source.py @@ -12,7 +12,7 @@ from astrbot import logger from astrbot.core.provider.func_tool_manager import FuncCall from typing import List from ..register import register_provider_adapter -from astrbot.core.provider.entites import LLMResponse +from astrbot.core.provider.entities import LLMResponse class SimpleGoogleGenAIClient: diff --git a/astrbot/core/provider/sources/gsvi_tts_source.py b/astrbot/core/provider/sources/gsvi_tts_source.py index b57932edf..581eef4dc 100644 --- a/astrbot/core/provider/sources/gsvi_tts_source.py +++ b/astrbot/core/provider/sources/gsvi_tts_source.py @@ -2,7 +2,7 @@ import uuid import aiohttp import urllib.parse from ..provider import TTSProvider -from ..entites import ProviderType +from ..entities import ProviderType from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/llmtuner_source.py b/astrbot/core/provider/sources/llmtuner_source.py index c43d03580..ebe9235fd 100644 --- a/astrbot/core/provider/sources/llmtuner_source.py +++ b/astrbot/core/provider/sources/llmtuner_source.py @@ -2,7 +2,7 @@ import os from llmtuner.chat import ChatModel from typing import List from .. import Provider -from ..entites import LLMResponse +from ..entities import LLMResponse from ..func_tool_manager import FuncCall from astrbot.core.db import BaseDatabase from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/openai_source.py b/astrbot/core/provider/sources/openai_source.py index 0d080167e..7c4f5995e 100644 --- a/astrbot/core/provider/sources/openai_source.py +++ b/astrbot/core/provider/sources/openai_source.py @@ -20,7 +20,7 @@ from astrbot import logger from astrbot.core.provider.func_tool_manager import FuncCall from typing import List, AsyncGenerator from ..register import register_provider_adapter -from astrbot.core.provider.entites import LLMResponse +from astrbot.core.provider.entities import LLMResponse @register_provider_adapter( diff --git a/astrbot/core/provider/sources/openai_tts_api_source.py b/astrbot/core/provider/sources/openai_tts_api_source.py index f120a6a59..20b00f949 100644 --- a/astrbot/core/provider/sources/openai_tts_api_source.py +++ b/astrbot/core/provider/sources/openai_tts_api_source.py @@ -1,7 +1,7 @@ import uuid from openai import AsyncOpenAI, NOT_GIVEN from ..provider import TTSProvider -from ..entites import ProviderType +from ..entities import ProviderType from ..register import register_provider_adapter diff --git a/astrbot/core/provider/sources/sensevoice_selfhosted_source.py b/astrbot/core/provider/sources/sensevoice_selfhosted_source.py index 84087ecf6..b6e3331f8 100644 --- a/astrbot/core/provider/sources/sensevoice_selfhosted_source.py +++ b/astrbot/core/provider/sources/sensevoice_selfhosted_source.py @@ -11,7 +11,7 @@ import re from funasr_onnx import SenseVoiceSmall from funasr_onnx.utils.postprocess_utils import rich_transcription_postprocess from ..provider import STTProvider -from ..entites import ProviderType +from ..entities import ProviderType from astrbot.core.utils.io import download_file from ..register import register_provider_adapter from astrbot.core import logger diff --git a/astrbot/core/provider/sources/whisper_api_source.py b/astrbot/core/provider/sources/whisper_api_source.py index e38a81de9..0009af906 100644 --- a/astrbot/core/provider/sources/whisper_api_source.py +++ b/astrbot/core/provider/sources/whisper_api_source.py @@ -2,7 +2,7 @@ import uuid import os from openai import AsyncOpenAI, NOT_GIVEN from ..provider import STTProvider -from ..entites import ProviderType +from ..entities import ProviderType from astrbot.core.utils.io import download_file from ..register import register_provider_adapter from astrbot.core import logger diff --git a/astrbot/core/provider/sources/whisper_selfhosted_source.py b/astrbot/core/provider/sources/whisper_selfhosted_source.py index cfd1267d0..96f0b6f6d 100644 --- a/astrbot/core/provider/sources/whisper_selfhosted_source.py +++ b/astrbot/core/provider/sources/whisper_selfhosted_source.py @@ -3,7 +3,7 @@ import os import asyncio import whisper from ..provider import STTProvider -from ..entites import ProviderType +from ..entities import ProviderType from astrbot.core.utils.io import download_file from ..register import register_provider_adapter from astrbot.core import logger diff --git a/astrbot/core/provider/sources/zhipu_source.py b/astrbot/core/provider/sources/zhipu_source.py index 3e819d633..2f7490317 100644 --- a/astrbot/core/provider/sources/zhipu_source.py +++ b/astrbot/core/provider/sources/zhipu_source.py @@ -3,7 +3,7 @@ from astrbot import logger from astrbot.core.provider.func_tool_manager import FuncCall from typing import List from ..register import register_provider_adapter -from astrbot.core.provider.entites import LLMResponse +from astrbot.core.provider.entities import LLMResponse from .openai_source import ProviderOpenAIOfficial