-
-
Notifications
You must be signed in to change notification settings - Fork 804
Refactor: 重构配置前端页面,新增数个配置项 #2331
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor: 重构配置前端页面,新增数个配置项 #2331
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
此 PR 对 AstrBot 进行了重要的前端页面重构,新增了多个配置项,并改进了多配置文件管理功能。主要改进了用户体验和配置的组织结构。
- 重构前端配置页面的用户界面,增加配置类型切换和多配置文件管理
- 新增多个配置项,包括图片转述、人格池、提供商池等功能
- 移除了一些过时的功能和代码,简化了项目结构
Reviewed Changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 3 comments.
Show a summary per file
File | Description |
---|---|
packages/astrbot/long_term_memory.py | 添加 TODO 注释标记待移除的配置项 |
dashboard/src/views/ProviderPage.vue | 移除会话隔离设置相关的 UI 组件和功能 |
dashboard/src/views/PlatformPage.vue | 移除重启检查相关的组件引用 |
dashboard/src/views/ConfigPage.vue | 大幅重构配置页面,新增多配置文件管理和现代化 UI |
dashboard/src/layouts/full/vertical-sidebar/VerticalSidebar.vue | 移除未使用的导入和变量 |
dashboard/src/i18n/locales/zh-CN/features/config.json | 新增配置相关的国际化文本 |
dashboard/src/components/shared/ | 新增多个组件支持提供商、人格和列表项选择 |
astrbot/dashboard/routes/config.py | 新增多配置文件管理的后端 API 接口 |
astrbot/core/provider/func_tool_manager.py | 修正函数参数名称的不一致问题 |
astrbot/core/core_lifecycle.py | 重构流水线调度器加载和重载逻辑 |
astrbot/core/config/default.py | 新增大量配置项和配置元数据定义 |
astrbot/core/astrbot_config_mgr.py | 增强配置管理器支持配置文件的增删改查 |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
@@ -52,7 +53,7 @@ def _load_all_configs(self): | |||
) | |||
continue | |||
|
|||
def _is_umo_match(p1: str, p2: str) -> bool: | |||
def _is_umo_match(self, p1: str, p2: str) -> bool: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The method _is_umo_match
is now an instance method (with self
parameter) but it doesn't use self
anywhere in its implementation. This should either be a static method or class method since it doesn't access instance state.
def _is_umo_match(self, p1: str, p2: str) -> bool: | |
@staticmethod | |
def _is_umo_match(p1: str, p2: str) -> bool: |
Copilot uses AI. Check for mistakes.
* refactor: 重构配置文件管理,以支持更灵活的、基于 umo part 的配置文件隔离 * Refactor: 重构配置前端页面,新增数个配置项 (#2331) * refactor: 重构配置前端页面,新增数个配置项 * feat: 完善多配置文件结构 * perf: 系统配置入口 * fix: normal config item list not display * fix: 修复 axios 请求中的上下文引用问题
此更改优化了配置项的显示,让配置更加清晰明了。
Work in progess, 将会先合并到
refactor-multi-config-file
分支再合并到releases/4.0.0
分支。Check
requirements.txt
和pyproject.toml
文件相应位置。