{% if ai_enhanced %}
🤖 DeepSeek AI 增强
{% else %}
📋 规则分析
{% endif %}
📊

微信聊天分析报告

生成时间: {{ generated_at }}  |  v1.1.0

📈 聊天统计
{{ stats.total_messages }}
总消息数
{{ stats.self_messages }}
你的消息
{{ stats.other_messages }}
对方消息
{% if stats.conversation_duration_days %}{{ stats.conversation_duration_days }}天{% else %}--{% endif %}
聊天跨度
{% if mbti and mbti.type and mbti.type != '未知' %}
🧠 MBTI 人格推断
{{ mbti.type }}

{{ mbti.name }}

置信度: {{ "%.0f"|format(mbti.confidence) }}%

{% if mbti.preference %}

{{ mbti.preference.get('E_I','') }}{{ mbti.preference.get('S_N','') }}{{ mbti.preference.get('T_F','') }}{{ mbti.preference.get('J_P','') }}

{% endif %}
{% endif %} {% if big_five and big_five.openness %}
🔬 大五人格分析
{% for dim, key in [('开放性','openness'),('尽责性','conscientiousness'),('外向性','extraversion'),('宜人性','agreeableness'),('神经质','neuroticism')] %} {% set val = big_five.get(key, 50) %}
{{ dim }} {{ "%.0f"|format(val) }}%
{% endfor %}
{% endif %}
⚠️ 风险预警
{% if risks and not risks.no_risk_detected %} {% for rtype, rdata in risks.items() %} {% if rtype != 'no_risk_detected' %}

{{ rdata.description }} {{ rdata.risk_level }}

匹配关键词: {{ rdata.matched_keywords|join(', ') }}

{% if rdata.response_strategies and rdata.response_strategies.defensive %}

💡 应对: {{ rdata.response_strategies.defensive[0] }}

{% endif %}
{% endif %} {% endfor %} {% else %}

✅ 未检测到明显风险话术

{% endif %}
{% if sentiment %}
💬 情感分析

{% if sentiment.trend == 'up' %}📈{% elif sentiment.trend == 'down' %}📉{% else %}➡️{% endif %} 情感趋势: {{ {'up':'上升','down':'下降','stable':'稳定'}.get(sentiment.trend, sentiment.trend) }}

{% if sentiment.positive_ratio is defined and sentiment.positive_ratio is not none %}

正面: {{ "%.1f"|format(sentiment.positive_ratio) }}%  |  负面: {{ "%.1f"|format(sentiment.negative_ratio if sentiment.negative_ratio is defined else 0) }}%

{% endif %} {% if sentiment.summary %}

{{ sentiment.summary }}

{% endif %}
{% endif %} {% if prediction and prediction.next_message %}
🔮 对话预测

"{{ prediction.next_message }}"

{% if prediction.alternatives %}

其他可能: {{ prediction.alternatives|join(' / ') }}

{% endif %}
{% endif %} {% if scenario_analysis and scenario_analysis.primary %}
🎯 场景分析

{% if scenario_analysis.primary == 'romantic' %}💕 恋爱场景 {% elif scenario_analysis.primary == 'work' %}💼 工作场景 {% elif scenario_analysis.primary == 'social' %}👥 社交场景 {% elif scenario_analysis.primary == 'important' %}📌 重要事项 {% else %}{{ scenario_analysis.primary }}{% endif %}

{% endif %} {% if summary %}
📝 AI 分析摘要

{{ summary }}

{% endif %} {% if events %}
📅 待办事项
{% endif %}