Skip to main content

Symbolic cognition engine for epistemic drift, rupture detection, and realignment.

Project description

Cognize

Programmable cognition for Python systems

Version


Overview

Cognize is a lightweight cognition engine for Python systems.
It tracks belief (V) vs. reality (R), manages misalignment memory (E), and detects symbolic rupture (Θ).
Now supports runtime injection of programmable logic for collapse, realignment, and adaptive thresholds.

Built for agents, simulations, filters, and symbolic drift-aware systems.


Features

  • Cognitive projection engine (EpistemicState)
  • Drift tracking with misalignment memory
  • Programmable inject_policy(...) support
  • Prebuilt logic in cognize.policies (collapse, realign, threshold)
  • Vector-compatible input support
  • Trace export (.json, .csv) for audit or training
  • Lightweight, domain-agnostic, DSL-ready

Installation

pip install cognize

Core Concepts

Symbol Meaning
V Belief / Projection
R Reality Signal
Distortion
Θ Rupture Threshold
E Misalignment Memory

Quick Usage

from cognize import EpistemicState

# Initialize agent
agent = EpistemicState(V0=0.0, threshold=0.35)

# Feed signals
for R in [0.1, 0.3, 0.6, 0.8]:
    agent.receive(R)
    print(agent.summary())

Programmable Injection (v0.1.2+)

from cognize.policies import (
    collapse_soft_decay_fn,
    realign_tanh_fn,
    threshold_adaptive_fn
)

agent.inject_policy(
    collapse=collapse_soft_decay_fn,
    realign=realign_tanh_fn,
    threshold=threshold_adaptive_fn
)

agent.receive(0.5)
print(agent.summary())

Exporting Trace

agent.export_json("trace.json")
agent.export_csv("trace.csv")

Example Output

{
  "t": 2,
  "V": 0.41,
  "R": 0.6,
  "delta": 0.19,
  "Θ": 0.35,
  "ruptured": false,
  "symbol": "⊙",
  "source": "default"
}

Full Cognize User Guide


License

Licensed under the Apache License 2.0.


© 2025 Pulikanti Sashi Bharadwaj
All rights reserved.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cognize-0.1.2.tar.gz (12.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cognize-0.1.2-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file cognize-0.1.2.tar.gz.

File metadata

  • Download URL: cognize-0.1.2.tar.gz
  • Upload date:
  • Size: 12.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for cognize-0.1.2.tar.gz
Algorithm Hash digest
SHA256 20684cc4c8f65f3d4d24f235c77777de3e2dfd115bad1d47fedebe3487a4a514
MD5 1387de12c75ef9624bdff5262f32458c
BLAKE2b-256 e6039336c7bbde3b6b8aa6acb8a36960d0c14512a0ac5de36830390b1319bcf3

See more details on using hashes here.

File details

Details for the file cognize-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: cognize-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 10.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for cognize-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 e182c8b23609e800b86ea5fb77161b6db864c3cf03a1e40e65ff38acf0b2e7c7
MD5 c9321f0223c946025170cbfe8a4967e7
BLAKE2b-256 9f47b365d6e90040e716daf793b7d6d3931beb9474c4a1908f5a61560adaa4e6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page