Skip to content

Python: Add Function Approval UI to DevUI - #1401

Merged
Victor Dibia (victordibia) merged 6 commits into
microsoft:mainfrom
victordibia:devui_approval
Oct 15, 2025
Merged

Python: Add Function Approval UI to DevUI#1401
Victor Dibia (victordibia) merged 6 commits into
microsoft:mainfrom
victordibia:devui_approval

Conversation

@victordibia

@victordibia Victor Dibia (victordibia) commented Oct 10, 2025

Copy link
Copy Markdown
Contributor

Motivation and Context

Add a helpful UI for function approval flow in DevUI and other fixes

Performance & Architecture:

  • Implement lazy loading for entity discovery - entities loaded on-demand instead of at startup
  • Add hot reload capability for development workflow via new reload endpoint
  • Reduce startup time and memory footprint by deferring module imports

Security Enhancements:

  • Remove remote entity loading capabilities (POST /v1/entities/add, DELETE endpoints)
  • DevUI now strictly local development tool - no remote code execution
  • Add explicit security documentation and best practices in README

Frontend Improvements:

  • Migrate to Zustand for centralized state management (replacing prop drilling)
  • Add lightweight zero-dependency markdown renderer with code block copy support
  • Improve gallery UX with setup instructions modal instead of direct URL loading
  • Enhanced message UI with copy functionality and better token usage display

Testing & Quality:

  • Expand test coverage for lazy loading, type detection, and cache invalidation
  • Add comprehensive tests for new behaviors (+231 lines of test code)
  • Improve type safety and documentation throughout

Breaking Changes:

  • Remote entity loading via URLs is no longer supported
  • Entities must be loaded from local filesystem only
image

Description

Contribution Checklist

  • The code builds clean without any errors or warnings
  • The PR follows the Contribution Guidelines
  • All unit tests pass, and I have added new tests where possible
  • Is this a breaking change? If yes, add "[BREAKING]" prefix to the title of the PR.

@markwallace-microsoft Mark Wallace (markwallace-microsoft) added the python Usage: [Issues, PRs], Target: Python label Oct 10, 2025
@markwallace-microsoft

Mark Wallace (markwallace-microsoft) commented Oct 10, 2025

Copy link
Copy Markdown
Contributor

Python Test Coverage

Python Test Coverage Report •
FileStmtsMissCoverMissing
TOTAL10361170683% 
report-only-changed-files is enabled. No files were changed during this commit :)

Python Unit Test Overview

Tests Skipped Failures Errors Time
1276 98 💤 0 ❌ 0 🔥 27.954s ⏱️

…ty and state management

Major architectural improvements to DevUI for better performance, security, and developer experience:

Performance & Architecture:
- Implement lazy loading for entity discovery - entities loaded on-demand instead of at startup
- Add hot reload capability for development workflow via new reload endpoint
- Reduce startup time and memory footprint by deferring module imports

Security Enhancements:
- Remove remote entity loading capabilities (POST /v1/entities/add, DELETE endpoints)
- DevUI now strictly local development tool - no remote code execution
- Add explicit security documentation and best practices in README

Frontend Improvements:
- Migrate to Zustand for centralized state management (replacing prop drilling)
- Add lightweight zero-dependency markdown renderer with code block copy support
- Improve gallery UX with setup instructions modal instead of direct URL loading
- Enhanced message UI with copy functionality and better token usage display

Testing & Quality:
- Expand test coverage for lazy loading, type detection, and cache invalidation
- Add comprehensive tests for new behaviors (+231 lines of test code)
- Improve type safety and documentation throughout

Breaking Changes:
- Remote entity loading via URLs is no longer supported
- Entities must be loaded from local filesystem only
@markwallace-microsoft Mark Wallace (markwallace-microsoft) added the documentation Usage: [Issues, PRs], Target: documentation in the code base and learn docs label Oct 15, 2025
@victordibia
Victor Dibia (victordibia) marked this pull request as ready for review October 15, 2025 20:25
Copilot AI review requested due to automatic review settings October 15, 2025 20:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a comprehensive Function Approval UI to DevUI and implements numerous architectural improvements for better performance, security, and developer experience.

Key changes include:

  • Implement lazy loading for entity discovery to reduce startup time and memory usage
  • Add hot reload capability for development workflow
  • Remove remote entity loading capabilities for enhanced security
  • Migrate frontend to Zustand for centralized state management
  • Add lightweight markdown renderer with code block copy support

Reviewed Changes

Copilot reviewed 35 out of 38 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
python/packages/devui/tests/test_execution.py Updates test assertions to support "unknown" entity type during discovery phase
python/packages/devui/tests/test_discovery.py Adds comprehensive tests for lazy loading, type detection, and hot reload functionality
python/packages/devui/frontend/vite.config.ts Removes commented build optimization settings
python/packages/devui/frontend/src/types/openai.ts Reorganizes event type definitions and adds turn separator for UI grouping
python/packages/devui/frontend/src/stores/devuiStore.ts Implements centralized Zustand store for unified state management
python/packages/devui/frontend/src/components/ui/markdown-renderer.tsx Adds zero-dependency markdown renderer with code block copy functionality
python/packages/devui/frontend/src/components/layout/settings-modal.tsx Reorders tabs to prioritize Settings over About
python/packages/devui/frontend/src/components/layout/entity-selector.tsx Updates to show lazy loading indicators and removes remote entity management
python/packages/devui/frontend/src/components/layout/deployment-modal.tsx Adds comprehensive deployment guide with Docker and Azure instructions
python/packages/devui/frontend/src/components/features/agent/agent-view.tsx Migrates to Zustand store and adds message copy functionality

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread python/packages/devui/tests/test_execution.py Outdated
Comment thread python/packages/devui/frontend/src/stores/devuiStore.ts
Comment thread python/packages/devui/frontend/src/components/layout/deployment-modal.tsx Outdated
Comment thread python/packages/devui/agent_framework_devui/_discovery.py
@victordibia
Victor Dibia (victordibia) added this pull request to the merge queue Oct 15, 2025
Merged via the queue into microsoft:main with commit b64358d Oct 15, 2025
21 checks passed
Reuben Bond (ReubenBond) pushed a commit to ReubenBond/agent-framework that referenced this pull request Oct 28, 2025
* ensure function aproval is parsed correctly

* udpate ui, add deployment guide button, other debug panel fixes

* feat(devui): Implement lazy loading architecture with enhanced security and state management

Major architectural improvements to DevUI for better performance, security, and developer experience:

Performance & Architecture:
- Implement lazy loading for entity discovery - entities loaded on-demand instead of at startup
- Add hot reload capability for development workflow via new reload endpoint
- Reduce startup time and memory footprint by deferring module imports

Security Enhancements:
- Remove remote entity loading capabilities (POST /v1/entities/add, DELETE endpoints)
- DevUI now strictly local development tool - no remote code execution
- Add explicit security documentation and best practices in README

Frontend Improvements:
- Migrate to Zustand for centralized state management (replacing prop drilling)
- Add lightweight zero-dependency markdown renderer with code block copy support
- Improve gallery UX with setup instructions modal instead of direct URL loading
- Enhanced message UI with copy functionality and better token usage display

Testing & Quality:
- Expand test coverage for lazy loading, type detection, and cache invalidation
- Add comprehensive tests for new behaviors (+231 lines of test code)
- Improve type safety and documentation throughout

Breaking Changes:
- Remote entity loading via URLs is no longer supported
- Entities must be loaded from local filesystem only

* update ui issues, uupdate test descripion
Aris Nguyen (arisng) pushed a commit to arisng/agent-framework that referenced this pull request Feb 2, 2026
* ensure function aproval is parsed correctly

* udpate ui, add deployment guide button, other debug panel fixes

* feat(devui): Implement lazy loading architecture with enhanced security and state management

Major architectural improvements to DevUI for better performance, security, and developer experience:

Performance & Architecture:
- Implement lazy loading for entity discovery - entities loaded on-demand instead of at startup
- Add hot reload capability for development workflow via new reload endpoint
- Reduce startup time and memory footprint by deferring module imports

Security Enhancements:
- Remove remote entity loading capabilities (POST /v1/entities/add, DELETE endpoints)
- DevUI now strictly local development tool - no remote code execution
- Add explicit security documentation and best practices in README

Frontend Improvements:
- Migrate to Zustand for centralized state management (replacing prop drilling)
- Add lightweight zero-dependency markdown renderer with code block copy support
- Improve gallery UX with setup instructions modal instead of direct URL loading
- Enhanced message UI with copy functionality and better token usage display

Testing & Quality:
- Expand test coverage for lazy loading, type detection, and cache invalidation
- Add comprehensive tests for new behaviors (+231 lines of test code)
- Improve type safety and documentation throughout

Breaking Changes:
- Remote entity loading via URLs is no longer supported
- Entities must be loaded from local filesystem only

* update ui issues, uupdate test descripion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Usage: [Issues, PRs], Target: documentation in the code base and learn docs python Usage: [Issues, PRs], Target: Python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants