Commit Graph

3 Commits

Author SHA1 Message Date
fmfsaisai
648d26721b feat(ghost): 插件花名册 system 段注入与渐进式发现链 (#2123)
* feat(ghost): align roster summary limit with manifest

Use the plugin-protocol 300-character summary limit for Desktop validation and cindy-tools roster truncation. Include the author-provided recall hint in live ghost_list results, preferring whenToUse over description.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* feat(ghost): add precise ghost_info discovery tool (#2031)

Add the fixed read-only ghost_info tool for targeted plugin detail lookup while keeping ghost_list as the live full inventory.

Depends on feat/roster-desc-max-align for the recall field and shared visibleChipGhosts filtering.

Visibility behavior changes:
- missing or uninstalled targets now take precedence over stale workdir-disable preferences and return GHOST_NOT_FOUND
- account-unavailable targets now use the explicit #907 not-signed-in message
- workdir-disabled plus asleep targets consistently return GHOST_DISABLED_IN_WORKDIR in ghost_call and setup waiter revalidation
- initial, setup, grant, pre-dispatch, post-context, and coordinator waiter checks now share one visibility classifier

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* docs(ghost): align handbook wording with manifest constant

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* docs(ghost): define progressive discovery author contract

Document whenToUse as the scenario-only model discovery field and align the author flow with roster to ghost_info to ghost_call.

Require category-scoped RULES in list_tools(category) details and schema-plus-rules recovery for invalid call_tool arguments.

Depends on feat/ghost-info for the precise discovery step.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): guide missing ghost_info targets

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* feat(ghost): inject roster into harness system prompts

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* test(ghost): cover roster prompt harness injection

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): harden roster prompt serialization

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): wire Pi roster prompt dependency

Declare and forward the existing roster prompt callback so Pi receives the same system-prompt injection as the other harnesses. This closes the pre-existing 73ba2ae03 type/runtime wiring omission.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): escape roster block delimiters

Escape angle brackets in serialized roster records so author-controlled values cannot forge the fixed ghost-roster boundaries. JSON semantics remain unchanged after parsing.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* test(ghost): cover Pi roster prompt assembly

Exercise buildPiAgent's explicit dependency wiring and verify the forwarded roster callback contributes to the composed Pi system prompt.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): fail closed remote roster injection

Remote Claude drops the in-process cindy MCP server and remote Codex only receives an HTTP allowlist that excludes the fixed ghost server. Keep both harnesses from injecting a roster when the session workingDir is remote and local workdir visibility preferences cannot be trusted.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* test(ghost): strengthen roster injection coverage

Lock the sixteen-entry cache budget, pin U+2028/U+2029 folding, and exercise the desktop Pi host through a real PiAgent startSession while mocking only the RPC process and external host dependencies.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* docs(ghost): document progressive discovery design

Add the authoritative design doc for the ghost progressive discovery chain (roster injection, ghost_info routing, runtime visibility gates) and index it from AGENTS.md.

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

* fix(ghost): type ghost_info INTERNAL fallback in wire result

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>

---------

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
2026-08-08 07:25:22 +08:00
Dash
647dd11be0 fix(plugins): 完全访问下自动批准文件交接 (#1417)
* fix(plugins): 完全访问下自动批准文件交接

Signed-off-by: Dash <dashhuang@gmail.com>

* fix(plugins): 兼容旧工具交接并清理失败落盘

Signed-off-by: Dash <dashhuang@gmail.com>

* fix(plugins): 复核保存写入后的路径身份

Signed-off-by: Dash <dashhuang@gmail.com>

---------

Signed-off-by: Dash <dashhuang@gmail.com>
2026-08-03 14:28:50 +08:00
nanaco
40f22f9f55 feat(plugins): 增加对话内通用 Setup Runtime (#329)
* feat(plugins): add conversational setup runtime

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): harden setup authorization flows

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): close setup runtime review gaps

Signed-off-by: nana <823073145@qq.com>

* fix(desktop): close plugin setup transport gaps

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): persist inline node secrets

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): harden setup state reconciliation

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): strip setup diagnostics from remotes

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): harden setup action routing

Signed-off-by: nana <823073145@qq.com>

* docs(plugins): clarify setup readiness contract

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): close setup lifecycle gaps

Signed-off-by: nana <823073145@qq.com>

* fix(plugins): harden setup interaction races

Signed-off-by: nana <823073145@qq.com>

---------

Signed-off-by: nana <823073145@qq.com>
Co-authored-by: nana <823073145@qq.com>
2026-07-25 15:36:38 +08:00