mirror of
https://github.com/pchuan98/codex.git
synced 2026-07-01 00:31:56 +08:00
[codex] [4/4] Simplify recommended plugin install schema (#28403)
## Summary - Simplify recommendation-context `request_plugin_install` arguments to `plugin_id` and `suggest_reason`. - Derive plugin type and install action from the matched candidate while preserving Codex-owned elicitation metadata. - Keep the legacy list-backed schema unchanged and accept resumed calls that still use `tool_id`. ## Stack - #28399 - #28400 - #27704 - This PR ## Validation - `just test -p codex-tools -p codex-core request_plugin_install` (25 passed) - `just fix -p codex-tools -p codex-core` - `just fmt` - `git diff --check`
This commit is contained in:
@@ -230,9 +230,7 @@ async fn endpoint_mode_injects_candidates_hides_list_and_rejects_invented_ids()
|
||||
call_id,
|
||||
REQUEST_PLUGIN_INSTALL_TOOL_NAME,
|
||||
&serde_json::to_string(&json!({
|
||||
"tool_type": "plugin",
|
||||
"action_type": "install",
|
||||
"tool_id": "invented@openai-curated-remote",
|
||||
"plugin_id": "invented@openai-curated-remote",
|
||||
"suggest_reason": "Try this"
|
||||
}))?,
|
||||
),
|
||||
@@ -312,9 +310,7 @@ async fn endpoint_recommendation_adds_install_identity_only_to_elicitation_metad
|
||||
call_id,
|
||||
REQUEST_PLUGIN_INSTALL_TOOL_NAME,
|
||||
&serde_json::to_string(&json!({
|
||||
"tool_type": "plugin",
|
||||
"action_type": "install",
|
||||
"tool_id": "github@openai-curated-remote",
|
||||
"plugin_id": "github@openai-curated-remote",
|
||||
"suggest_reason": "Use GitHub for this request"
|
||||
}))?,
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user