Conversation
Documentation build overview
46 files changed ·
|
1394bd2 to
5d43331
Compare
ba0f980 to
ab7a316
Compare
Rebased onto main: the three wording tables are one, the window branch reads the reduction the way main's walk does, and the tests sit in the parametrized tables. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
ab7a316 to
2759dd7
Compare
|
Rebased onto current |
|
Note The following content was generated by AI. Closed at the author's request, in a sweep of the open PRs. Closed rather than rebased, because the operator surface this branch adds is written in a spelling The facts behind that:
Rebasing it would mean rewriting the operator declaration, the dim rule, the typesetting branch, four examples and three golden constraints against the new names. That is the work of writing it again, without the benefit of starting from what the language looks like today. The feature is still wanted. Generated by Claude Code |
What this changes
sum_forward(<expr>, over=<dim>, within=<n|parameter>[, edge='wrap'][, by=<lookup>])— sums the next n positions along an axis, wheresum_backsums the last n.operators.py,dimensions.py,degree.py— the operator, its dim rule, its place among the reductions.typesetting/walk.py— one branch renders both windows;_WINDOWSdecides only which side of the lag operator the written index falls on.sum_forward,_by_parameter,_wrap,_partitioned), three golden constraints, generator rows; docs regenerated.Also carries the
sum_forwardhalf of #59:by=partitions a leading window exactly as it does a trailing one.Why
sum_backandsum_forwardare one operator with a direction. Spelling that direction in the name rather than in the sign of a width keeps the width a count — which is what every rule about it already assumes — and lets the typesetter render both from one place:Same operator, operands swapped.
The
sum_backhalf of #59 was split out into #65, since it fixed a rulemainalready documented in theBUILTINScomment and already checked in_dims_call— only the builtin declaration was missing, so the rule was unreachable. #59 is now closed as superseded.Landing order
Merge #65 first. This branch is built on it — the partitioned-window typesetting (
_group) comes from there — but GitHub refuses to retarget this PR's base ("the pull request is part of a stack", left over from the closed #59), so it still points atmainand its diff shows #65's commit as well. Once #65 lands, rebasing this branch ontomaindrops that commit and the diff issum_forwardalone.#61 → #63 also branch off #65, in parallel with this. Both this PR and #61 touch
dimensions.pyaround the named-amount rules; whichever lands second needs thesum_forwardkeys added back to_AMOUNTS/_VARIES(and_NEGATED, from #63). That is a few lines rather than a conflict in the operator itself — but it argues for landing #61/#63 first, so those dicts get written once with both windows in them.