Demos

Worked examples showing Parseltongue in action. Each demo is a self-contained project.
pgmd demos are for normal people (except the engine one). py and pltg demos are for engineers.

pgmd AI2AI Investment Memo

Three notebook patterns — standalone, explicit, implicit — analyzing a Series A investment memo. Shows facts with verified quotes, cross-document derivation, and taint tracking.

py Apple Arithmetic

Build Peano arithmetic from observational field notes about counting physical objects, then apply it to an orchard harvest inventory. Starts with a completely empty system, introduces symbols as terms, states parameterized axioms grounded in evidence, and derives concrete theorems via :bind — all in successor notation.

pltg Apple Arithmetic (.pltg)

Same orchard arithmetic, but loaded entirely through .pltg files with an empty initial environment. Proves the loader bootstraps Peano notation, axioms, imports, and derives from scratch — no Python-side setup needed.

pltg Apple Arithmetic with Variadic Splats (?...)

Same orchard, same ground truth — but axioms now use ?... splat patterns for variadic operations: sum-all, count-gt, all-gt. No more nested binary ops: (sum-all a b c d) replaces (+ (+ (+ a b) c) d).

py Biomarker Evidence Conflict

Two papers report on fecal calprotectin as a diagnostic marker for IBD. Paper A supports its diagnostic value (high sensitivity). Paper B challenges its specificity (elevated in non-IBD conditions). The system ingests both, derives contradictory conclusions, and flags the conflict.

py Code Implementation Checks

Extracting facts from a Python authentication module and verifying internal consistency. Shows how the system catches both genuine code properties and fabricated claims about behavior that doesn't exist in the source.

pltg Biopharma Data Governance — Cross-Layer Consistency

A biopharma company maintains three layers of data governance: 1. Technical catalog (CSVs) — what actually exists in the data platform 2. Contracts (.md) — legal agreements with external data providers 3. Business catalog (.md) — business-facing data product descriptions

pltg Deferred Directives

run-on-entry blocks only fire when a file is the entry point. A library's deferred block is skipped on import, but executes when loaded directly — enabling self-tests and setup that don't pollute importers.

py Documentation Validation

A library README contains several internally inconsistent claims: the config table says max_sessions=10 but no code or spec backs it up, the security section makes unverifiable audit claims, and the session management section contradicts itself about hashing. Parseltongue extracts facts and catches every inconsistency.

pgmd Engine Self-Inspection

The parseltongue engine inspects itself — loading its own formal specification (core.pltg) and rendering an interactive notebook that shows the engine's structure, consistency layers, error classification, and diff mechanism.

pltg Entry Mocks

Self-contained unit tests using let + mocks. A module rebinds forward-declared primitives to mock values via run-on-entry, turning formal expressions into computable self-tests — only when loaded as the entry point.

py Custom Effects

User-defined side effects passed at construction time. The DSL calls (load-data "name" "path") as a top-level directive, triggering a custom Python callback. Effects bridge the DSL and the host environment — any callable can become an operator.

py Revenue Reports

Company performance analysis from multiple financial documents. The system grows from a minimal base as evidence is ingested, with quote verification catching fabricated claims, taint propagation marking downstream derivations, and manual override correcting specific facts.

py Self-Healing Probes

The entire analysis flow — loading documents, checking consistency, diagnosing failures, and recovering — is written in Parseltongue DSL. Python only registers primitive effects and feeds the script. Effects become the instruction set for self-healing probes.

py Code-Specification Cross-Validation

An API specification says tokens expire in 30 minutes, max 3 sessions, and MD5 must not be used. The implementation has 1-hour expiry, 5 sessions, and uses MD5 for session IDs. Parseltongue catches every divergence.