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", "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.1.2)
Ghost Engine v0.1.2 establishes a formally verified core protected by property-based testing using Hypothesis.
Verified invariants include:
- Threat level is never negative
- Threat accumulation is monotonic with respect to input intensity
- Threat decays monotonically in the absence of new input
- Actor-specific threat memory remains consistent
- Internal step types never leak into public engine state
- Engine state mutates only through explicit step() calls
These guarantees hold under randomized and adversarial input.
TESTING PHILOSOPHY
Ghost uses property-based testing to validate behavioral invariants rather than relying solely on example-driven tests.
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 property-based 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 is in early development. The core architecture is stable as of v0.1.2, but APIs may evolve as new layers are added.
This project is intended as a foundation for experimentation, research, and future system design rather than a finished product.
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.1.2.tar.gz.
File metadata
- Download URL: ghocentric_ghost_engine-0.1.2.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9494e25d1c87a968ec04d0acd69a47daef67a7bc2e4fdbbe07fc15909585f231
|
|
| MD5 |
eb7548e7d9180ceac5cd40e383ec885d
|
|
| BLAKE2b-256 |
d495328f5ca081b75c6ef23893d693e2b5d0869df4e2a13bbe11d0124b1c5d7b
|
Provenance
The following attestation bundles were made for ghocentric_ghost_engine-0.1.2.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.1.2.tar.gz -
Subject digest:
9494e25d1c87a968ec04d0acd69a47daef67a7bc2e4fdbbe07fc15909585f231 - Sigstore transparency entry: 856280172
- Sigstore integration time:
-
Permalink:
GhoCentric/ghost-prototype@422c98aebc9e5c22579ce4c98a4e56a0e64556f7 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/GhoCentric
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@422c98aebc9e5c22579ce4c98a4e56a0e64556f7 -
Trigger Event:
push
-
Statement type:
File details
Details for the file ghocentric_ghost_engine-0.1.2-py3-none-any.whl.
File metadata
- Download URL: ghocentric_ghost_engine-0.1.2-py3-none-any.whl
- Upload date:
- Size: 5.9 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 |
7fe1deef0ba023e1dba7b228ecc84541ccabb3e0cc08a8a96a403ef30b29e76a
|
|
| MD5 |
a028f8f2dbf0900ae8e813c4a3c5c96d
|
|
| BLAKE2b-256 |
5956ec5bf678c180ec56d68f7102202461fb3e41d24e3db62f2e61bbf0e9af93
|
Provenance
The following attestation bundles were made for ghocentric_ghost_engine-0.1.2-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.1.2-py3-none-any.whl -
Subject digest:
7fe1deef0ba023e1dba7b228ecc84541ccabb3e0cc08a8a96a403ef30b29e76a - Sigstore transparency entry: 856280226
- Sigstore integration time:
-
Permalink:
GhoCentric/ghost-prototype@422c98aebc9e5c22579ce4c98a4e56a0e64556f7 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/GhoCentric
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@422c98aebc9e5c22579ce4c98a4e56a0e64556f7 -
Trigger Event:
push
-
Statement type: