A recent study published on arXiv (2607.09842) reveals a fascinating finding about how large language models (LLMs) encode identity in their internal representations. The research shows that multimodal instruction fine-tuning causes a fundamental reorganization in the geometry of hidden states: identity encoding shifts from being direction-based to magnitude-based. This change, detected using metrics such as the Wasserstein distance between Ollivier-Ricci curvature distributions on trajectory graphs, has profound implications for developing artificial intelligence applications that require consistent behavior aligned with a brand or system identity.
The experiment analyzed four open-weight language models under different post-training regimes: a base model without additional training (Gemma-4-E4B base), a multimodal RLHF model (Gemma-4-E4B-it), a reinforcement distillation model (DeepSeek-R1-Distill-Qwen-7B), and a supervised fine-tuning model (Qwen2.5-7B-Instruct). Three prompt conditions were compared: an identity-specifying prompt, a generic assistant prompt, and a 26-token baseline. The main metric was the 1-Wasserstein distance between edge-wise distributions of Ollivier-Ricci curvature on a k-NN graph built from hidden-state trajectories. Results showed that in the base model identity is encoded in trajectory direction (significant angular separation, p=0.002), while in the multimodal instruction-tuned model this encoding migrates to magnitude (angular separation becomes non-significant, p=0.439, but magnitude shows differences, p=0.042, and the mean norm of the first generated state reverses, being lowest for the identity prompt). This pattern is exclusive to the multimodal instruction regime and does not appear under distillation or SFT.
Why should a software development company care? Because how an AI model represents its identity directly affects user trust, response consistency, and personalization capabilities. When building custom applications that integrate virtual assistants, AI agents, or recommendation systems, it is crucial that the model maintains a coherent identity across interactions. This study suggests that multimodal instruction fine-tuning, as done in systems combining text and images, can alter that encoding predictably. For companies like Q2BSTUDIO, specialized in custom software, this information is invaluable for designing fine-tuning pipelines that preserve or intentionally modify model identity according to client requirements.
From a technical perspective, using Ollivier-Ricci curvature as a diagnostic tool for neural networks opens new possibilities for quality monitoring in AI systems. Instead of relying solely on performance metrics like accuracy or recall, developers can inspect the internal geometry of representations to detect deviations in identity encoding. This is particularly relevant in cybersecurity, where an AI agent that inadvertently changes its identity could be exploited for impersonation or manipulation attacks. Q2BSTUDIO incorporates these insights into its cybersecurity services, offering robustness assessments for AI models.
Furthermore, identity encoding reorganization has implications for deployment in cloud environments like AWS or Azure. In multi-layer applications where the AI model acts as a user interface, identity consistency is key to customer experience. Q2BSTUDIO's cloud services ensure models are deployed with configurations that maintain identity coherence, whether through prompt adjustments or specific network architectures. Likewise, in Business Intelligence (Power BI), integrating natural language assistants that maintain a consistent corporate identity can improve adoption of analytical tools.
Another notable aspect of the study is the teacher-forcing control method, which attributed approximately 30% of the free-running cosine signal to prompt-driven effects. This underscores the importance of careful prompt design in production, especially for AI agents that must interact in multimodal contexts. Companies developing applications with language models must consider not only content but also how the model internalizes identity. For example, a customer service AI agent trained with multimodal instructions may require a different fine-tuning approach to preserve brand personality.
In conclusion, this study represents a significant advance in understanding how language models encode identity and how multimodal instruction fine-tuning reorganizes that geometric representation. For Q2BSTUDIO, as a pioneering software and technology development company, this knowledge is directly integrated into the methodology for creating artificial intelligence, cybersecurity, cloud, and BI solutions. The ability to measure and control identity encoding through geometric metrics offers a competitive advantage in building robust, reliable AI systems aligned with each client's needs. Research continues, but one thing is clear: identity is no longer just a matter of content, but of geometry.



