All 57 Entries

The Pattern Programming Language: Programs as Port-Type-Compatible Pattern Graphs Across 37 Target Languages

February 11, 2026 v1.1 language specification representing programs as ~200-byte binary-serialized DAGs (.gp) with a 5-class Effect System, Port Semantic Contracts, and 37-language codegen—with November 25, 2026 errata fixing its 55.1% port-compatibility share and Any-wildcard soundness caveat.

David Charlot • • Addendum & Errata: Nov 25, 2026 • 6 min read • Glossary • Verification & AI-Use Disclosure
pattern-lang typed-dags effect-systems design-by-contract polyglot-codegen historical-whitepaper

Part I: Contemporary Historical Summary (As Written in February 2026)

Historical Source Provenance (Original Date: February 11, 2026): David Jean Charlot, PhD · Open Interface Engineering. Preserved from PATTERN_LANGUAGE_SPECIFICATION v1.1 (Download Original Feb 2026 PDF).

Thesis: Programs as Directed Acyclic Graphs, Text as a Target View

Completed on February 11, 2026 (one day prior to our public essay on Christopher Alexander’s architectural patterns), the Pattern Programming Language v1.1 Specification inverted traditional source representation: the canonical artifact is a binary-serialized, acyclically checked Directed Acyclic Graph (.gp, averaging ~200 bytes for a 4-node pipeline) that emits source code across 37 target programming languages.

Port-Type Algebra & Five NodeKind Primitives

Every .gp graph wires directed ports over structural GraphType / SynthType descriptors (Int, Float, Bool, Text, Bytes, List<T>, Map<K, V>, Struct, plus a dynamic Any wildcard port descriptor) and 5 NodeKind variants:

  1. Input(port_spec) and Output(port_spec) — graph boundary port declarations;
  2. Literal(const_val) — inline typed constants;
  3. Pattern(pattern_id) — catalog nodes (800 core patterns + dyn: extensions);
  4. SubGraph(graph_hash) — content-addressed hierarchical subgraphs (71 multi-node composite recipes in v1.1).

Evaluating all 413,449 ordered (output_port, input_port) pairs across the 800-pattern core catalog yielded 227,653 port-type-compatible (with Any wildcard) pairings and 185,796 incompatible pairings—printed in the original February 2026 table as "54.9%" (Superseded / corrected to 55.06% [55.1%] compatible + 44.94% [44.9%] incompatible = 100% — see Nov 25, 2026 Errata below).

Stage-Splitting Parallelism via the 5-Class Effect System

Pattern v1.1 labeled each node with one of five effect classes and applied Kahn’s topological sort + an Effect Conflict Matrix to partition independent nodes into parallel vs. serialized execution waves:

5-Class Effect System:
  Pure  ·  IO  ·  State(resource_id)  ·  Concurrent  ·  Nondeterministic

Stage-Splitting Conflict Rules:
  Pure        x  Any Effect        -> Parallelizable whenever data-independent
  State(r_1)  x  State(r_2)        -> Parallelizable when resource_id r_1 != r_2;
                                      Serialized when r_1 == r_2
  IO          x  IO                -> Serialized (preserves observable IO ordering)
  IO          x  Concurrent        -> Serialized
  Concurrent  x  Concurrent        -> Serialized barrier unless isolated in disjoint SubGraphs

Port Semantic Contracts (requires / ensures Predicates)

Because structural port types (List<Int> -> List<Int>) do not track ordering or domain invariants—for instance, wiring hash_dedup(List<Int>) directly into binary_search(List<Int>, Int) destroys sort order while still matching List<Int>—Pattern v1.1 attached finite Port Semantic Contracts (requires / ensures sets over Sorted, Unique, NonEmpty, Normalized, Positive, NonNegative, Bounded):

Upstream NodeUpstream ensuresDownstream NodeDownstream requiresGraph Construction Verdict
hash_dedup{ Unique } (omits Sorted)binary_search{ Sorted }ContractViolation rejected at build time
merge_sort{ Sorted }sorted_dedup{ Sorted } -> ensures { Sorted, Unique }Valid (2-stage contract chain)
sorted_dedup{ Sorted, Unique }binary_search{ Sorted }Valid (Contract Satisfied)

Arithmetic & Type-Soundness Errata (2026-11-25 Audit)

  1. Pairwise Percentage Fix (227,653 / 413,449 = 55.06% [55.1%], NOT 54.9%):
    • Dividing 227,653 compatible port pairs (numerator) by 413,449 total ordered pairs (denominator) equals 0.550619... = 55.06% (55.1%), while the remaining 185,796 / 413,449 incompatible pairs equal 0.449380... = 44.94% (44.9%), summing cleanly to 100% (55.06% + 44.94% = 100%). The February 2026 PDF mistakenly printed 54.9% (100% - 45.1%, transposing the tenths digit of 44.94%).
  2. Why "Port-Type-Compatible (with Any Wildcard)" Replaces "Type-Safe" (Non-Transitivity & Unsoundness of Any):
    • In Pattern v1.1’s port matcher, the dynamic wildcard type Any matched every concrete GraphType bidirectionally (T ~ Any and Any ~ U for all T, U). As established in gradual-typing theory (Siek & Taha, 2006), consistency ~ with Any is not transitive: an Int output wired into an Any pass-through node wired into a Text consumer passes pairwise port checks (Int ~ Any and Any ~ Text) while producing an ill-typed Int -> Text mismatch in statically typed targets (Rust, C, Haskell) or a runtime type error in dynamic targets (Python, JS) unless explicit runtime cast/blame guards are inserted!
    • Furthermore, the 55.1% compatible share is substantially inflated by Any-typed generic utility ports (identity, print, container wrappers). Accordingly, we replace "type-safe pairings" with "port-type-compatible (with Any wildcard)", and note that finite Port Semantic Contracts (Sorted, NonEmpty, etc.) were syntactic tag propagation rules rather than SMT-discharged refinement proofs.
  3. Epistemic & Licensing Status (unmetered, BSL-1.1 / Private Core): Archival PDF (#08) is public at /papers/archive/08-Pattern-Programming-Language.pdf under CC BY-ND 4.0. Public pattern-lang binaries at openIE-dev/pattern-lang ship under BSL-1.1, while full core compiler and 37-language emitter sources reside in private mirror openIE-dev/pattern-lang-core (unreproduced externally).

Chronological Evolution Within OpenIE Research

  1. Sound Typed Graphs, Loops & Machine-Checked VCs (Reality Code Engine (RCE) & RCE-VC): Eliminated unsound bidirectional Any wildcards and pure-DAG acyclicity restrictions (Kahn's sort cannot express stateful event loops or OS kernels), scaling RCE to 2,221 deterministic verification checks backed by machine-checked proof obligations (RCE-VC).
  2. Unifying Language and Tensor DAGs (flowG): Merged .gp dataflow concepts with dtype-explicit, capability-safe FunctionGraph lowering in openIE-dev/flow-g (Apache-2.0).
  3. Empirical Lookup Testing (The Deterministic Null & AI Coding Market): Evaluated zero-parameter deterministic pattern lookup against cloud LLMs under hardware energy counters (reported_j, 9/10 bounded ties, 3.59x repeat-energy reduction).
  • Dennis, J. B., & Misunas, D. P. (1975). A Preliminary Architecture for a Basic Data-Flow Processor. ISCA 1975, 126–132 — foundational formulation of static dataflow program graphs and token-firing semantics.
  • Morrison, J. P. (1994 / 2010). Flow-Based Programming: A New Approach to Application Development. Van Nostrand Reinhold — bounded-port black-box component networks closely foreshadowing .gp graphs.
  • Meyer, B. (1992). Applying “Design by Contract”. IEEE Computer, 25(10), 40–51 — origin of requires / ensures precondition and postcondition software contracts.
  • Plotkin, G., & Pretnar, M. (2009). Handlers of Algebraic Effects. ESOP 2009; Gifford, D. K., & Lucassen, J. M. (1986). Integrating Functional and Imperative Programming (type-and-effect systems for automatic parallelization).
  • Rondon, P. M., Kawaguchi, M., & Jhala, R. (2008). Liquid Types. PLDI 2008, 159–169 — SMT-decidable refinement predicates ({v: List Int | Sorted v}), contrasting with Pattern v1.1’s syntactic finite tag propagation.
  • Siek, J. G., & Taha, W. (2006). Gradual Typing for Functional Languages. Scheme and Functional Programming Workshop 2006 — formal explanation of why bidirectional Any consistency breaks static transitivity and soundness without runtime casts.

Changelog (2026-11-25)

  • Corrected 227,653 / 413,449 from "54.9%" to 55.06% (55.1%) alongside 185,796 / 413,449 = 44.94% (44.9%), summing to 100%.
  • Replaced "type-safe" in title, headlineMetric, and claims with "port-type-compatible (with Any wildcard)" and added an explicit soundness erratum explaining how bidirectional Any matching breaks static type soundness.
  • Disclosed BSL-1.1 binary licensing and private openIE-dev/pattern-lang-core provenance (unreproduced externally), separated Part I from Part II, and cited Dennis & Misunas (1975), Morrison FBP (1994), Meyer (1992), Gifford & Lucassen (1986) / Plotkin & Pretnar (2009), Liquid Types (Rondon et al., 2008), and Siek & Taha (2006).
DC

David Charlot

Open Interface Engineering, Inc. · Signed Provenance · Self-Checked

Archival PDF (#08) public at /papers/archive/08-Pattern-Programming-Language.pdf under CC BY-ND 4.0; Pattern-lang binaries ship under BSL-1.1 at openIE-dev/pattern-lang, while full core sources reside in private mirror openIE-dev/pattern-lang-core (externally unreproduced). Full licensing & AI-use disclosure →

Archival v1.1 specification PDF (#08, Feb 11, 2026); binaries under BSL-1.1 at openIE-dev/pattern-lang; full compiler/codegen core in private mirror openIE-dev/pattern-lang-core (unreproduced externally)

Check the primary artifacts or run an independent replication

Inspect signed provenance manifests, rerun our public Apache-2.0 commodity-hardware replication kits, review our November 25, 2026 outside-review errata, or browse primary manuscripts on the Research Hub.