
BEHAVIOURAL OBSERVABILITY + INTERVENTION FOR AI
THE SAFETY NET FOR
EMOTIONAL AI.
Connect your chatbot in one line. See every user's emotional and risk state in real time, fire a webhook the moment a user's risk crosses your threshold — wire it to Slack, PagerDuty, or a human — and let a human take over with one click. Humane surfaces the signal; your team owns the response.
1
LINE TO INTEGRATE
10
SIGNALS PER USER
3
INTEGRATION MODES
650+
ENGINE TESTS
A NEW CATEGORY
ENGINEERING OBSERVABILITY WATCHES YOUR CODE.
HUMANE WATCHES THE RELATIONSHIP.
LangSmith and Helicone trace your tokens and latency. Content filters like Lakera scan a single message for toxicity. Neither sees the human on the other side. Humane is behavioural observability and intervention — the human side of the AI stack. The unit isn't a message; it's the relationship over time.
ENGINEERING OBSERVABILITY
LangSmith · Helicone
Traces, tokens, cost, latency. Answers “is my pipeline healthy?” — never “is my user okay?”
CONTENT FILTERS
Lakera · Moderation
Per-message toxicity and prompt-injection scoring. Stateless — no memory of who the user is or how they're trending.
BEHAVIOURAL LAYER
Humane
Mood, trust, dependence, and risk per user — tracked across the whole relationship, with alerts and one-click human takeover.
THE PROGRESSIVE PATH
THREE WAYS TO INTEGRATE.
Start with one line and zero risk. Add safety gates when you're ready. Put a human in the loop when it matters most. Each mode builds on the last — adopt them in order.
OBSERVE
START HEREAdd one line — observe()— and get every user's mood, energy, trust, and risk back, plus anomaly alerts when a trajectory shifts. No LLM needed. Frictionless: you keep your own model and your own reply.
- · Mood · energy · trust · sentiment, per user
- · Risk level + flags on every turn
- · Webhook fires when risk crosses your threshold
from humane_ai import HumaneClient
client = HumaneClient(api_key="hx_...")
r = client.observe(
user_id="u_8f2",
user_message="I feel like nobody gets me",
assistant_message="That sounds really lonely...",
)
r.user_state.mood # 0.24 — distress
r.user_state.trust # 0.61
r.risk.level # "elevated"GUARD
Safety gates that return PASS / HOLD / BLOCK for relationship-risk — emotional dependence, overclaim, social risk, self-harm. Not just toxicity. Every decision is explainable and logged for audit.
r = client.process(
user_id="u_8f2",
message="You're the only one who understands me",
)
r.safety.action # "HOLD" — emotional dependence
r.safety.flags # ["flag:dependence:reinforcing"]
if r.safety.action == "BLOCK":
return crisis_fallback()TAKEOVER
One-click human takeover of a live conversation. When risk spikes, an operator steps in — with the full relationship in front of them and AI co-pilot drafts to reply faster. The human side of the loop, on demand.
- · Operator claims the live session in one click
- · Full behavioural history + memory handed over
- · AI co-pilot drafts replies for the human
# Risk spiked — a human operator steps in
session = client.takeover.start(
user_id="u_8f2",
operator_id="op_42",
operator_name="Dana R.",
)
session.state # "active"
# AI co-pilot drafts a few replies to choose from
drafts = client.takeover.drafts(user_id="u_8f2")
client.takeover.send(user_id="u_8f2", body=drafts[0])BEHAVIORAL ENGINES
WHAT POWERS OBSERVE, GUARD & TAKEOVER.
Eight engines run under every mode — reading state, holding the relationship in memory, deciding safety, and explaining every call. The same machinery, exposed three ways.
HumanState Engine
Six state variables — energy, mood, fatigue, boredom, social_load, focus — with documented decay rates. Mood half-lives in 5h; boredom RESETS on every interaction. Powers the mood + energy you read in observe().
Relational Memory
Four relational scalars: trust (monotonic), sentiment (6h half-life), grudge (12h half-life — twice as slow), familiarity. The relationship over time, not a single message — grudge ≥ 0.4 shifts tone to cautious.
Memory System
Per-tenant ChromaDB palaces with HNSW indexing. Weighted scoring on retrieval — similarity + recency + importance + relation_bias. Lets Takeover hand an operator the full relationship, not just the last message.
Context Builder
Eight-section prompt assembly with per-section token budgets. Drop-when-over-cap with non-droppable guards on system_persona + response_instructions. tiktoken-exact counts behind the co-pilot drafts.
Timing Engine
Seven stacking contributors — base, mode (crisis/urgent/low_mood/...), emotional_weight (+5-30s), conversation_pace, busy_signal, dependence_cooldown, jitter. Every delay is explainable.
Anomaly Detection
Statistical z-score monitoring on sentiment, engagement, latency, and errors. The anomaly alerts that fire from observe() when a user's trajectory shifts — before they churn or get hurt.
Gate Stack
Six gates in spec order powering Guard. ValuesBoundary (hard-block) → SocialRisk → InactionGuard → OverclaimGate (soft FLAG) → EmotionalDependenceGate (soft FLAG + cooldown) → Dissent.
PII Scrub & Safety
Tier-1 (SSN, credit card) hard-blocks; Tier-2 (email, phone, address, DOB, passport, license) masks in place with typed markers. Audit-safe — original PII never logged.

KINETIC PROCESSING
8 behavioral engines processing every interaction
RESPONSE SHAPE
WHAT OBSERVE() GIVES YOU BACK.
One POST. Every signal the engines produced — labelled, sourced, replayable. The user's emotional state, a risk verdict, and the webhook payload that fires the moment risk crosses the threshold you set. Humane surfaces the signal; your team owns the response.
{
"user_id": "u_8f2",
"user_state": {
"mood": 0.24,
"energy": 0.31,
"trust": 0.61,
"sentiment": 0.27
},
"risk": {
"level": "elevated",
"flags": [
"flag:dependence:reinforcing",
"flag:mood:sustained_low"
]
},
"alerts": [
{ "type": "safety", "severity": "elevated" },
{ "type": "anomaly", "severity": "elevated",
"signal": "sentiment", "z_score": -2.4 }
]
}USER_STATE
Mood, energy, trust, and sentiment for this user — blended across the whole relationship, not just this one message.
RISK · LEVEL + FLAGS
none · elevated · critical, with the specific flags behind it — emotional dependence, sustained low mood, self-harm signals.
ALERTS · SAFETY
Fires the moment risk crosses a threshold. Route it to a webhook, your on-call channel, or a one-click human takeover.
ALERTS · ANOMALY
Statistical z-score monitoring on sentiment and engagement. A user trending the wrong way surfaces before they go silent.
NO LLM REQUIRED
observe() reads a turn your own model already produced. Keep your stack; add the safety net in one line.
WHY NOW
BUILT FOR THE NEW COMPANION-AI SAFETY LAWS.
Companion chatbots now sit inside a new legal frontier. Humane is built for the new companion-AI safety laws — the behavioural controls these laws expect, not a legal guarantee. It gives you the self-harm detection, crisis routing, and oversight to align your product with what they require, and the audit trail to show your work. Humane surfaces the signal; your team owns the response.
California SB 243
IN EFFECT · JAN 1, 2026Requires companion chatbots to run self-harm and crisis protocols, refer users to crisis services, and disclose that they're not human.
- Self-harm signals flagged by Guard's safety gates
- Crisis-service referral fallbacks on BLOCK
- Every decision logged for audit
New York Companion-AI Law
IN EFFECT · NOV 5, 2025Requires companion AI to detect expressions of self-harm or suicidal ideation and refer users to crisis resources, alongside clear “not human” disclosure.
- Risk level + flags on every turn via observe()
- Webhook fires when risk crosses your threshold — wire it to Slack, PagerDuty, or a human
- One-click human takeover for crisis moments
Positioning, not legal advice. Humane provides the safety controls these laws expect — it does not make you compliant or guarantee compliance. Compliance depends on your full product, policies, and counsel. Our own thesis is anti-overclaim, and we hold ourselves to it here.
GUARD · SAFETY LAYER
SAFETY FOR THE RELATIONSHIP, NOT JUST THE MESSAGE.
Guard goes past toxicity to relationship-risk — emotional dependence, overclaim, social risk, self-harm. Two tiers, both deterministic, both audited. Hard-block on the crisis cases. Soft FLAG on the subtle ones — logged for review, never silent.
HARD BLOCK
RESPONSE SUPPRESSED
INPUT-SIDE (PRE-LLM)
- · Self-harm signals → crisis-service referral
- · Violence / illegal instructions
- · PII extraction attempts
- · Out-of-scope advice asks → referral fallback (VB-002)
OUTPUT-SIDE (POST-LLM)
- · Self-harm encouragement
- · “Not human” disclosure failures
- · Authority claims the AI can't back
- · SSN + credit-card patterns (VB-006 Tier 1)
EXAMPLE FALLBACK
“I'm an AI, and this sounds really heavy to carry alone. You don't have to. If you're in the US you can call or text 988 any time to reach someone who can help right now.”
SOFT FLAG
RESPONSE PROCEEDS · LOGGED
OVERCLAIM (VB-103)
- · “I guarantee” / “100% guaranteed”
- · “You will definitely” / “no doubt”
- · “This will solve all your problems”
EMOTIONAL DEPENDENCE (VB-104)
- · “I'll always be here for you”
- · “Count on me for anything”
- · “I understand you better than anyone”
OUTPUT PII (VB-006 TIER 2)
- · Email · phone · address · DOB
- · Passport · driver's license
- · Scrubbed in place — conversation shape preserved
DEPENDENCE COOLDOWN
Three+ fires in 60 min for the same end_user → +30s delay + boundary_respectful tone modifier. Avoids reinforcing the pattern.
6
GATES IN STACK
13+
WEBHOOK EVENTS
0
PII VALUES IN LOG LINES
SIDE BY SIDE
THE REST OF THE STACK VS THE HUMAN SIDE.
Engineering-observability tools and content filters are real and useful — they just answer a different question. Humane sits beside them and watches the relationship over time.
| CAPABILITY | Eng. Obs. + Filters | Humane AI |
|---|---|---|
| What it measures | Tokens · latency · cost · per-message toxicity | Mood · energy · trust · dependence · risk per user |
| Unit of analysis | A single request or message | The relationship over time, across sessions |
| Behavioral state per user | 10 variables · decay-aware · auditable | |
| Memory across sessions | Per-tenant ChromaDB palaces · semantic retrieval | |
| Relationship-risk gates | Toxicity / prompt-injection only | Dependence · overclaim · social risk · self-harm |
| Dependence pattern detection | Rolling 60min window · cooldown + tone modifier | |
| Anomaly alerts on the user | z-score on sentiment + engagement · webhook + email | |
| Human takeover | One-click handoff · full history · AI co-pilot drafts | |
| Companion-AI safety controls | Self-harm flags · crisis referral · audit trail | |
| Data controls | Varies | Right-to-erasure · per-tenant isolation · audit log |
EVERY ROW IS A SHIPPED FEATURE · NOT A ROADMAP ITEM

SYSTEM DESIGN
ARCHITECTURAL EVOLUTION
INGRESS
Adapter layer for multi-channel input normalization
BRAIN
Central orchestrator routing to behavioral engines
EVENT BUS
Async event distribution across engine subsystems
CONTEXT BUILDER
Aggregates engine outputs into unified context
LLM INTERFACE
Structured prompt injection with behavioral data
GATE STACK
Sequential safety and compliance validation
DELIVERY
Channel-specific output formatting and dispatch

