Ghost cognitive engine
Project description
ghocentric-ghost-engine
A lightweight, deterministic internal state engine for experimenting with persistent state, temporal dynamics, and emergent behavior in interactive systems.
Ghost is NOT a language model and NOT a decision-maker. It is a minimal, stateful core designed to accumulate interaction signals over time and expose them in a clean, predictable, and serialization-safe way.
This project is intentionally focused on architecture and correctness first. Surface features, integrations, and higher-level reasoning systems are expected to be layered on top of the core in later versions.
INSTALLATION
pip install ghocentric-ghost-engine
BASIC USAGE
from ghost.engine import GhostEngine
engine = GhostEngine()
engine.step({ "source": "npc_engine", "intent": "threat", "actor": "player", "target": "guard", "intensity": 0.5, })
state = engine.state() print(state["npc"]["threat_level"])
Ghost mutates state only via explicit step() calls.
All public-facing state is exposed as dictionaries and is safe to serialize.
CORE DESIGN PRINCIPLES
• Deterministic, persistent state core
• Explicit state transitions via step()
• No hidden execution or side effects
• Public API remains dict-based and serialization-safe
• Internal typed representations may exist but never leak
• Designed to be expanded around a stable core, not bloated prematurely
Ghost does NOT:
• Choose actions
• Generate dialogue
• Interpret semantics
• Store memory implicitly
Those behaviors belong to external systems that consume Ghost’s state.
STABILITY & GUARANTEES (v0.2.0)
Ghost Engine v0.2.0 establishes the first fully functional deterministic interaction core.
The engine now guarantees:
• Deterministic runtime behavior (same inputs → same outputs)
• Explicit, bounded state mutation per step
• Actor state updates across interactions
• Pairwise relationship mutation with symmetric consistency
• Bounded cascade propagation across interaction networks
• Global tension tracking across the system
• Full JSON-safe serialization of engine state
These guarantees hold under repeated execution and adversarial input.
ARCHITECTURAL EXPANSION (v0.2.0)
Version 0.2.0 introduces the first fully operational multi-agent interaction model on top of Ghost’s deterministic state core.
New capabilities include:
Agent State Mutation
Agents now maintain evolving internal state (mood, tension, last intent) and react deterministically to interaction signals.
Relationship Graph
Pairwise relationships now evolve through explicit interaction deltas, supporting long-term system memory without hidden state.
Bounded Cascade Propagation
Signals propagate deterministically through an agent’s local interaction network with strict bounds to prevent runaway behavior.
Global System Tension
The engine now tracks a shared global tension signal representing aggregate interaction pressure across the system.
Why This Matters
These changes allow Ghost-based systems to scale toward:
• large multi-agent simulations
• social interaction modeling
• emergent behavioral systems
• game-world simulation engines
while preserving the deterministic, explicit-state philosophy of the core.
TESTING PHILOSOPHY
Ghost uses property-based testing and invariant validation rather than relying solely on example-driven tests.
Core validation includes:
• determinism verification
• clamping and bounded-state guarantees
• serialization safety validation
This ensures the engine remains correct and predictable as new systems and features are layered on top in future versions.
PROJECT STRUCTURE
ghost/ core engine modules
tests/ invariant and runtime tests
npc_demo.py experimental sandbox for new ideas
pyproject.toml build and packaging configuration
Demos are intentionally minimal and act as experimental sandboxes.
They are not representative of Ghost’s final scope.
STATUS
Ghost Engine remains in early development.
As of v0.2.0:
• The deterministic interaction core is stable
• APIs may still evolve
• Higher-level systems remain intentionally external
This project is intended as a foundation for experimentation, research, and future system design rather than a finished product.
RELEASE HISTORY
v0.2.0
• Introduced real agent state mutation
• Added relationship mutation logic
• Implemented bounded cascade propagation
• Achieved deterministic runtime guarantees
• Achieved JSON-safe serialization baseline
v0.1.3
• AgentRegistry and neighbor indexing for scalable interaction graphs
v0.1.2
• Formal invariant verification using property-based testing
v0.1.1
• Core threat accumulation improvements
v0.1.0
• Initial public architecture release
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ghocentric_ghost_engine-0.2.0.tar.gz.
File metadata
- Download URL: ghocentric_ghost_engine-0.2.0.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8c5cdda01e30f67628a3e5e29482b959e0c5ef9388dae9892b2014e61a723eb5
|
|
| MD5 |
6cb4772872258e34b683d432a1624f3e
|
|
| BLAKE2b-256 |
389edb81aebf1502bececd6d0a3ec21045a9598f31ec339a5a144416ef5a195e
|
Provenance
The following attestation bundles were made for ghocentric_ghost_engine-0.2.0.tar.gz:
Publisher:
publish.yml on GhoCentric/ghost-prototype
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ghocentric_ghost_engine-0.2.0.tar.gz -
Subject digest:
8c5cdda01e30f67628a3e5e29482b959e0c5ef9388dae9892b2014e61a723eb5 - Sigstore transparency entry: 1058518093
- Sigstore integration time:
-
Permalink:
GhoCentric/ghost-prototype@a691ccf6abbcabe98e8fd52a94bdf12c81d12eeb -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/GhoCentric
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@a691ccf6abbcabe98e8fd52a94bdf12c81d12eeb -
Trigger Event:
push
-
Statement type:
File details
Details for the file ghocentric_ghost_engine-0.2.0-py3-none-any.whl.
File metadata
- Download URL: ghocentric_ghost_engine-0.2.0-py3-none-any.whl
- Upload date:
- Size: 8.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c3f57e495f5051c70e7fb315eedf258a114ff35dd334e2a5a82af15e842bf9cf
|
|
| MD5 |
17a47a280ead6d441a0a4dba7cd4f93e
|
|
| BLAKE2b-256 |
7e1fd7870381090231a39a788ff8b73f824ef02f2e1c034024c2515c4188d584
|
Provenance
The following attestation bundles were made for ghocentric_ghost_engine-0.2.0-py3-none-any.whl:
Publisher:
publish.yml on GhoCentric/ghost-prototype
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ghocentric_ghost_engine-0.2.0-py3-none-any.whl -
Subject digest:
c3f57e495f5051c70e7fb315eedf258a114ff35dd334e2a5a82af15e842bf9cf - Sigstore transparency entry: 1058518096
- Sigstore integration time:
-
Permalink:
GhoCentric/ghost-prototype@a691ccf6abbcabe98e8fd52a94bdf12c81d12eeb -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/GhoCentric
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@a691ccf6abbcabe98e8fd52a94bdf12c81d12eeb -
Trigger Event:
push
-
Statement type: