19 Commits
Author SHA1 Message Date
shuiyu1123 b8faaae0c6 release: v5.4.1 2026-06-19 00:30:15 +08:00
shuiyu1123 bac5ea01a9 feat: 统一错误处理 - ToolResult 类
- 新增 xcli_core/tool_result.py: ToolResult + ErrorCode
- unified_tool_manager: execute/mcp_call 返回 ToolResult
- cmd_executor: 所有返回改为 ToolResult
- file_manager: 所有返回改为 ToolResult
- 兼容旧接口: execute_dict() 返回 dict, handler 可返回 str 或 ToolResult
2026-06-19 00:26:49 +08:00
shuiyu1123 161ab9d3a8 feat: MCP stdio server + TUI回车发送 + 子Agent无限制 + 安全引擎优化 + diff弹窗绿红背景
- 新增 mcp_server.py: 标准 MCP stdio 传输层入口
- TUI: 回车发送消息,Shift+回车换行 (SendTextArea子类)
- 子Agent: 移除 max_steps=20 限制
- 安全引擎: 移除 ALWAYS_CONFIRM 关键词强制拦截
- code_editor: diff弹窗绿底(+)/红底(-)背景色
2026-06-19 00:10:27 +08:00
shuiyu1123 78b74d1bb1 feat: 新增 7 个实用插件
- json_toolkit: JSON 工具箱(格式化/压缩/校验/路径查询/差异比较/Schema推断)
- snippet_manager: 代码片段管理器(保存/搜索/分类/标签/导入导出)
- regex_tester: 正则表达式测试器(匹配/提取/替换/解释/常用模式库/性能测试)
- id_generator: UUID/ID 生成器(UUID v1/v4/v5/NanoID/短ID/雪花ID/ULID/自定义模板)
- color_picker: 颜色工具(HEX/RGB/HSL/HSV/CMYK转换/WCAG对比度/调色板/色盲模拟)
- bookmark_manager: 书签管理器(分类/标签/搜索/导入导出/可访问性检查)
- markdown_tool: Markdown 工具(TOC/统计/表格生成/待办提取/语法检查/字数统计)

所有插件均支持 Plugin/Liugin 双协议和 MCP 定义。
2026-04-30 03:01:11 +08:00
xiaoli-cli-bot 0d27f2b774 feat: add /manual command + fix cross-engine command routing
- /manual → switch to manual engine (CLI + TUI)
- /manual status → run manual engine sub-commands
- /manual restart → restart manual terminal
- /engine.manual status → now works from any engine (not just manual)
- Fixed handle_engine_command to route to correct engine by name
2026-04-29 20:04:40 +08:00
xiaoli-cli-bot 03685ab5e7 fix: WebUI engine switch now updates UI and shows errors 2026-04-29 19:57:17 +08:00
xiaoli-cli-bot 7a72a5c69e fix: Ollama model validation, TUI CSS, WebUI overhaul
1. Ollama: validate model is configured before API call, show helpful error
2. TUI: remove unsupported scroll-behavior CSS property
3. WebUI server: add full tool calling loop (FC + JSON action)
4. WebUI HTML: complete redesign
   - Modern dark theme with better typography
   - Markdown rendering via marked.js
   - Tool call/result visualization with colored cards
   - Dynamic sidebar (engines + tools from server)
   - Better input area with gradient send button
   - Responsive layout
2026-04-29 19:51:42 +08:00
xiaoli-cli-bot baa2cbc49a feat: diff display mode - popup or inline (SSH compatible)
- Startup prompt asks user to choose popup or inline diff mode
- Added inline diff display in main terminal with colored output
- Green for added lines, red for deleted lines (both modes)
- TUI mode uses Rich markup, CLI mode uses ANSI colors
- New commands: diff_popup popup / diff_popup inline
- Default: inline mode (SSH compatible)
2026-04-29 19:40:07 +08:00
xiaoli-cli-bot f41d5d5a7c fix: remove unsupported @keyframes from Textual CSS
Textual CSS parser does not support @keyframes syntax (it's a Web CSS feature).
These keyframes were unused - all animations are implemented via Python's
set_interval() and animate() methods. Removing them fixes the stylesheet
parse error that prevented TUI mode from starting.
2026-04-29 19:28:53 +08:00
shuiyu1123 da9cfb6c9d chore: 清理仓库,删除不需要的文件
删除内容:
- xiaoli-cli-v5.1.2.zip(旧版本构建产物)
- compare.html / webui-analysis.html(AI编程助手横评页面)
- scheduler_tasks.json(空运行时数据)
- skills/file-manager/scripts/test.txt / test_multi.txt(测试数据)
- .gitee/pipeline.yml / .github/workflows/ci.yml(CI配置)
2026-04-29 18:34:20 +08:00
shuiyu1123 62aa5ed128 docs: v5.1.2 竞品实力对比分析页面 2026-04-27 01:14:49 +08:00
shuiyu1123 9048b0e813 feat: 自动语法检查 + Diff弹窗 + Web UI + 默认模型更新
- 自动语法检查: 编辑操作完成后自动检查代码语法(11种语言)
- Diff弹窗: 编辑后弹出新窗口显示修改前后对比(可开关)
- 主动语法检查: 新增 syntax_check/check 操作
- Web UI: 纯静态HTML界面(对话/编辑器/文件浏览/状态面板)
- 默认模型: Ollama默认从qwen2.5更新为gemma4:31b
- 更新README/HELP/CHANGELOG文档
2026-04-27 01:08:27 +08:00
shuiyu1123 6de5c6f202 feat: Function Calling 兼容
新增 xcli_core/fc_tools.py:
- MCP 定义 → OpenAI FC 格式转换
- FC 响应解析 (tool_calls 提取)
- 自动收集所有插件 FC 定义
- 400 错误自动降级为普通模式

引擎层改动 (openai_engine + ollama_engine):
- generate_response 新增 tools 参数
- 请求体自动注入 tools/tool_choice
- 响应检测 tool_calls 并返回 FC 标记
- 对话历史支持 tool 角色消息和 assistant.tool_calls
- _build_messages_with_history 兼容 FC 消息格式

cli_core.py 集成:
- _handle_fc_response: FC 响应 → 工具执行 → 结果回传
- _execute_tool_by_name: FC 调用路径的安全检查+工具分发
- process_conversation 循环自动处理 FC 工具调用
- TUI/CLI 双模式 FC 支持
2026-04-27 00:29:34 +08:00
shuiyu1123 15e35ca8ad feat: 持久化记忆系统
新增 xcli_core/memory.py (20KB):
- MEMORY.md: 长期记忆,AI 可追加备忘
- memory/YYYY-MM-DD.md: 每日日记,AI 可写观察日记
- chat_history/: 自动保存聊天记录 (JSON)
- 全局关键词搜索 (日记+记忆+聊天记录)
- 上下文自动压缩 (超50条时AI摘要)
- /memory 命令入口

cli_core.py 集成:
- process_conversation 结束后自动保存聊天记录
- 超过阈值自动压缩上下文 (保留最近10条+摘要)
- 系统提示词自动注入记忆上下文 (MEMORY.md+今日日记)
- /memory 帮助文本
2026-04-27 00:23:52 +08:00
shuiyu1123 11afacb6e9 fix: ESC 跨平台取消 AI 响应
- 重写 _generate_response_with_animation
- generate_response 移入独立线程,ESC 后可立即返回
- Linux/macOS: 使用 tty.setcbreak + select 非阻塞读取
- Windows: 保留 msvcrt 检测
- 三个线程并行: 动画 / ESC检测 / AI响应
- ESC 按下后立即停止动画并返回取消标记
2026-04-27 00:12:03 +08:00
shuiyu1123 4f3a60bf9f feat: 定时任务插件 - AI 可设定定时提醒
- 新增 plugins/scheduler.py 定时任务插件
  - add: 添加定时任务 (支持 30m/2h/14:30/2026-04-28 10:00/r:30m)
  - list: 列出所有任务及剩余时间
  - delete: 取消指定任务
  - clear: 清除已结束任务
- 后台守护线程每秒检查到期任务
- 到期时自动激活 AI 处理提醒 (CLI/TUI 双模式)
- 重复任务 (r: 前缀) 触发后自动重新调度
- JSON 持久化存储 scheduler_tasks.json
- /scheduler 和 /remind 命令入口
2026-04-27 00:06:23 +08:00
shuiyu1123 19f9cf0826 feat: 任务完成时发送系统通知
- 新增 xcli_core/notification.py 跨平台通知模块
  - Windows: win10toast / PowerShell BurntToast / MessageBox
  - macOS: osascript display notification
  - Linux: notify-send / D-Bus
- process_conversation 结束后自动触发通知
- 新增 /notify 命令开关通知 (on/off)
- 通知在后台线程发送,不阻塞主流程
- 防重复通知冷却机制 (2秒)
2026-04-27 00:03:14 +08:00
shuiyu1123 ab0287d186 docs: 移除对标相关描述 2026-04-25 13:28:21 +08:00
shuiyu1123 4b0c739c07 docs: 完善项目文档
- README.md: 重写中文文档,补充特性说明、项目结构、使用指南
- README.en.md: 重写英文文档,与中文版对齐
- CHANGELOG.md: 补充 v5.0.0 更新日志
- CONTRIBUTING.md: 新增贡献指南
- HELP.md: 更新使用指南,适配 v5.0.0
2026-04-25 13:26:05 +08:00