From 4cde2f7c67ee8402f1eb8e995d46eb7d0a9c4717 Mon Sep 17 00:00:00 2001 From: zhoujie <929834232@qq.com> Date: Tue, 24 Feb 2026 21:04:33 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat(config):=20=E6=96=B0=E5=A2=9E?= =?UTF-8?q?=E5=85=A8=E5=B1=80=E8=AE=BE=E7=BD=AE=E8=87=AA=E5=8A=A8=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增图片生成参数自动保存【quality_mode、sd_steps、sd_cfg_scale、sd_negative_prompt】 - 新增自动运营调度参数自动保存【sched_comment_on、sched_like_on、sched_fav_on、sched_reply_on、sched_publish_on】 - 新增智能学习参数自动保存【learn_interval】 - 新增内容排期参数自动保存【queue_gen_count】 - 优化人设切换逻辑,同时保存到配置并更新队列主题池 - 新增页面加载时自动恢复全局设置功能 📝 docs(config): 更新配置管理文档 - 在config_manager.py中新增默认配置项 - 在main.py中实现启动时自动加载全局设置 - 更新配置保存测试脚本_test_config_save.py 📦 build(ui): 优化用户界面交互 - 图片生成参数变更时自动保存到配置 - 自动运营参数变更时自动保存到配置 - 智能学习参数变更时自动保存到配置 - 内容排期参数变更时自动保存到配置 - 修复人设切换时队列主题池未更新的问题 🐛 fix(queue): 修复发布队列图片显示问题 - 在publish_queue.py中新增图片预览功能 - 支持将图片转换为base64编码嵌入markdown显示 - 显示图片文件大小和状态信息 --- .github/prompts/opsx-apply.prompt.md | 149 +++++ .github/prompts/opsx-archive.prompt.md | 154 +++++ .github/prompts/opsx-bulk-archive.prompt.md | 239 ++++++++ .github/prompts/opsx-continue.prompt.md | 111 ++++ .github/prompts/opsx-explore.prompt.md | 171 ++++++ .github/prompts/opsx-ff.prompt.md | 91 +++ .github/prompts/opsx-new.prompt.md | 66 +++ .github/prompts/opsx-onboard.prompt.md | 522 +++++++++++++++++ .github/prompts/opsx-sync.prompt.md | 131 +++++ .github/prompts/opsx-verify.prompt.md | 161 ++++++ .github/skills/openspec-apply-change/SKILL.md | 156 ++++++ .../skills/openspec-archive-change/SKILL.md | 114 ++++ .../openspec-bulk-archive-change/SKILL.md | 246 ++++++++ .../skills/openspec-continue-change/SKILL.md | 118 ++++ .github/skills/openspec-explore/SKILL.md | 290 ++++++++++ .github/skills/openspec-ff-change/SKILL.md | 101 ++++ .github/skills/openspec-new-change/SKILL.md | 74 +++ .github/skills/openspec-onboard/SKILL.md | 529 ++++++++++++++++++ .github/skills/openspec-sync-specs/SKILL.md | 138 +++++ .../skills/openspec-verify-change/SKILL.md | 168 ++++++ _test_config_save.py | 38 ++ config.json | 40 +- config_manager.py | 33 ++ main.py | 236 ++++++-- openspec/config.yaml | 20 + publish_queue.py | 46 ++ 26 files changed, 4096 insertions(+), 46 deletions(-) create mode 100644 .github/prompts/opsx-apply.prompt.md create mode 100644 .github/prompts/opsx-archive.prompt.md create mode 100644 .github/prompts/opsx-bulk-archive.prompt.md create mode 100644 .github/prompts/opsx-continue.prompt.md create mode 100644 .github/prompts/opsx-explore.prompt.md create mode 100644 .github/prompts/opsx-ff.prompt.md create mode 100644 .github/prompts/opsx-new.prompt.md create mode 100644 .github/prompts/opsx-onboard.prompt.md create mode 100644 .github/prompts/opsx-sync.prompt.md create mode 100644 .github/prompts/opsx-verify.prompt.md create mode 100644 .github/skills/openspec-apply-change/SKILL.md create mode 100644 .github/skills/openspec-archive-change/SKILL.md create mode 100644 .github/skills/openspec-bulk-archive-change/SKILL.md create mode 100644 .github/skills/openspec-continue-change/SKILL.md create mode 100644 .github/skills/openspec-explore/SKILL.md create mode 100644 .github/skills/openspec-ff-change/SKILL.md create mode 100644 .github/skills/openspec-new-change/SKILL.md create mode 100644 .github/skills/openspec-onboard/SKILL.md create mode 100644 .github/skills/openspec-sync-specs/SKILL.md create mode 100644 .github/skills/openspec-verify-change/SKILL.md create mode 100644 _test_config_save.py create mode 100644 openspec/config.yaml diff --git a/.github/prompts/opsx-apply.prompt.md b/.github/prompts/opsx-apply.prompt.md new file mode 100644 index 0000000..494e10e --- /dev/null +++ b/.github/prompts/opsx-apply.prompt.md @@ -0,0 +1,149 @@ +--- +description: Implement tasks from an OpenSpec change (Experimental) +--- + +Implement tasks from an OpenSpec change. + +**Input**: Optionally specify a change name (e.g., `/opsx:apply add-auth`). If omitted, check if it can be inferred from conversation context. If vague or ambiguous you MUST prompt for available changes. + +**Steps** + +1. **Select the change** + + If a name is provided, use it. Otherwise: + - Infer from conversation context if the user mentioned a change + - Auto-select if only one active change exists + - If ambiguous, run `openspec list --json` to get available changes and use the **AskUserQuestion tool** to let the user select + + Always announce: "Using change: " and how to override (e.g., `/opsx:apply `). + +2. **Check status to understand the schema** + ```bash + openspec status --change "" --json + ``` + Parse the JSON to understand: + - `schemaName`: The workflow being used (e.g., "spec-driven") + - Which artifact contains the tasks (typically "tasks" for spec-driven, check status for others) + +3. **Get apply instructions** + + ```bash + openspec instructions apply --change "" --json + ``` + + This returns: + - Context file paths (varies by schema) + - Progress (total, complete, remaining) + - Task list with status + - Dynamic instruction based on current state + + **Handle states:** + - If `state: "blocked"` (missing artifacts): show message, suggest using `/opsx:continue` + - If `state: "all_done"`: congratulate, suggest archive + - Otherwise: proceed to implementation + +4. **Read context files** + + Read the files listed in `contextFiles` from the apply instructions output. + The files depend on the schema being used: + - **spec-driven**: proposal, specs, design, tasks + - Other schemas: follow the contextFiles from CLI output + +5. **Show current progress** + + Display: + - Schema being used + - Progress: "N/M tasks complete" + - Remaining tasks overview + - Dynamic instruction from CLI + +6. **Implement tasks (loop until done or blocked)** + + For each pending task: + - Show which task is being worked on + - Make the code changes required + - Keep changes minimal and focused + - Mark task complete in the tasks file: `- [ ]` → `- [x]` + - Continue to next task + + **Pause if:** + - Task is unclear → ask for clarification + - Implementation reveals a design issue → suggest updating artifacts + - Error or blocker encountered → report and wait for guidance + - User interrupts + +7. **On completion or pause, show status** + + Display: + - Tasks completed this session + - Overall progress: "N/M tasks complete" + - If all done: suggest archive + - If paused: explain why and wait for guidance + +**Output During Implementation** + +``` +## Implementing: (schema: ) + +Working on task 3/7: +[...implementation happening...] +✓ Task complete + +Working on task 4/7: +[...implementation happening...] +✓ Task complete +``` + +**Output On Completion** + +``` +## Implementation Complete + +**Change:** +**Schema:** +**Progress:** 7/7 tasks complete ✓ + +### Completed This Session +- [x] Task 1 +- [x] Task 2 +... + +All tasks complete! You can archive this change with `/opsx:archive`. +``` + +**Output On Pause (Issue Encountered)** + +``` +## Implementation Paused + +**Change:** +**Schema:** +**Progress:** 4/7 tasks complete + +### Issue Encountered + + +**Options:** +1.