add: 添加命令ai model list的逻辑
This commit is contained in:
16
maubot_llmplus/plugin.py
Normal file
16
maubot_llmplus/plugin.py
Normal file
@@ -0,0 +1,16 @@
|
||||
from maubot import Plugin
|
||||
|
||||
|
||||
class AbsExtraConfigPlugin(Plugin):
|
||||
default_username: str
|
||||
user_id: str
|
||||
|
||||
async def start(self) -> None:
|
||||
await super().start()
|
||||
self.default_username = await self.client.get_displayname(self.client.mxid)
|
||||
self.user_id = self.client.parse_user_id(self.client.mxid)[0]
|
||||
|
||||
def get_bot_name(self) -> str:
|
||||
return self.config['name'] or \
|
||||
self.default_username or \
|
||||
self.user_id
|
||||
Reference in New Issue
Block a user