Commit Graph

2 Commits

Author SHA1 Message Date
Devin AI
0b3a5a6c81 Address PR review comments: Add type hints, improve error handling, and optimize code structure
Co-Authored-By: Joe Moura <joao@crewai.com>
2025-03-11 07:45:14 +00:00
Devin AI
570a9b1ba1 Add to_structured_dict method to Crew class with tests
This implements a structured dictionary representation of Crew objects
for frontend-friendly visualization, as requested in issue #2326.

The method provides a comprehensive view of the Crew's structure including:
- Basic crew information (id, name, process type)
- Agent details
- Task information
- Task relationships
- Manager agent (for hierarchical processes)

Added comprehensive tests to verify functionality across different
Crew configurations and error handling.

Co-Authored-By: Joe Moura <joao@crewai.com>
2025-03-11 07:37:31 +00:00