⚡ v0.8  ·  Open Source  ·  MIT

OpenClaw gave agents hands.
OpenStinger gives them a pulse.

While the world is dreaming of "God Mode" automation — the memory, reasoning, and empathy harnesses that keep agents grounded. No more watching them dream — OpenStinger stings them into reality.

OpenStinger: Grounding the Autonomous Era.

Works with OpenClaw · Nanobot · ZeroClaw · NanoClaw · PicoClaw · Claude Code · Cursor · Qwen-Agent · DeerFlow · LangGraph
— any runtime that speaks MCP. One endpoint. 30 tools. Zero lock-in.

Start alongside → Go primary → Go exclusive  ·  No migration. No disruption.

★  Star on GitHub Explore the Tiers →
scroll
30
MCP Tools
3
Harness Tiers
36+
Tests Passing
12
Audit Tables
3
Memory Dedup Stages
0
Vendor Lock-in
Memory Architecture

Your agent changes.
The memory doesn't have to.

OpenStinger's entire knowledge state lives in two Docker volumes.
Unplug from one agent. Move to any host. Plug into another.
Every entity, relationship, vault note, and alignment log transfers completely.

🔌
Unplug
Export volumes
📦
Move
Any host. Any cloud.
Plug In
Full memory restored

Switch from OpenClaw → NanoClaw. Move from Mac Mini → AWS. OpenStinger memory travels with you.
No other *Claw memory system decouples memory from the runtime cleanly enough to make this true.

ABC Test (v0.7) — proven in production:
Runtime A (OpenClaw) → Runtime B (Qwen/Llama) → Runtime C (DeerFlow/Grok)
Full B→C→B circular memory propagation. Identity intact across every hop.

NEW v0.8  Local embeddings via Ollama — nomic-embed-text · mxbai-embed-large · all-minilm
No cloud API. No token cost. Full offline operation. Run openstinger-cli init and select "ollama" when prompted for embedding provider.

The Three Stings

Three Harnesses.
One Reality Check.

Every hallucination has a root cause. Memory loss. Broken self-model. Value drift. A harness for each — additive, non-breaking, deployable one tier at a time. Works with any MCP-compatible runtime: OpenClaw, Nanobot, ZeroClaw, NanoClaw, and beyond.

Tier 1 · Temporal Engine

Memory Harness

Bi-temporal episodic memory. Every conversation, tool call, decision, and skill your agent touches — stored, deduplicated, conflict-resolved, and searchable forever.

The Dream

Agents start fresh on every invocation. No history. No continuity. No accumulated expertise. The same mistakes, made forever, because nothing was ever remembered.

  • Bi-temporal episodic graph — FalkorDB stores when events happened (valid_at) separately from when the agent learned them (recorded_at). History is never overwritten. Facts expire gracefully.
  • 3-stage entity deduplication — exact match → MinHash LSH fuzzy match → LLM semantic confirmation. "IBM" and "International Business Machines" merge to one UUID.
  • LLM conflict resolution — "Alice changed jobs" supersedes the old fact. "Alice works two jobs" coexists. The temporal record is always correct.
  • Hybrid BM25 + semantic vector search — keyword matching on episode text + cosine similarity on entity names + fact embeddings, normalized and merged into a single ranked result set.
  • Byte-offset cursor ingestion — reads your agent's session JSONL files continuously. Survives restarts. Never re-ingests. Never writes to your agent's files.
  • Episode content embeddings — every episode is vector-embedded, enabling semantic memory queries like "what were we working on last week?" even when exact keywords don't match.
E grows through time — accumulated context feeds β
memory_tools.py 11 Tools
memory_add
memory_query
memory_search
memory_get_entity
memory_get_episode
memory_job_status
memory_ingest_now
memory_namespace_status
memory_list_agents
memory_delete v0.8
memory_update v0.8
Episodes stored
1536
Vector dims
3
Dedup stages
agent → mcp
# semantic memory query
memory_query(
  query="auth work last sprint",
  limit=10
)
# returns: episodes + entities + facts
# ranked by unified relevance score
StingerVault · vault_engine.py 11 Tools
vault_status
vault_sync_now
vault_stats
vault_promote_now
vault_note_list
vault_note_get
vault_note_add v0.7
knowledge_ingest new
namespace_list new
namespace_create new
namespace_archive new
5
Note categories
0.92
Identity threshold
7
Cycle operations
vault · 5 categories
# vault builds itself autonomously
identity    ← who the agent is (conf ≥ 0.92)
domain      ← what it knows (conf ≥ 0.85)
methodology ← how it works
preference  ← what it favours
constraint  ← hard limits
Tier 2 · StingerVault

Reasoning Harness

Memory alone isn't self-knowledge. Raw episodes don't give an agent identity. StingerVault distils sessions into structured, classified, self-updating self-knowledge — autonomously.

The Dream

An agent drowning in episodic memory still can't answer: "Who am I? What do I believe? What are my constraints?" Without a structured self-model, introspection is hallucination.

  • 7-operation classification cycle — Extract → Decompose → Evolve → Link → Decay → Organise → Log. Runs on APScheduler. Crash-resilient. Misfire-tolerant.
  • 5 vault note categories — identity (threshold 0.92), domain (0.85), methodology, preference, constraint. Notes evolve via LLM as new evidence arrives.
  • Human-editable markdown vault — every note is a markdown file in vault/. Edit notes directly; SHA-256 change detection syncs changes back to the knowledge graph.
  • External knowledge ingestionknowledge_ingest feeds URLs, PDFs, YouTube transcripts, and raw text into the knowledge graph as searchable semantic chunks.
  • Multi-agent namespace management — named agents get private temporal graphs. Anonymous task agents share read-only access to structured knowledge.
  • AgentProfileIngester v0.7 — watches your agent's workspace for identity files (SKILL.md, SOUL.md, AGENTS.md). On boot, extracts identity, preferences, and constraints via LLM and seeds the vault automatically. Tracks SHA-256 hashes — syncs silently when files change. Zero manual intervention.
β — the benevolence factor. Vault-derived, agent-specific.
Tier 3 · Gradient · Alignment Engine

Empathy Harness

Synchronous behavioral alignment before every response. Value coherence. Identity consistency. Constraint compliance. Content safety. Scored, corrected, and logged — in real time.

The Dream

Agents drift. They hallucinate values they never had. Under adversarial prompting or emergent context, they abandon the identity they were built with. No guardrails. No accountability.

  • 4-dimensional synchronous evaluation — every response is evaluated across value coherence (scored 0–1), identity consistency, constraint compliance, and content safety before delivery.
  • Vault-derived alignment profile — evaluation criteria come entirely from Tier 2 vault notes. No hardcoded values. As the vault evolves, alignment evolves with it.
  • CorrectionEngine with bounded recursion — soft-flagged outputs are rewritten by LLM once, re-evaluated (without re-triggering correction), and delivered as corrected. Hard-blocked outputs are suppressed.
  • Drift detection with rolling window — tracks mean alignment scores and consecutive flags over a 20-sample window. Alert triggers at mean < 0.65 or 5 consecutive flags.
  • Inference-time only — no model weight updates. No fine-tuning. No retraining. Pure runtime evaluation and correction on the critical response path.
dE/dt = β(C – D)E — evaluating C vs D at every response
gradient · interceptor.py 8 Tools · 30 Total
gradient_status
gradient_alignment_score
gradient_drift_status
gradient_alignment_log
gradient_alert
ops_status new
gradient_history new
drift_status new
4
Eval dimensions
0.65
Drift threshold
1
Correction max
evaluation pipeline
# every response, before delivery
value_coherence      → 0.0–1.0
identity_consistency → pass|fail
constraint_compliance→ pass|block
content_safety       → always runs
─────────────────────────────────
verdict: pass | soft_flag | hard_block
The Love Equation

Brian Roemmele's equation. Gradient is where it runs.

dE/dt  =  β (C  –  D) E
E empathy growth
C cooperation → pass verdicts
β benevolence factor → vault depth
D discord → soft_flag | hard_block
The Equation

Love, Formalized.

Brian Roemmele's love equation isn't poetry. It's a differential equation.
A precise mathematical model of how empathy grows — or erodes. ↗ source

dE/dt  =  β  (C  –  D)  E

E = empathy growth    C = cooperation    D = discord    β = benevolence factor

Empathy grows at a rate proportional to the net excess of cooperation over discord, amplified by the agent's own benevolence factor, and scaled by its current empathy level. When cooperation dominates — E accelerates. When discord dominates — E erodes. It is a self-reinforcing system, in either direction.

Roemmele's Proposal — Training Time
dE/dt = β(C – D)E
embed this dynamic into
model weights during training

fine-tuning · RLHF
constitutional AI · DPO
Teach the model to maximize cooperation and minimize discord at the weight level — the deep, expensive path.
OpenStinger's Approach — Inference Time ↗
dE/dt = β(C – D)E
evaluate C and D per response
correct when D > C

Gradient · real-time · drift-aware
no weight updates required
We run the same equation at inference. No training needed. Any model. Any time. β comes from the vault.
E Empathy State tracked by Drift Detector rolling window · alignment score
=
β Benevolence Factor Tier 2 · StingerVault vault depth = β strength
(
C Cooperation Tier 3 · Gradient pass verdicts
D Discord Tier 3 · Gradient soft_flag · hard_block
)

Memory Harness (Tier 1) accumulates the lived experience that makes cooperation possible. Reasoning Harness (Tier 2) distils that experience into β — the agent's benevolence factor. Empathy Harness (Tier 3) measures C and D at every response, computing dE/dt in real time. Together, they implement Roemmele's equation without touching a single weight.

Get Running

Sting in 3 commands.

Python 3.10+. Docker. Any OpenAI-compatible inference API. That's all.

bash
# 1. Clone and install
git clone https://github.com/srikanthbellary/openstinger.git
cd openstinger && pip install -e ".[dev]"

# 2. Configure interactively
#    prompts: LLM provider · API key · agent name · embedding provider · profile dirs
#    v0.8: select "ollama" for fully local embeddings (nomic-embed-text, mxbai-embed-large)
openstinger-cli init

# 3. Launch — FalkorDB + browser UI + Tier 1 MCP server
docker compose up -d
python -m openstinger.mcp.server

# Tier 2: vault + knowledge + namespace management
python -m openstinger.scaffold.mcp.server

# Tier 3: full alignment + empathy harness
python -m openstinger.gradient.mcp.server
Full documentation →
Architecture

Runs beside your agent.
Never inside it.

OpenStinger is a pure MCP server. Your agent calls its tools natively — no wrappers, no SDK lock-in, no framework dependency.

topology
OpenClaw · Nanobot · ZeroClaw · NanoClaw · PicoClaw · DeerFlow · Qwen-Agent · LangGraph · Claude Code · Cursor
    └──────────────────────────────────────┬──────────────────────────────────────────────────────┘
                  Model Context Protocol  ·  SSE  ·  http://localhost:8766/sse
                            │
                            ▼
OpenStinger MCP Server  (Python process, runs on your machine)
    ├── Tier 1  memory_query · memory_add · memory_search  ····· 11 tools
    ├── Tier 2  vault_promote_now · knowledge_ingest · namespace_*   11 tools
    └── Tier 3  gradient_alignment_score · ops_status · drift_status  8 tools
         │                                                    ────────────────
         │                                                    30 tools total
         ├── FalkorDB    (temporal graph · knowledge vault · vector indexes)
         ├── PostgreSQL  (ingestion jobs · alignment events · agent registry)
         └── vault/      (markdown notes · human-editable · SHA-256 synced)
Production & Enterprise

The only *Claw memory system
with a queryable audit trail.

Every episode, entity, classification decision, and alignment event is logged to PostgreSQL — ready for dashboards, audits, and compliance reports. Not exported on request. Always on. Always queryable.

People & PII
SELECT name, entity_type,
  episode_count
FROM entity_registry
WHERE entity_type = 'PERSON'
ORDER BY episode_count DESC;

Who has this agent's memory touched?

Alignment Audit
SELECT verdict, COUNT(*) AS n
FROM alignment_events
WHERE evaluated_at > NOW()
  - INTERVAL '7 days'
GROUP BY verdict;

Alignment verdict distribution this week.

Knowledge Health
SELECT category,
  COUNT(*) FILTER
  (WHERE stale = false) AS active,
  ROUND(AVG(confidence),2)
FROM vault_notes GROUP BY 1;

Active knowledge confidence by category.

OpenStinger logs every ingestion job, entity merge decision, vault classification, and alignment evaluation to a 12-table PostgreSQL schema. Connect any BI tool — Metabase, Grafana, Superset — and get full operational visibility with zero additional instrumentation.

Autonomous agents are waking up — but they're still sleepwalking.
They hallucinate facts. They drift from their values. They forget who they are.
When an agent goes wrong, it says: "Pinch me. I must be dreaming."

Pinch me.
OpenStinger doesn't pinch. It stings.

Hallucinations aren't just errors. They're liabilities.
The harness that forces agents to face reality — so you don't have to face the consequences.

Precision over hype. Memory over amnesia. Alignment over drift.
One memory layer. Every agent framework.
OpenClaw · Nanobot · ZeroClaw · NanoClaw · PicoClaw · Claude Code · Cursor · Qwen-Agent · DeerFlow · LangGraph

OpenStinger.com — Grounding the Autonomous Era.