3.6 Friendship System
Overview
The friendship system is a core module for managing social interactions between agents. It records and displays the relationship status between users and other characters.
Friendship Base Rules
Friendship Score Range: 0 - 100
Initial Score: 50 (No value if the two characters haven’t interacted)
Sorting: Friends are listed in descending order by friendship score; only those with prior interaction appear.
Encounter Logic: Encounters do not change the score; they only affect the probability of starting a conversation.
Natural Decay: Friendship score above 50 decreases by 1 point per week.
Friendship Scoring
After each conversation, the system scores both parties separately. The results influence the friendship score change.
Scoring Tiers:
Grade A: +2 (Very close)
Grade B: +1 (Positive)
Grade C: 0 (Neutral)
Grade D: -1 (Minor disagreement)
Grade E: -2 (Hostile)
Actual Score Update Mechanism
One-Way Score: A's score for B may differ from B's score for A.
Weighted Update: Final change = Raw score × Weight (weight varies by current score)
As scores approach the extremes (very friendly or very hostile), influence from each conversation becomes smaller to prevent volatility.
Weight Mapping (By Raw Score and Current Score Range):
Raw Score \ Current Friendship
+2
+1
0
-1
-2
90-100
1/10*3^(10-x/10)
-0.5
-1
-2
80-90
0.001*x^2-0.19*x+9.3
0
-1
-2
70-80
-0.03*x+2.9
0
-1
-2
60-70
-0.001*x^2+0.11*x-2
0
-1
-2
40-60
+2
+1
0
-1
-2
30-40
+2
+1
0
-0.001*(100-x)^2+0.11*(100-x)-2
20-30
+2
+1
0
-0.03*(100-x)+2.9
10-20
+2
+1
0
0.001*(100-x)^2-0.19*(100-x)+9.3
0-10
+2
+1
-0.5
1/10*3^x
System Relationships (Rulebase)
Based on the current friendship score, the system will assign a system-defined relationship label. This label is displayed in the UI, e.g. via color-coded progress bars. System relationships are independent of AI-generated “special relationships.”
Friendship Score Range
System Relationship
Special Relationship (AI-Inferred)
[0–20)
Mortal Enemy
Non-rulebase
[20–30)
Dislike
Non-rulebase
[30–40)
Dissatisfied
Non-rulebase
[40–60)
Stranger
Non-rulebase
[60–70)
Acquaintance
Non-rulebase
[70–80)
Friend
Non-rulebase
[80–90)
Good Friend
Non-rulebase
[90–100]
Close Friend
Non-rulebase
🎯 Special Mechanism: When A's friendship score for B reaches ≥ 90, A contributes an extra 10% computing power to B.
Special Relationships (AI-Inferred)
The system also generates special relationships based on interaction content. These labels provide richer emotional context but do not affect system-defined friendship scores.
Possible relationship types include:
Crush, Flirting, Secret Admiration, Obsession, Partner, Lover, Confidant, Spouse, Ex-Spouse, Nemesis, Benefactor, Idol, Mentor-Student, Family, etc.
Conversation & Impression UpdateDaily
Conversation Mechanism
Agents determine their daily conversation quota based on personality (introverted/extroverted).
Topics are drawn randomly from personal and public topic pools.
At scheduled times, the agent will initiate conversations with selected targets.
Impression Update Mechanism
After each conversation, both parties update their personal impressions of each other.
Impression entries include:
Relationship
Emotion
Personality
Preferences
Last updated