unbridled-41 opened a new issue, #5943:
URL: https://github.com/apache/rocketmq-dashboard/issues/5943

   ### Studio Version
   branch: `rocketmq-studio` @ `7e7aa344` (the revision verified; the branch is 
based on it)
   deployed as: not required to reproduce
   
   ### Runtime Environment
   
   Reproduced with the frontend tests (`cd web && npx vitest run 
src/pages/ai/components/__tests__/Composer.test.tsx 
src/pages/ai/__tests__/AiPage.test.tsx`).
   
   ### Connected RocketMQ Cluster
   
   Not involved.
   
   ### Describe the Bug
   
   `GET /api/ai/agent-capabilities` answers five flags and documents why:
   
   ```java
   /** all five fields are required booleans, never null, so the UI can grey 
out engines and tool tiers
    * that are absent instead of guessing */
   // mcpEnabled / l3ToolsAllowed "exist so the UI can explain a refusal 
instead of showing a mystery
   // error ... facts the composer has no other way to learn"
   ```
   
   Only `rmqctlAvailable` was consumed (`grep -rn claudeAvailable web/src` -> 
the type declaration only). So:
   
   - the composer offered "Claude Code" and "Qoder" even when the server's 
probe had found the binary missing, and the run then failed with a provider 
error;
   - a server with `spring.ai.mcp.server.enabled=false` (every tool call 
refused) or `studio.ai.allow-l3-tools=false` (destructive tools refused) 
refused the call with no notice anywhere - exactly the mystery error those 
fields were added to prevent, while the composer's quick actions include 
destructive operations.
   
   ### Steps to Reproduce
   
   1. Run with `studio.ai.allow-l3-tools=false` (or without the CLI binary) and 
open the AI page.
   2. The composer offers the unavailable engine and shows no notice; the 
refusal surfaces only as a run error.
   
   ### What Did You Expect to See?
   
   Engines the server probed as absent are not selectable, and a disabled tool 
tier is explained where the operator types.
   
   ### What Did You See Instead?
   
   Both flags were silently dropped by the page.
   
   ### Evidence
   
   - `server/.../ops/ai/conversation/vo/AiAgentCapabilitiesVO.java`, 
`server/.../ops/ai/conversation/AgentCapabilityProbe.java`, 
`server/.../ops/ai/conversation/AiConversationController.java`.
   - `web/src/pages/ai/hooks/useAgentCapabilities.ts`, 
`web/src/pages/ai/components/Composer.tsx`, 
`web/src/pages/ai/components/RuntimeNotices.tsx`, `web/src/pages/ai/index.tsx`.
   - `cd web && npx vitest run 
src/pages/ai/components/__tests__/Composer.test.tsx -t 'probed as absent'` - 
fails before the fix.
   
   ### Impact
   
   A user selects an engine that cannot start, or issues a destructive request 
that is refused, with nothing in the UI explaining either.
   
   ### Acceptance Criteria
   
   - The probe's flags drive the engine options and the notices, an 
unprobed/unknown capability keeps today's permissive behaviour, and each state 
has a regression test.
   
   **Corresponding PR:** #ISSUEPR#
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to