Secondary Development Guidelines and Architecture Explanation
The project is designed using a layered architecture:
- exhibition layer: Cross-platform UI implemented by Flutter (lib/ui/)
- business logic layer::
- Voice processing (lib/services/audio_service.dart)
- Network communication (lib/api/websocket_client.dart)
- Device control (lib/features/miot/)
- data layer: Hive Local Database + SharedPreferences Configuration Storage
Extended Development Recommendations:
- Adding a new model requires inheritance from the BaseAIService abstract class.
- Custom themes should modify the color constants under lib/themes/
- Use riverpod for state management to avoid direct setState
- Calling platform-specific native APIs via platform_channel
This answer comes from the articleXiaozhi MCP Client: a cross-platform AI assistant supporting voice and text interactionThe