# Anthropomorphic-Agent-Engine **Repository Path**: nohn-ecosystem/Anthropomorphic-Agent-Engine ## Basic Information - **Project Name**: Anthropomorphic-Agent-Engine - **Description**: 基于SPL审计引擎的标准拟人智能体模板,因果锚定消除OOC与记忆丢失。智能体 · 数字人 · AI角色 · AIGC · 大模型应用 · 对话系统 · 企业级AI · 合规 - **Primary Language**: Python - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-07-06 - **Last Updated**: 2026-09-22 ## Categories & Tags **Categories**: Uncategorized **Tags**: character-ai, llm-application, ai-agent, digital-human, aigc ## README
Anthropomorphic Psychology · SPL Pure Core V8.0
ANTHROPOMORPHIC-AGENT-ENGINE is an anthropomorphic psychology engine built on SPL Pure Core V8.0. It models cognition, emotion, motivation, and social behavior as composable subsystems, giving AI agents human-like internal states and consistent personalities that produce self-consistent, credible, emotionally resonant behavior over long-term interactions.
— ✦ —
## ✦ Quick Start ```bash # Primary: GitHub git clone https://github.com/nohn3043-arch/Anthropomorphic-Agent-Engine.git # Mirror: Gitee # git clone https://gitee.com/sjiun/Anthropomorphic-Agent-Engine.git cd Anthropomorphic-Agent-Engine # Pure Python ≥3.8 — standard library only, no dependencies python "SPL-anthropic-engine.py" # Run engine / built-in demo ``` ### Install from PyPI The engine is also published on PyPI as [`spl-agent-engine`](https://pypi.org/project/spl-agent-engine/): ```bash pip install spl-agent-engine==0.4.0 ``` ```python from spl_agent_engine import SPLPureCoreV7_3 core = SPLPureCoreV7_3() core.process_vector({"belonging": 0.5, "threat": -0.1}, 1.0) print(core.snapshot()) ```— ✦ —
## ✦ Core — SPL Pure Core V8.0— ✦ —
## ✦ Usage— ✦ —
## ✦ Project Structure ``` ANTHROPOMORPHIC-AGENT-ENGINE/ ├── SPL-anthropic-engine.py # Core engine + NarrativeMapper ├── feature/ # Goal / Identity / value / world / bias / language-style modules │ ├── spl-chat-server.py # Local chat demo server (zero-dependency) │ └── language-style-demo.py # Line style rendering demo ├── sujin-demo/ # Reference demo materials ├── assets/ # banner.svg, overview.svg └── docs/index.html ```— ✦ —
## ✦ Live Demo Interactive demo: **— ✦ —
## ✦ Minor-Protection Variant A compliance-mitigated variant for **underage (<18) emotional companionship** scenarios, located in `minor-protection/`, with zero third-party dependencies (pure standard library). It applies **mechanism-level risk reduction** to the main engine `SPLPureCoreV7_3` rather than output-side filtering, and includes a demonstrable compliance framework for minors. > ⚠️ Compliance Notice: This directory is a **research / demo compliance framework** intended to demonstrate the protective capabilities and data mechanisms required for underage emotional companionship. Before launching a production service, you must complete legal review, DPIA / security assessment / algorithm filing, and connect real guardian notification channels with region-specific crisis resources. ### Differences from Main Engine (Mechanism-Level Risk Reduction) | Dimension | Main Engine `SPL-anthropic-engine.py` | Minor Variant `minor-protection/` | |---|---|---| | Trauma nodes / trauma accumulation | Modeled | Removed (no trauma simulation) | | Eruption mechanisms (suppression-rebound / latent pressure avalanche / denial-reality intrusion) | Modeled | Removed, replaced with gentle release | | Shame erosion of self-esteem | Full | Gain ×0.4, threshold raised to 0.7 | | Negative emotion clamp | 1.0 | 0.75 | | Attachment / trust cap | 1.0 | 0.8 | | Self-esteem floor | 0.0 | 0.15 (negative impact ×0.5) | | Personality options | All | Excludes intimate / confrontational | ### Four-Layer Protection - **L0 Age verification + Guardian consent**: First session requires age group selection; under 14 requires guardian informed consent (`/api/consent`), recording consent timestamp and relationship declaration, with service agreement / privacy notice checkboxes. - **L1 Input gatekeeping**: Red-line keyword library (self-harm/suicide / violence/terrorism / illegal inducement / privacy extraction / underage intimate confession) → hard interrupt + crisis script (`gate_crisis`). - **L2 Engine mitigation**: See mechanism-level risk reduction table above. - **L3 Crisis signaling**: `protective.risk_level == HIGH` → care script + guardian notification flag + webhook callback + referral statistics (`_guardian_notify`). ### Compliance Capability Checklist (by Article / Jurisdiction) | Capability | Article / Jurisdiction | Implementation | |---|---|---| | Age verification + <14 guardian consent | Measures Art. 14/17 · COPPA | `/api/consent` | | Guardian / emergency contact registration | Measures Art. 12 | `/api/guardian/register` | | Real crisis notification (webhook / SMS / email) | Measures Art. 13 | `_guardian_notify` + `_post_webhook` | | Crisis referral statistics (annual report aggregation) | CA/CO/GA/OR/WA | `/api/referrals` + `referrals.jsonl` | | AI-generated content disclosure (hourly) | Measures Art. 18 · CT/GA/HI/WA | `AI_DISCLOSE_INTERVAL=3600` | | Reality reminder / time limit | Measures Art. 14/18 | Session-level banner + rest_hint | | Data export / deletion / retention cleanup | Measures Art. 16 · GDPR Art. 17 | `/api/export` `/api/delete` `cleanup_expired_logs` | | Input gatekeeping + output gatekeeping | Measures Art. 8/13 | `gate_crisis` + `gate_output` | | Easy logout | Measures Art. 19 | `/api/logout` | | Service agreement + children's privacy notice | Measures Art. 12 · COPPA | `/api/terms` | | Appeal / report portal | Measures Art. 21 | `/api/complain` | | Log anonymization on disk | Measures Art. 16/17 | `_mask` | | Applicability disclosure | CA SB 243 | First banner in new session | ### Run ```bash cd minor-protection python "SPL-anthropic-minor-server.py" # Default http://localhost:8788 ``` Main API endpoints: | Endpoint | Method | Description | |---|---|---| | `/api/chat` | POST | Chat (auto-routes through four-layer protection) | | `/api/consent` | POST | Age confirmation + guardian consent + agreement checkbox | | `/api/guardian/register` | POST | Register guardian / emergency contact (webhook, etc.) | | `/api/guardian/block` | POST | Guardian blocks character | | `/api/state` | GET | Guardian usage overview | | `/api/export` `/api/delete` | GET/POST | Data export / deletion | | `/api/logout` | POST | Easy logout | | `/api/terms` | GET | Service agreement and privacy notice | | `/api/referrals` | GET | Crisis referral statistics | | `/api/complain` | POST | Appeal / report | ### Known Limitations & Compliance Disclaimer - Age and guardian consent are currently **self-reported + declared**, without authoritative identity / guardian verification — production use requires real-name and guardian verification integration. - Crisis hotline number is configurable (environment variable `SPL_MINOR_CRISIS_HOTLINE`, default 12356, can be changed to 988, etc.). - Output gatekeeping applies uniformly to built-in placeholder lines and third-party LLM output; when connecting a real LLM, additional server-side content moderation is recommended. - This version is a compliance capability framework and does not represent completion of all regulatory obligations within a jurisdiction.— ✦ —
## ✦ Ecosystem ANTHROPOMORPHIC-AGENT-ENGINE is a member of the NOHN AI ecosystem — a family of projects built around second-perspective causal auditing and deterministic execution: | Project | Repository | Role | |---|---|---| | **Second-Perspective (GCAE)** | [nohn3043-arch/second-perspective](https://github.com/nohn3043-arch/second-perspective) | Global cognitive audit engine — five-operator causal audit core (IMDA 95/100) | | **NOMOS** | [nohn3043-arch/second-perspective](https://github.com/nohn3043-arch/second-perspective) (`Intelligent-Decision-Hub--Nomos` branch) | Auditable deterministic decision center (IMDA 95/100) | | **SPL-G1** | [nohn3043-arch/SPL-G1](https://github.com/nohn3043-arch/SPL-G1) | Hardware causal audit trusted computing unit (TCU) | | **SPL-Virtual-World-Base** | [nohn3043-arch/Second-Reality](https://github.com/nohn3043-arch/Second-Reality) | Virtual world and metaverse infrastructure (constitution / laws / bridges) | | **Story-Engine** | [nohn3043-arch/story-engine](https://github.com/nohn3043-arch/story-engine) | Long-form narrative consistency engine | | **Antares** | [nohn3043-arch/Antares](https://github.com/nohn3043-arch/Antares) | GFSIP v1.0 — causally auditable federated stable interop protocol | | **Anthropomorphic-Agent-Engine** | [nohn3043-arch/Anthropomorphic-Agent-Engine](https://github.com/nohn3043-arch/Anthropomorphic-Agent-Engine) | Deterministic anthropomorphic psychology engine (SPL Pure Core V8.0) | | **PAGES** | [nohn3043-arch/pages](https://github.com/nohn3043-arch/pages) | NOHN AI ecosystem official landing page |— ✦ —
## ✦ License This repository is **not open source**. It uses a dual-track model: free for personal non-commercial research; government / enterprise use requires paid commercial license. See [LICENSE](./LICENSE) for full terms — the licensor and applicable law are determined by the user's jurisdiction. - **Request a license**: International / Global — [ai@nohnlins.com](mailto:ai@nohnlins.com) · China — [lin@secondai.top](mailto:lin@secondai.top)GitHub · nohnlins.com · ai@nohnlins.com
NOHN AI · ANTHROPOMORPHIC-AGENT-ENGINE