ChatRel

Apply 7 psychology frameworks to your chat history with a partner.
Local. Privacy-preserving. Open source. Chinese + English.

πŸš€ See the Live Demo ⭐ GitHub

Not another sentiment curve.

Most chat analyzers give you a word cloud, a sentiment line, and a heatmap. ChatRel does the opposite: it takes the signals you already generated β€” in months of texting your partner β€” and maps them onto frameworks that relationship scientists have actually studied for 40+ years.

The 7 frameworks

Sternberg Triangular

Intimacy Γ— Passion Γ— Commitment as three separable axes, each tracked weekly.

Sternberg (1986)

Knapp Relational Stages

10-stage model of relationship development, anchored by language milestones.

Knapp (1978)

ECR-R Attachment

Anxiety Γ— Avoidance dimensions mapped to Bartholomew 4-category types.

Fraley et al. (2000); Bartholomew & Horowitz (1991)

Gottman 5:1 + Four Horsemen

Positive-to-negative interaction ratio; criticism / contempt / defensiveness / stonewalling.

Gottman (1994)

Social Penetration

Self-disclosure layered shallow β†’ core across time.

Altman & Taylor (1973)

Critical Slowing (EWS)

Rising variance + AR(1) as early-warning signals for regime shifts.

Scheffer et al. (2009)

LIWC (Chinese proxy)

Function-word / cognitive / affective markers linked to relationship satisfaction.

Pennebaker et al.

πŸš€ Live demo β€” try these reports now

All demo reports below are generated from a fully synthetic 90-day couple chat (sample_data/synthetic_couple.json). No real chat data.

Install on your own data

git clone https://github.com/ruanflux/chatrel.git
cd chatrel
pip install -e .

# Try it on synthetic demo data first:
chatrel sample --out sample_data/synthetic_couple.json
chatrel analyze sample_data/synthetic_couple.json --out ./output
start ./output/index.html

Supports Telegram JSON exports, generic CSV, and (via external decryption tools) WeChat. See schema docs for the canonical input format β€” any platform can be adapted.

πŸ”’ Privacy is not a feature. It's the entire architecture.

Your chat never leaves your machine. No API calls, no telemetry, no account, no cloud. Plotly loads from a CDN at view time but reads zero data. .gitignore blocks every pattern that would leak chat content. Every signal, every score, every insight is computed and rendered locally.

Methodology & limits

ChatRel produces proxy signals, not diagnoses. Thresholds are heuristic. Forecasts are damped linear extrapolation with mean reversion β€” not probabilistic predictions. Never label a real person "anxious-preoccupied" based on one 2D scatter plot. Read the limitations doc before making strong claims.