April 23, 2026
ModeGate Revamp and Chat Feature Completion
The mode-gate service received extensive refactoring to address SonarCloud reliability issues, replacing float equality checks with pytest
The mode-gate service received extensive refactoring to address SonarCloud reliability issues, replacing float equality checks with pytest.approx to tolerate IEEE-754 rounding noise in unit tests.
Cognitive complexity was reduced by splitting a large validation function into three smaller helper methods, and Sonar new code smells were resolved across the mode-gate service.
New feature tests were added to cover fire/decay math, configuration fallback, and state round-trip assertions for the mode-gate service.
Documentation was updated to reflect the three-tier tool loading system: unconditional primitives, mode-gated conditional tools, and dynamic find_tools.
A new classifier was integrated to promote or demote tools on a per-turn basis based on cognitive intents, using asymmetric EMA decay logic.
Tool performance metrics now include a channel column to distinguish invocations from different sources like user or background processes.
Image drag-and-drop upload was implemented, blocking up to 10 seconds for OCR/PDF extraction before injecting tags into the LLM prompt.
The privacy protection logic was significantly expanded to ensure the delete-all operation truncates every user-owned data table, preventing data retention leaks.
-
Replaced float equality checks with pytest.approx in mode_gate tests.
-
Integrated per-turn tool promotion using a mode_detector classifier.
-
Implemented drag-and-drop image upload blocking up to 10s for OCR/PDF extraction.
-
Expanded delete-all to wipe every user-owned data table across multiple services.
-
Refactored mode-gate logic to reduce cognitive complexity and resolve Sonar issues.
-
Added a channel column to tool_performance_metrics for invocation tracking.