reaxlll/affect-kit ↗★ 0

affect-kit

Turn timestamped affect annotations into a living emotional state — bands, momentum and residual warmth, not a single number.

Package
affect-kit
Compatibility
Unverified
Version
0.1.0
License
MIT
Last updated
Nov 1, 2026

Install

This plugin has no verified bundle, or compatibility checks failed. Read the repository notes first. Read the full README ↗

7. 配置

DEFAULT_CONFIG 里每个数字都能调,最值得动的是三个:

import { DEFAULT_CONFIG } from "affect-kit";

const cfg = {
  ...DEFAULT_CONFIG,
  halfLifeHours: 72,               // 基线更稳
  fade: { weight: 0.55, fast: 10, slow: 48 },  // 余温记得更久
  hysteresisMinutes: 60,           // 状态更粘
};

词汇校准表(比如把「沉」这个做事状态从 −0.6 折成 −0.15)不在库里——那是各人自己的词表:

compose(entries, now, cfg, { calibrate: { 沉: -0.15, 认真: 0.15 } });