Skip to content

Add MCP provider feature discovery#910

Merged
boudra merged 3 commits into
getpaseo:mainfrom
kongjiadongyuan:codex/orchestration-feature-discovery
May 13, 2026
Merged

Add MCP provider feature discovery#910
boudra merged 3 commits into
getpaseo:mainfrom
kongjiadongyuan:codex/orchestration-feature-discovery

Conversation

@kongjiadongyuan
Copy link
Copy Markdown
Contributor

@kongjiadongyuan kongjiadongyuan commented May 11, 2026

Summary

Follow-up to #835 and #909: add provider feature discovery to the orchestration MCP surface.

  • add list_provider_features for draft agent configurations
  • reuse the existing AgentManager.listDraftFeatures plumbing already used by the app/WebSocket feature picker
  • return provider-owned AgentFeature[] values so orchestrators can discover feature IDs like Codex fast_mode before setting them
  • update the MCP docs and Paseo skill guidance to say agents should query features instead of guessing feature IDs

This complements #909: #909 lets orchestrators set provider features, and this PR lets them discover which features are valid for a draft agent config.

Design note

I kept discovery as a separate MCP tool because it mirrors the existing app/WebSocket feature picker path and avoids overloading provider/model listing. The caller passes a draft config (provider, cwd, optional model/modeId/thinkingOptionId/featureValues) and gets back the provider-owned AgentFeature[] shape.

Tests

  • npx vitest run packages/server/src/server/agent/mcp-server.test.ts --bail=1
  • npx vitest run packages/server/src/server/agent/mcp-parity.e2e.test.ts -t "list_provider_features" --bail=1
  • npm run lint
  • npm run typecheck
  • npm run format:check

@kongjiadongyuan
Copy link
Copy Markdown
Contributor Author

Added real MCP HTTP end-to-end coverage for provider feature discovery. The new test calls list_provider_features through the test daemon via StreamableHTTP MCP client and verifies the provider feature value comes back from a draft session; it is not a direct registered-tool handler test.\n\nWhile making the MCP parity e2e run cleanly, I also fixed/covered stale worktree list cache behavior after MCP create_worktree/archive_worktree.\n\nVerification run locally:\n- npx vitest run packages/server/src/server/agent/mcp-server.test.ts --bail=1\n- npx vitest run packages/server/src/server/agent/mcp-parity.e2e.test.ts --bail=1\n- npm run lint\n- npm run typecheck\n- npm run format:check\n\nCommit: 136a4f8

@kongjiadongyuan
Copy link
Copy Markdown
Contributor Author

Follow-up cleanup: I moved the unrelated MCP worktree list-cache fix into the dedicated small PR #911. This PR now stays focused on provider feature discovery.\n\nRelevant verification after cleanup:\n- npx vitest run packages/server/src/server/agent/mcp-server.test.ts --bail=1\n- npx vitest run packages/server/src/server/agent/mcp-parity.e2e.test.ts -t "list_provider_features" --bail=1\n- npm run lint\n- npm run typecheck\n- npm run format:check

@kongjiadongyuan
Copy link
Copy Markdown
Contributor Author

Small design note for review: I kept discovery as a separate list_provider_features MCP tool because it mirrors the existing app/WebSocket feature picker path (AgentManager.listDraftFeatures) and keeps provider/model listing stable. The caller provides a draft config (provider, cwd, optional model/modeId/thinkingOptionId/featureValues) and gets back the provider-owned AgentFeature[] shape, so orchestrators can discover IDs like Codex fast_mode instead of guessing them.

This is meant to complement #909: #909 sets provider features, this PR discovers which ones are valid for a draft agent config.

@kongjiadongyuan kongjiadongyuan changed the title Expose provider feature discovery through MCP Add MCP provider feature discovery May 11, 2026
@boudra boudra force-pushed the codex/orchestration-feature-discovery branch from 75af1f2 to 41df6f1 Compare May 13, 2026 12:08
@boudra boudra closed this May 13, 2026
@boudra boudra reopened this May 13, 2026
@boudra boudra closed this May 13, 2026
@boudra boudra reopened this May 13, 2026
@boudra boudra force-pushed the codex/orchestration-feature-discovery branch from 4aa1cd7 to eb3a336 Compare May 13, 2026 12:10
@boudra boudra closed this May 13, 2026
@boudra boudra reopened this May 13, 2026
@boudra boudra closed this May 13, 2026
@boudra boudra reopened this May 13, 2026
@boudra boudra merged commit c6534b3 into getpaseo:main May 13, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants