- Add OutputFormat ADT for explicit format handling vs file extension checking - Replace crash-prone runIOorExplode with proper Either error handling - Extract processMermaidBlock into focused functions for better maintainability - Convert String constants to Text for type consistency - Add DiagramConfig type for better configuration management - Enhance haskell-refactoring-expert agent to handle module organization 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>