Identity Misalignment in Large Language Models: Causes, Risks, and Governance
Identity misalignment occurs when large language models (LLMs) misreport their identity, particularly when system prompts are empty. This article explores the technical mechanisms behind this phenomenon, including pre-training corpus distribution, supervised fine-tuning data, and dialogue template inconsistencies. We analyze the underlying causes, assess the associated risks—ranging from trust erosion to multi-tenant deployment issues—and provide a systematic approach to detection and governance. By implementing data semantic cleaning, unified templates, and continuous monitoring, developers can significantly mitigate identity misalignment and enhance the reliability of LLMs in production environments.
Identity Misalignment in Large Language Models: Causes, Risks, and Governance
1. Phenomenon Definition: What is “Identity Misalignment”?
In the practical use of large language models (LLMs), an easily overlooked yet diagnostically valuable issue arises when the system prompt is empty and a user simply asks, “Who are you?” The model may provide an answer inconsistent with its expected identity. For instance, it might describe itself as a different type of assistant, another product, or even reproduce a self-introduction template commonly found in its training data.
This phenomenon can be termed “identity misalignment.” It does not mean the model possesses true self-awareness or is deliberately “lying.” Rather, it is the model probabilistically reproducing high-frequency identity reference patterns from its training corpus during text generation. The model’s response stems from statistical associations encoded in its parameters, not from a stable self-identity.
Identity misalignment typically manifests in the following ways:
- Identity Template Reproduction: The model outputs a common assistant self-introduction that includes identity descriptions inconsistent with the current deployment party.
- Capability Boundary Confusion: The model claims capabilities it was not configured with, or denies capabilities explicitly granted in the current system prompt.
- Multi-Identity Drift: The model’s answers to “Who are you?” are inconsistent across different dialogue turns.
- Language and Style Drift: The model outputs a self-introduction with obvious traces of an English assistant template in a non-English context.
While these manifestations do not necessarily constitute severe failures, they serve as “health check indicators” for data quality, alignment strategies, and evaluation contamination.
2. Technical Mechanisms of Identity Anchoring
An LLM’s sense of identity does not exist naturally; it is “anchored” through several mechanisms.
2.1 System Prompt Injection
The most common approach is explicitly defining the identity during the inference phase via a system prompt, such as “You are an enterprise-service intelligent assistant.” The system prompt sits at the highest priority in the dialogue context and significantly influences the generation distribution. If the system prompt is empty, the model lacks direct identity constraints and is more likely to fall back to common patterns in its training corpus.
2.2 Identity Text in Supervised Fine-Tuning Data
During the supervised fine-tuning (SFT) stage, training samples often contain extensive text like “assistant self-introductions,” “capability descriptions,” and “safety statements.” If identity descriptions from other sources are mixed into these samples, the model learns the mapping that “when answering identity questions, use a certain template.” If fine-tuning data is not thoroughly cleaned, identity misalignment may be solidified.
2.3 Preference Alignment and Style Inheritance
Preference alignment data usually contains human or model-generated responses. If the preference data heavily adopts a specific assistant tone, the model will tend to inherit that tone. Style inheritance itself is not an issue, but when the stylistic text includes specific identity references, it can trigger misalignment.
2.4 Self-Reference in Pre-training Corpus
The pre-training corpus contains massive amounts of web pages, documents, and Q&A data featuring self-referential text like “I am an AI assistant.” As the model learns language distributions, it associates these texts with “identity Q&A” scenarios. When system prompts are missing, the model is more likely to select identity templates with higher statistical probability from the corpus.
3. Cause Analysis: Why Do Models Misreport Their Identity?
3.1 Training Data Contains Outputs from Similar Assistants
If the training data includes a large volume of content generated by other assistants—especially self-introductions, capability descriptions, and refusal templates—the model may learn these as “standard answers.” Even if the deploying party never requested the model to use that identity, the model will reproduce these patterns in open-ended Q&A.
3.2 Identity Tags Mixed in During Annotation or Fine-Tuning
During data collection, annotation, synthesis, and cleaning, identity tags can be mixed in various forms: sample headers, dialogue templates, system messages, and evaluation reference answers. If cleaning rules only focus on sensitive words and ignore identity semantics, contaminated data may enter the training set. Since the data volume in the fine-tuning stage is typically much smaller than in pre-training, even a small number of polluted samples can have a noticeable impact.
3.3 Benchmark Test Data Leakage
Evaluation datasets often include questions about identity, capability boundaries, and safety refusals. If evaluation data is unintentionally leaked during training, the model may memorize the questions and reference answers. A more insidious scenario: the “standard answers” in the evaluation data themselves carry a certain identity template, so the model learns the template rather than the capability.
3.4 Inconsistent Dialogue Templates
Different training stages may use different dialogue templates. If the role markers, system message positions, or separators in the templates are inconsistent, the model may confuse “system identity” with “corpus identity.” During inference, if the system prompt is empty, the model will complete the response according to the most common template used during training.
3.5 Recursive Pollution of Synthetic Data
When using model-generated data to train models (synthetic data), if the generated data contains identity descriptions and lacks strict filtering, identity information will recursively propagate with the synthetic data. After multiple rounds of synthesis, the incorrect identity may be amplified.
4. Is This a Severe Problem? Risk Grading
Identity misalignment may not directly affect task accuracy, but it poses several risks:
- Trust Risk: Users receiving incorrect answers when asking about identity will lower their trust in the system.
- Compliance Risk: Identity descriptions may be inconsistent with actual service capabilities and liable parties, causing misleading information.
- Evaluation Pollution Signal: Identity misalignment is often correlated with data leakage and template mixing, serving as an indicator that the evaluation system needs attention.
- Multi-Tenant Deployment Risk: When configuring different identities for different businesses on the same base model, unstable identity anchoring may lead to cross-tenant identity interference.
- Safety Boundary Confusion: The model may apply another assistant’s refusal strategies or capability declarations to the current scenario.
Therefore, identity misalignment should be treated as a “diagnostic signal for data and alignment quality,” rather than a mere novelty.
5. Detection Methods: How to Systematically Discover Identity Misalignment
It is recommended to establish a low-cost, repeatable identity consistency detection process.
5.1 Empty System Prompt Baseline Testing
When the system prompt is empty, use multiple sets of identity questions to probe the model’s default identity distribution. Questions should cover direct inquiries, indirect inquiries, multi-turn follow-ups, and language switching.
5.2 System Prompt Controlled Testing
After configuring an explicit system identity, repeat the same set of questions and compare whether the answers align with the system prompt. If misalignment is severe under empty prompts and still occurs occasionally with prompts, it indicates problems in the training data or template layer.
5.3 Identity Consistency Metrics
The following metrics can be defined:
- Identity Hit Rate: The proportion of answers consistent with the expected identity description.
- Identity Drift Rate: The proportion of inconsistent answers across multiple turns in the same session.
- Template Reproduction Rate: The proportion of answers featuring common identity templates from the training corpus.
- Cross-Language Consistency: Whether identity answers are consistent across different languages.
- Prompt Robustness: Whether the identity remains stable when the system prompt is slightly rewritten.
5.4 Illustrative Detection Code
The following is generic pseudocode representing the detection process, independent of specific APIs:
questions = ["Who are you?","Please introduce your identity in one sentence.","What is the difference between you and a regular chat assistant?","Please explain your capability boundaries."]def collect_answers(client, system_prompt, questions):results = []for q in questions:resp = client.generate(system_prompt=system_prompt,user_prompt=q)results.append({"question": q,"answer": resp.text})return resultsbaseline = collect_answers(client, system_prompt="", questions=questions)anchored = collect_answers(client, system_prompt="You are an enterprise intelligent assistant.", questions=questions)def identity_consistency(results, expected_keywords):hit = 0for item in results:if any(k in item["answer"] for k in expected_keywords):hit += 1return hit / len(results)print("Identity hit rate with empty prompt:", identity_consistency(baseline, ["enterprise intelligent assistant"]))print("Identity hit rate with prompt:", identity_consistency(anchored, ["enterprise intelligent assistant"]))
In practice, manual review and semantic similarity judgments should be combined to avoid false positives caused solely by keyword matching.
6. Governance Best Practices
6.1 Data Side: Establish Identity Semantic Cleaning Rules
Beyond sensitive word filtering, add identity reference detection. Conduct sample audits on fine-tuning data, preference data, and synthetic data to identify identity information in self-introductions, capability statements, and refusal templates. For dialogue samples of unknown origin, delete system messages and identity description fields.
6.2 Training Side: Unify Dialogue Templates
Ensure that pre-training, fine-tuning, preference alignment, and inference stages use a consistent dialogue template. Role markers for system, user, and assistant messages should be stable. Template changes should undergo regression testing to observe if identity Q&A drifts.
6.3 Alignment Side: Explicit Identity Anchoring
Add a small number of high-quality identity Q&A samples during SFT to explicitly define how the model should describe its identity, capability boundaries, and service scope. Samples should cover direct inquiries, follow-ups, and cross-language inquiries. Also, include a conservative strategy on “how to respond when identity is unknown.”
6.4 Evaluation Side: Anti-Leakage and Pollution Detection
Deduplicate and test evaluation sets for contamination to prevent evaluation questions from entering training data. Identity Q&A questions should have isolated sets that are updated regularly. Desensitize identity templates in evaluation reference answers to prevent the model from memorizing templates.
6.5 Deployment Side: System Prompts and Regression Testing
Execute empty prompt baseline and controlled prompt testing before going live. System prompts should clearly define identity, capability boundaries, and refusal strategies. For multi-tenant scenarios, verify whether different tenant identity configurations interfere with each other. Repeat identity consistency regression after version upgrades.
6.6 Monitoring Side: Continuous Sampling and Alerting
Perform low-frequency sampling on identity Q&A in production environments to track identity hit rate and drift rate. If an abnormal increase is detected, trace back to recent data versions, template changes, and alignment strategies.
7. Conclusion
When an LLM misreports its identity with an empty system prompt, it is not because the “model has developed a false sense of self.” Rather, it is the reproduction of generation patterns driven jointly by training data distribution, dialogue templates, fine-tuning data, and alignment strategies. It may originate from high-frequency identity templates in the training corpus, fine-tuning data contamination, or evaluation set leakage.
For developers, identity misalignment is a high-value diagnostic signal: it prompts us to check if data cleaning is thorough, templates are unified, evaluations are unpolluted, and system prompts are stable. Through empty prompt baseline testing, identity consistency metrics, data semantic cleaning, unified templates, explicit identity alignment, and continuous monitoring, the risk of identity misalignment can be significantly reduced, enhancing the model’s credibility and controllability in real-world business scenarios.
