How google/mozc works
Main Components Overview
The system should be divided into these major components:
a. Core Engine Components:
• Dictionary System (/src/dictionary)
• Converter (/src/converter)
• Prediction System (/src/prediction)
• Rewriter System (/src/rewriter)
• Session Manager (/src/session)
b. Platform-Specific UI Components:
• Windows (TSF/IMM) (/src/win32)
• macOS (/src/mac)
• Linux/IBus (/src/unix/ibus)
• Android (/src/android)
c. Supporting Systems:
• IPC Layer (/src/ipc)
• Renderer (/src/renderer)
• Storage (/src/storage)
• Base Utilities (/src/base)
Component Relationships
[User Interface Layer]
• Windows/Mac/Linux/Android UI
• ↕
[IPC Communication Layer]
• ↕
[Session Management]
• ↕
[Core Engine]
• ↙ ↓ ↘
Dictionary Converter Prediction
• ↘ ↓ ↙
• Rewriter System
• ↕
[Storage Layer]
Specific Implementation Details
Key architectural elements:
• Server-client architecture (mozc_server, mozc_renderer)
• Dictionary management system
• Configuration system (/src/config)
• Platform-specific input handling
• Rendering system for candidate windows
Data Flow Indicators
Show:
• Input flow from UI to core engine
• Dictionary lookup paths
• Conversion result paths
• Configuration data flow
• IPC communication paths
Notes for Implementation Details
Callouts for:
• Multi-platform support mechanisms
• Dictionary data structures
• IPC mechanisms
• Threading model
• Resource management
Remember to emphasize the modular nature of the system and how different components can be swapped out for different platforms while maintaining the core conversion engine's integrity.