Repository navigation
Project Tom Hagen: fold pipeline types without overload ceilings - #26
Merged
Merged
Conversation
commit: |
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 5, 2026 14:48
ef031fb to
064f111
Compare
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 9, 2026 01:21
064f111 to
6b2572c
Compare
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 9, 2026 01:40
6b2572c to
c1d1acb
Compare
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 9, 2026 01:54
c1d1acb to
4eb4da5
Compare
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 9, 2026 03:23
4eb4da5 to
c61f11a
Compare
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
3 times, most recently
from
September 23, 2026 01:13
f2bc48b to
533256c
Compare
Add compiler diagnostics and materialize merged phase models so public hovers expose concrete model shapes. Co-Authored-By: Jacob Bolda <me@jacobbolda.com>
cowboyd
force-pushed
the
project-tom-hagen-fold
branch
from
September 23, 2026 15:03
533256c to
21e1d0b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
route(),command(), andextend()relied on large overload towers that imposed arbitrary limits on otherwise composable definitions. Larger applications could exceed those limits, while adding more overloads made the public types brittle and expensive to maintain.The replacement must preserve exact inference across static elements, reusable extensions, nested routes, and dynamic checkpoints without filling normal hovers with internal type machinery.
Approach
Treat definition construction as a small type-level interpreter. Each built-in combinator carries an operation describing how it changes the current route, and a variadic fold applies those operations from left to right. Static operations are accumulated in bounded groups and materialized as concrete route, model, child, and phase shapes, which keeps compiler work controlled and public hovers readable.
The runtime remains ordinary immutable function composition. Concrete user combinators compose without registration; only generic transformations whose output depends on their input require
mark(), because TypeScript cannot otherwise apply that higher-order relationship. Tuple inputs retain exact inference, while widened arrays intentionally fall back to a conservative type instead of pretending to know their sequence.