Skip to content

Conversation

@Concept-Vi
Copy link

Summary

Adds generic multiselect field type to OAP's x-oap-ui-config system, enabling any agent to use List[str] configuration fields with multiselect UI.

Changes

  • Type Definitions: Add "multiselect" to ConfigurableFieldUIType union and define ConfigurableFieldMultiselectMetadata interface
  • Component: Create MultiselectCombobox component (generalized from AgentsCombobox)
  • Utility: Add deepEqual for array comparison in visible_if conditions
  • Integration: Wire multiselect into ConfigField rendering
  • Tests: Unit tests for component, utility, and visible_if integration
  • Documentation: Usage guide for Python backend and frontend

Testing

  • Unit tests pass (component, utility, visible_if)
  • Integration tests pass
  • E2E manual testing completed
  • Type checking passes
  • Linting passes
  • Build succeeds

Usage Example

output_formats: List[str] = Field(
    default=["markdown", "json"],
    metadata={
        "x_oap_ui_config": {
            "type": "multiselect",
            "options": [
                {"label": "Markdown", "value": "markdown"},
                {"label": "JSON", "value": "json"}
            ]
        }
    }
)

Dependencies

All dependencies already present (Radix UI, cmdk, TypeScript).

Backward Compatibility

Fully backward compatible - existing configs work unchanged.

Estimated Review Time

~30 minutes

Concept-Vi and others added 15 commits November 4, 2025 19:47
Restructures research agent configuration to properly represent 3-agent
architecture (Orchestrator + Research Sub-Agent + Critique Sub-Agent) with
per-agent tool/RAG allocation and customizable prompts.

Backend changes (deepagents-platform):
- Add 15 new config fields for per-agent customization
- Reorganize field groups: Orchestrator (Group 1), Research (Group 2), Critique (Group 3)
- Implement per-agent tool distribution (graph-wide + agent-specific)
- Make sub-agent prompts configurable (previously hardcoded)
- Enable per-agent temperature/max_tokens overrides

Frontend changes (open-agent-platform):
- Restructure Tools tab: 4 sections (graph-wide, orchestrator, research-sub, critique-sub)
- Restructure RAG tab: Same 4-section model
- Update summaries to show all 4 allocation levels
- Color-coded sections: blue (graph-wide), purple (orchestrator), green (research), orange (critique)

Enables template creation with:
- Per-agent prompts (e.g., academic vs news research)
- Per-agent tool allocation (e.g., research gets code tools, critique gets validation tools)
- Per-agent model/temperature tuning

Fixes architecture misunderstanding from previous session where "graph-wide" was
ambiguous - now clearly shows which of 3 agents gets which tools.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
…ebar

Fixes TypeScript errors from incomplete per-agent configuration implementation:

1. Fix config property access (lines 643-648, 1056-1061):
   - orchestrator/research/critique tools: .default → .default.tools
   - orchestrator/research/critique RAG: .default → .default.collections

   These configs now properly access the MCP/RAG object structure returned by
   configSchemaToToolsConfig() instead of treating them as raw arrays.

2. Remove 88 lines of dead code (old agent-specific tools section):
   - Wrapped in `{false && agentToolConfig &&...}`
   - Referenced undefined variables (agentToolConfig, agentEnabledTools)
   - Was marked "OLD Agent-specific tools section - REMOVE THIS"
   - Replaced by new per-agent sections (orchestrator/research/critique)

This completes the per-agent configuration architecture started in commit
5945d48. Build now succeeds with 0 TypeScript errors.

Related backend fix changes config types from "json" to "mcp"/"rag".

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
UI component additions:
- Added 3 ToolGroupSection components for orchestrator/research/critique tools
- Added 3 ConfigFieldRAG components for orchestrator/research/critique RAG
- Color-coded badges: purple (orchestrator), green (research), orange (critique)

Config access changes (lines 643-648, 1056-1061):
- Changed .default → .default.tools for tool configs
- Changed .default → .default.collections for RAG configs
- Aligns with MCPConfig/RagConfig object structure from backend

Dead code removal:
- Removed 88 lines of disabled code (wrapped in {false && ...})
- Section referenced undefined variables agentToolConfig, agentEnabledTools
- Had comment "OLD Agent-specific tools section - REMOVE THIS"

Description text updates:
- Removed "Configure in General tab" from 6 section descriptions
- Configs now only appear in Tools/RAG tabs, not General tab

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
Prevent worktree contents from being tracked in repository.
Required before creating feature/multiselect-field-type worktree.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
Add 'multiselect' to ConfigurableFieldUIType union and define
ConfigurableFieldMultiselectMetadata interface for array field support.
Generalized from AgentsCombobox. Supports both single and multiple
selection with any option list. Removes Agent-specific logic.
Enables visible_if conditions to work with array values using
deep equality instead of reference equality.
Add rendering case for multiselect type and update visible_if
to use deep equality for array value comparison.
Cover single/multiple selection, placeholder display, deselection
prevention, and selection count display.
Cover primitive values, arrays, null/undefined, empty arrays,
and object reference equality.
Verify deep equality comparison works correctly for array-valued
visible_if conditions.
Document manual testing of multiselect rendering, interaction,
and payload structure.
Make component available through @/components/ui barrel export.
Document Python usage, properties, rendering behavior, visible_if
support, and limitations.
- Update yarn.lock after build process
- Add implementation plan for multiselect field type feature
- Provides comprehensive documentation of the implementation approach

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
@vercel
Copy link

vercel bot commented Nov 12, 2025

@Concept-Vi is attempting to deploy a commit to the LangChain Team on Vercel.

A member of the Team first needs to authorize it.

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.

1 participant