- Move EMOJI_MAP to module level as DEFAULT_EMOJI_MAP for memory efficiency
- Add _parse_bool_env() helper function for cleaner boolean conversion
- Implement performance optimization with icon caching
- Improve error handling for unknown emojis with better fallback format
- Update tests to work with new module structure
- All functionality preserved and tests passing
Addresses feedback from PR review #3063
Co-Authored-By: João <joao@crewai.com>
- Add environment variable CREWAI_DISABLE_EMOJIS to control emoji usage
- Create comprehensive emoji-to-text mapping for runtime compatibility
- Implement _get_icon() helper method in ConsoleFormatter
- Replace all hardcoded emojis with dynamic icon selection
- Add comprehensive test suite covering all emoji disable scenarios
- Maintain backward compatibility (emojis enabled by default)
- Fixes issue #3062 for Azure Functions and similar runtime environments
Co-Authored-By: João <joao@crewai.com>