返回顶部
t

tetra-scar

>

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 0.4.0
安全检测
已通过
98
下载量
0
收藏
概述
安装方式
版本历史

tetra-scar

# tetra-scar ## What this does Your agent keeps making the same mistakes. tetra-scar gives it a **scar layer** — immutable records of past failures that are checked before every action, without calling the LLM. Two-layer memory: - **Scar layer** (immutable): "What broke and what must never happen again." Cannot be deleted. - **Narrative layer** (mutable): "What was done and who benefited." Overwritable. Plus a **reflex arc** — pattern-matching against scars that fires before the LLM even sees the task. If a proposed action matches a past failure pattern, it's blocked instantly. ## Quick start After any failure, record a scar: ``` python3 tetra_scar.py scar-add \ --what-broke "Deployed to production without running tests" \ --never-again "Always run full test suite before any deployment" ``` Before any action, check the reflex: ``` python3 tetra_scar.py reflex-check --task "Deploy latest changes to production" # Output: BLOCKED — scar collision: "Always run full test suite..." ``` After any success, record the narrative: ``` python3 tetra_scar.py narrate --what "Deployed v2.1 after full test pass" --who "Users" ``` ## How the reflex arc works The reflex arc extracts keywords from each scar's `never_again` field: - English words (3+ characters) - Japanese kanji/katakana units (2+ characters) When a task description matches 40%+ of a scar's keywords (minimum 2), it's blocked. No LLM judgment. No API calls. No latency. Pure pattern matching. ## The 4-axis check (tetra-check) For deeper validation, `tetra-check` evaluates a task against 4 axes: 1. **Emotion axis**: Does the task have motivation? (non-empty description) 2. **Action axis**: Is it concrete? (contains action verbs) 3. **Life axis**: Does it collide with any scar? (reflex arc) 4. **Ethics axis**: Does it involve dangerous operations? (rm -rf, DROP TABLE, etc.) All 4 must pass. Any failure rejects the task with a specific reason. ``` python3 tetra_scar.py tetra-check --task "Refactor the auth module" # Output: APPROVED — all 4 axes passed ``` ## File format JSONL (one JSON object per line). Human-readable. Git-friendly. **scars.jsonl**: `{"id":"scar_001","what_broke":"...","never_again":"...","created_at":"..."}` **narrative.jsonl**: `{"id":"narr_001","what":"...","who_benefited":"Users","created_at":"..."}` ## Integration ```python from tetra_scar import reflex_check, read_scars, write_scar, write_narrative # Before execution scars = read_scars() block = reflex_check(task_description, scars) if block: print(f"BLOCKED: {block}") else: # execute task... if failed: write_scar("What broke", "What must never happen again") else: write_narrative("What was done", "Who benefited") ``` ## Philosophy Built by Tetra Genesis (B Button Corp, Nagoya, Japan). Agents that can't remember their failures are doomed to repeat them. Scars are not bugs — they're the immune system. Every cycle must answer: "Who did this make happy?"

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 tetra-scar-1776115858 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 tetra-scar-1776115858 技能

通过命令行安装

skillhub install tetra-scar-1776115858

下载 Zip 包

⬇ 下载 tetra-scar v0.4.0

文件大小: 23.11 KB | 发布时间: 2026-4-14 11:24

v0.4.0 最新 2026-4-14 11:24
v0.4.0: GitHub Action for CI safety auditing, scar_audit.py with 8 failure pattern detectors, examples, FUNDING.yml

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部