From 4957a233bd5cb27db1d0ba54dee2e4f09731fea9 Mon Sep 17 00:00:00 2001 From: Aaron Stainback Date: Sat, 16 May 2026 00:17:03 -0400 Subject: [PATCH 1/2] chore(b-0359): decompose B-0359 step 1 into B-0552 --- ...em-language-level-confidence-primitives.md | 3 +- ...sharp-computation-expression-2026-05-16.md | 34 +++++++++++++++++++ 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md diff --git a/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md b/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md index 00ae5e0f15..a6e29122f4 100644 --- a/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md +++ b/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md @@ -8,7 +8,8 @@ created: 2026-05-09 last_updated: 2026-05-09 depends_on: [B-0358] classification: research -decomposition: needs-decomposition +decomposition: decomposing +children: [B-0552] owners: [architect] type: feature tags: [type-system, probabilistic, research, language-design, bayesian] diff --git a/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md b/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md new file mode 100644 index 0000000000..6d79badc40 --- /dev/null +++ b/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md @@ -0,0 +1,34 @@ +--- +id: B-0552 +priority: P2 +status: open +title: "Probabilistic type system step 1 — Type-level computation expression for Distributions (F#)" +effort: M +created: 2026-05-16 +last_updated: 2026-05-16 +depends_on: [B-0358] +classification: buildable +decomposition: atomic +owners: [architect] +type: feature +tags: [type-system, probabilistic, research, language-design, bayesian, fsharp] +--- + +# B-0552 — Probabilistic type system step 1: F# Computation Expression + +## What + +Decomposed from B-0359 (Probabilistic type system research arc). +This is step 1: Research Question 1 from the parent row. "Can F#'s type system express 'all returns are distributions' without a language fork? (Computation expressions + custom operators may suffice)". + +## Acceptance Criteria + +- [ ] Implement an F# Computation Expression builder `dist { ... }` that models a probabilistic distribution over values (using ZSet weights as the confidence primitive). +- [ ] Implement `Bind`, `Return`, `ReturnFrom` to allow monadic composition of probabilistic values. +- [ ] Provide proof-of-concept tests demonstrating that sharp types (`bool`) can be lifted into `dist { ... }` and composed without explicitly reverting to sharp conditionals. +- [ ] Determine if this approach allows enforcing `probabilistic: strict` rules at the API boundary. + +## Composes with + +- B-0359 (Parent research arc) +- B-0358 (bool → float API returns) \ No newline at end of file From 90273b6b5216bbfa66347786e3af0b6eeaca5707 Mon Sep 17 00:00:00 2001 From: Aaron Stainback Date: Sat, 16 May 2026 01:25:29 -0400 Subject: [PATCH 2/2] chore(b-0359): fix MD047 trailing newline and update timestamp --- docs/BACKLOG.md | 1 + ...bilistic-type-system-language-level-confidence-primitives.md | 2 +- ...pe-system-step-1-fsharp-computation-expression-2026-05-16.md | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/BACKLOG.md b/docs/BACKLOG.md index 6a02c45d32..aab33e8584 100644 --- a/docs/BACKLOG.md +++ b/docs/BACKLOG.md @@ -590,6 +590,7 @@ are closed (status: closed in frontmatter)._ - [ ] **[B-0546](backlog/P2/B-0546-recast-manifesto-framing-to-building-codes-specification-per-kestrel-aaron-correction-2026-05-15.md)** Recast docs/governance/MANIFESTO.md from "manifesto" framing to "building codes" framing per Aaron's correction + Kestrel's reframe — the document is best-practices-with-default-moral-oracle, not ideological commitment - [ ] **[B-0547](backlog/P2/B-0547-intelligent-compiler-recursive-hkt-clifford-fsharp-fork-roslyn-source-generators-linq-csharp-substrate-representation-2026-05-15.md)** Intelligent compiler — represent antigen-spread / multi-oracle / clearing primitives as recursive HKT in F# fork based on Clifford algebra; compose with Recursive Type Providers + Roslyn Source Generators + LINQ for C# - [ ] **[B-0548](backlog/P2/B-0548-qg-isomorphism-step-1-5-construct-strength-and-a-lifting-2026-05-16.md)** QG isomorphism Step 1.5 — Construct strength θ:M(Ω)→Ω and A-lifting Ã:Zeta→Zeta for type-correct M/A coherence laws +- [ ] **[B-0552](backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md)** Probabilistic type system step 1 — Type-level computation expression for Distributions (F#) ## P3 — convenience / deferred diff --git a/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md b/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md index a6e29122f4..8168805dfc 100644 --- a/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md +++ b/docs/backlog/P2/B-0359-probabilistic-type-system-language-level-confidence-primitives.md @@ -5,7 +5,7 @@ status: open title: "Probabilistic type system — language-level confidence primitives (Hejlsberg/Syme lineage)" effort: XL created: 2026-05-09 -last_updated: 2026-05-09 +last_updated: 2026-05-16 depends_on: [B-0358] classification: research decomposition: decomposing diff --git a/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md b/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md index 6d79badc40..b6773879ce 100644 --- a/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md +++ b/docs/backlog/P2/B-0552-probabilistic-type-system-step-1-fsharp-computation-expression-2026-05-16.md @@ -31,4 +31,4 @@ This is step 1: Research Question 1 from the parent row. "Can F#'s type system e ## Composes with - B-0359 (Parent research arc) -- B-0358 (bool → float API returns) \ No newline at end of file +- B-0358 (bool → float API returns)