Skip to main content

Shared knowledge atlas built on PTEX nonce-addressed textures

Project description

Amni-Prism

Shared knowledge atlas built on PTEX nonce-addressed textures. Every fact gets a unique GF(17) nonce — contribute knowledge, it deduplicates automatically, and the atlas grows.

Install

pip install -e .

Quick Start

import prism

# Contribute knowledge
prism.contribute_text('./codex', 'The speed of light is 299792458 m/s', domain='physics')

# Query it back
result = prism.query_text('./codex', 'The speed of light is 299792458 m/s')

# Search by keyword
hits = prism.search_keyword('./codex', 'speed of light')

CLI

# Contribute text
prism contribute "The speed of light is 299792458 m/s" -d physics

# Search
prism search "speed of light"

# Small model proposes a fact
prism propose "Water boils at 100C at sea level" -d physics --confidence 0.8

# Large model verifies pending proposals
prism pending
prism verify

# Scrape text for facts
prism scrape --file article.txt --source "https://en.wikipedia.org/wiki/Light"

# Stats
prism stats

How It Works

  1. GF(17) Nonces — Every word/line/block gets a unique nonce in GF(17) finite field space. Same content = same nonce = automatic dedup.
  2. PTEX Storage — Knowledge stored as nonce-addressed texture maps. Vocab in NLX format, hierarchical tiers in HNA format.
  3. Content-Hash Dedup — SHA-256 content hashing ensures no duplicates across contributors.
  4. Two-Tier Verification — Small models propose (~50 tokens), large models verify (~20 tokens). ~70 tokens per verified fact.
  5. NDJSON Manifests — Append-only JSON-lines manifests are git-merge-friendly. No merge conflicts.

Contributing

# Fork, clone, then:
pip install -e .
prism contribute "Your knowledge here" -d general
# Or pipe from stdin:
cat facts.txt | prism contribute -d science

Domains

25 built-in domains: code, math, science, history, language, music, art, philosophy, psychology, economics, politics, law, medicine, engineering, technology, education, sports, entertainment, food, travel, nature, religion, mythology, literature, general.

License

MIT

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

amni_prism-0.1.0.tar.gz (21.0 kB view details)

Uploaded Source

Built Distribution

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

amni_prism-0.1.0-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

Details for the file amni_prism-0.1.0.tar.gz.

File metadata

  • Download URL: amni_prism-0.1.0.tar.gz
  • Upload date:
  • Size: 21.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for amni_prism-0.1.0.tar.gz
Algorithm Hash digest
SHA256 f6a62b50f659b735d32841db3f3f45989febda781566763f662fb8d72ad43c45
MD5 e0bd893a2fe938f2aec344c787bb9005
BLAKE2b-256 6cd3222a9153a1104b882d87408e342fed5fd77305ccdd0eb3388558d0ae8078

See more details on using hashes here.

File details

Details for the file amni_prism-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: amni_prism-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 20.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for amni_prism-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a22fd162189be4e134dde0e9a00292dbb0664bbda1de83aa11865753115c7b0e
MD5 0f17bf4eb1bc88fec741a7abdad18383
BLAKE2b-256 3acd3c1025857e1f8afb7c696f050942093b8efa3080d517d1efb913a9848581

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