feat(studio): Add multiple choice UI for the Nemo Agent - #1001
Conversation
Signed-off-by: Henrique Tolentino <htolentino@nvidia.com>
Signed-off-by: Henrique Tolentino <htolentino@nvidia.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe NeMo agent now routes finite-choice clarification through Studio’s selectable picker, adds a validated ChangesAgent tooling updates
Sequence Diagram(s)sequenceDiagram
participant User
participant NeMoAgent
participant ask_user_question
participant Studio
User->>NeMoAgent: Request requiring finite-choice clarification
NeMoAgent->>ask_user_question: questions and studio_session_id
ask_user_question->>Studio: approval_prompt with AskUserQuestion
Studio-->>User: Selectable options picker
User-->>Studio: Selection or decline
Studio-->>ask_user_question: Approval result
ask_user_question-->>NeMoAgent: Updated selections or decline message
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
|
@CodeRabbit review it now |
|
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@agents/nemo-agent-local/src/nemo_agent/register.py`:
- Around line 568-608: Remove the framework-level `@tool` implementation of
ask_user_question and integrate this question flow through the existing NVIDIA
NAT-wrapped LangGraph integration. Reuse the repository’s established NAT
integration patterns and registration mechanisms rather than adding new
LangChain or other agent-framework tool code, while preserving the JSON
validation and user-decline behavior.
- Around line 597-605: Validate the parsed value in the AskUserQuestion flow
after json.loads and before _call_studio_tool: require a non-empty list whose
elements are question objects, returning the documented input error for objects,
scalars, empty arrays, or invalid elements. Preserve the existing JSON parsing
error handling and only call Studio for valid question arrays.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 2a5f5692-182c-4714-8adc-f7c7af1c9176
📒 Files selected for processing (5)
agents/nemo-agent-local/src/nemo_agent/register.pyagents/nemo-agent-local/tests/test_nemo_agent.pyservices/studio/src/nmp/studio/coding_agent_mcp_tools.pyservices/studio/src/nmp/studio/coding_agents.pyservices/studio/tests/unit/test_coding_agents.py
|
Signed-off-by: Henrique Tolentino <htolentino@nvidia.com>
Summary by CodeRabbit