diff --git a/base-config.yaml b/base-config.yaml index 87b546c..63cae4e 100644 --- a/base-config.yaml +++ b/base-config.yaml @@ -17,6 +17,7 @@ platforms: api_key: model: llama3.2 max_words: 1000 + max_context_messages: 100 openai: url: api_key: diff --git a/maubot.yaml b/maubot.yaml index ef8c5ac..75360a1 100644 --- a/maubot.yaml +++ b/maubot.yaml @@ -3,7 +3,6 @@ id: cn.tayxie.llmplus version: 1.0.0 license: MIT modules: - - maubot_platform - maubot_llmplus main_class: AiBotPlugin config: true diff --git a/maubot_llmplus/aibot.py b/maubot_llmplus/aibot.py index 7237533..0870cea 100644 --- a/maubot_llmplus/aibot.py +++ b/maubot_llmplus/aibot.py @@ -7,9 +7,9 @@ from mautrix.types import Format, TextMessageEventContent, EventType, MessageTyp from mautrix.util import markdown from mautrix.util.config import BaseProxyConfig, ConfigUpdateHelper -from maubot_platform.local_paltform import Ollama, LmStudio -from maubot_platform import Platform -from maubot_platform.thrid_platform import OpenAi, Anthropic +from maubot_llmplus.local_paltform import Ollama, LmStudio +from maubot_llmplus.platforms import Platform +from maubot_llmplus.thrid_platform import OpenAi, Anthropic """ 配置文件加载 diff --git a/maubot_platform/local_paltform.py b/maubot_llmplus/local_paltform.py similarity index 93% rename from maubot_platform/local_paltform.py rename to maubot_llmplus/local_paltform.py index 576c7f0..8f16d25 100644 --- a/maubot_platform/local_paltform.py +++ b/maubot_llmplus/local_paltform.py @@ -3,8 +3,8 @@ import json from mautrix.types import MessageEvent from mautrix.util.config import BaseProxyConfig -from maubot_platform import platforms -from maubot_platform.platforms import Platform, ChatCompletion +from maubot_llmplus import platforms +from maubot_llmplus.platforms import Platform, ChatCompletion class Ollama(Platform): diff --git a/maubot_platform/platforms.py b/maubot_llmplus/platforms.py similarity index 100% rename from maubot_platform/platforms.py rename to maubot_llmplus/platforms.py diff --git a/maubot_platform/thrid_platform.py b/maubot_llmplus/thrid_platform.py similarity index 93% rename from maubot_platform/thrid_platform.py rename to maubot_llmplus/thrid_platform.py index 4b50b71..33d58d4 100644 --- a/maubot_platform/thrid_platform.py +++ b/maubot_llmplus/thrid_platform.py @@ -1,7 +1,7 @@ from mautrix.types import MessageEvent from mautrix.util.config import BaseProxyConfig -from maubot_platform.platforms import Platform, ChatCompletion +from maubot_llmplus.platforms import Platform, ChatCompletion class OpenAi(Platform): diff --git a/maubot_platform/__init__.py b/maubot_platform/__init__.py deleted file mode 100644 index e69de29..0000000