[PR #60] Add 灵犀 (Mind Compass) — a typed-decision mind-state engine #60

Open
opened 2026-10-15 17:59:47 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/SillyTavern/SillyTavern-Content/pull/60
Author: @scd13150
Created: 9/22/2026
Status: 🔄 Open

Base: main ← Head: add-mind-compass


📝 Commits (1)

  • ec9502b Add 灵犀 (Mind Compass) extension

📊 Changes

2 files changed (+14 additions, -0 deletions)

View changed files

📝 extensions.json (+7 -0)
📝 index.json (+7 -0)

📄 Description

Adding 灵犀 (Mind Compass), an extension that separates language generation from mind-state adjudication.

What it does

The host chat model keeps writing prose. A second, non-generative model (TypeSafe Jev, System One) answers a fixed bundle of typed questions asynchronously:

Judgement Primitive
boundary violation, superficial flattery, conversational wit, emotional validation, vulnerability exposure Noul
inner expression (28 GoEmotions labels) Choice
power dynamic (0–4) Score

Code then owns a deterministic two-track dynamics engine — leaky-filter momentum, onion-model trust penetration, stage gating, affinity/defense arithmetic — and writes the results to SillyTavern variables, /expression-set, world-info injection, and per-card persistence.

The problem it addresses: a model asked to roleplay and track a relationship will inflate the relationship, because the same generation that produces flattering prose also produces the flattering score. Moving that judgement to a separate typed-decision model removes the coupling.

Submission requirements

  • Open source, libre license — AGPL-3.0, full text in the repository LICENSE
  • Compatible with the current release — loaded and exercised on a clean install
  • Documented — README covers features, architecture, both install methods, and configuration, in Chinese and English
  • No server plugin required — requires is empty; pure ES modules calling the API directly, so no local Python/Node/Docker

Files are at the repository root, so git clone into extensions/third-party/ works directly.

Why the key handling is worth a look

The API key is never written to settings.json and never exported with a character card. It goes to the host's own secret vault via /api/secrets, with a masked input. In an ecosystem where character cards are routinely shared as files, that is the difference between a key and a leak.

Notes on the two changed files

index.json was regenerated the same way generate_index_json.py builds it: the assets prefix plus every extensions.json entry. I did not run that script directly, because it walks assets/, which is ~136 MB and therefore absent from the sparse checkout I used — running it there silently produced a 4-entry index, dropping all 94 asset entries. The rebuild method was verified to reproduce the committed index.json byte-for-byte before this edit, so the only difference is the appended entry.

extensions.json is hand-formatted with a 4-space indent rather than json.dumps(indent=2) output, so I edited it as text instead of regenerating it, to avoid reformatting all 66 existing entries. The diff is 7 added lines and nothing else.

One judgement call worth flagging: the name field is 灵犀 (Mind Compass), which introduces the first non-ASCII characters in either JSON file. Happy to change it to Mind Compass (灵犀) or plain ASCII if you prefer to keep those files ASCII-only.

Repository: https://github.com/scd13150/st-Mind-Compass


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/SillyTavern/SillyTavern-Content/pull/60 **Author:** [@scd13150](https://github.com/scd13150) **Created:** 9/22/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `add-mind-compass` --- ### 📝 Commits (1) - [`ec9502b`](https://github.com/SillyTavern/SillyTavern-Content/commit/ec9502b2b917e0d77ba24cce4c7957e6dfd6c1fd) Add 灵犀 (Mind Compass) extension ### 📊 Changes **2 files changed** (+14 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `extensions.json` (+7 -0) 📝 `index.json` (+7 -0) </details> ### 📄 Description Adding 灵犀 (Mind Compass), an extension that separates language generation from mind-state adjudication. ## What it does The host chat model keeps writing prose. A second, **non-generative** model (TypeSafe Jev, System One) answers a fixed bundle of typed questions asynchronously: | Judgement | Primitive | | --- | --- | | boundary violation, superficial flattery, conversational wit, emotional validation, vulnerability exposure | Noul | | inner expression (28 GoEmotions labels) | Choice | | power dynamic (0–4) | Score | Code then owns a deterministic two-track dynamics engine — leaky-filter momentum, onion-model trust penetration, stage gating, affinity/defense arithmetic — and writes the results to SillyTavern variables, `/expression-set`, world-info injection, and per-card persistence. **The problem it addresses:** a model asked to roleplay *and* track a relationship will inflate the relationship, because the same generation that produces flattering prose also produces the flattering score. Moving that judgement to a separate typed-decision model removes the coupling. ## Submission requirements - [x] **Open source, libre license** — AGPL-3.0, full text in the repository `LICENSE` - [x] **Compatible with the current release** — loaded and exercised on a clean install - [x] **Documented** — README covers features, architecture, both install methods, and configuration, in Chinese and English - [x] **No server plugin required** — `requires` is empty; pure ES modules calling the API directly, so no local Python/Node/Docker Files are at the repository root, so `git clone` into `extensions/third-party/` works directly. ## Why the key handling is worth a look The API key is never written to `settings.json` and never exported with a character card. It goes to the host's own secret vault via `/api/secrets`, with a masked input. In an ecosystem where character cards are routinely shared as files, that is the difference between a key and a leak. ## Notes on the two changed files **`index.json`** was regenerated the same way `generate_index_json.py` builds it: the assets prefix plus every `extensions.json` entry. I did **not** run that script directly, because it walks `assets/`, which is ~136 MB and therefore absent from the sparse checkout I used — running it there silently produced a 4-entry index, dropping all 94 asset entries. The rebuild method was verified to reproduce the committed `index.json` **byte-for-byte** before this edit, so the only difference is the appended entry. **`extensions.json`** is hand-formatted with a 4-space indent rather than `json.dumps(indent=2)` output, so I edited it as text instead of regenerating it, to avoid reformatting all 66 existing entries. The diff is 7 added lines and nothing else. One judgement call worth flagging: the `name` field is `灵犀 (Mind Compass)`, which introduces the first non-ASCII characters in either JSON file. Happy to change it to `Mind Compass (灵犀)` or plain ASCII if you prefer to keep those files ASCII-only. Repository: https://github.com/scd13150/st-Mind-Compass --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
SillyTavern/SillyTavern-Content#60
No description provided.