Repository navigation
glove-parity: an edge table as the anchor, and distinct targets of a hop (D-CMH-G1-4b) - #1520
Conversation
MIN/MAX lower to mask-risc's MaskedMinI32/MaskedMaxI32. An empty selection pushes the fold's identity (i64::MAX / i64::MIN), the same seed the grouped terminals leave in an empty group; no I32 value equals it. procs::min/max and procs::and_cmp_i32 (<, <=, >, >= via IntSLess and IntNot) are named sequences over existing calls. No new opcode. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
Cond::Order (<, <=, >, >= on an I32 field, in the lane's units) binds to
Quack's Cmp::{Lt,Le,Gt,Ge}I32 and to R2IL's and_cmp_i32. Fold::Min/Max bind
to Agg::MinI32/MaxI32 and R2IL's MIN/MAX; FoldValue::Extremum is None for an
empty selection on both frontends. Gremlin: has(f, lt|lte|gt|gte(n)),
values(f).min()/max(), and their text forms. min/max of vertices, and an
ordered has after out(rel), are refused by name.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
…ontract Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
…(D-CMH-G1-4b)
Fold::Distinct { rel } is Gremlin's out(rel).dedup().count(): the number
of distinct live targets the selected rows reach. It lowers to the
relation's liveness semijoin (emitted once, whether or not a condition
already named the relation) and COUNT(DISTINCT key) over the key lane,
Terminal::CountKeyRunsU32: two words of state, no target mask, nothing a
second program reads. The key lane must be stored in key order; a lane in
another order is refused at run time (LaneNotOrdered), never miscounted.
An M:N relation is carried as its own concept: each edge row is one
traverser with a functional relation to each end, so count() is the bag
and dedup().count() the set of reached ends, both ends filtered at the
source through the key. A distinct count over the other end needs the
edges stored in that end's order: a second projection of the concept.
Composer: dedup() after out(rel) moves to the distinct targets; has()
commutes with it; count() folds; anything else, or ending there, stays
DedupThroughRelation. Text form, awareness projection (fold:distinct) and
R2IL (FrontendGap GATHER) follow.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
Six matrix rows move from COMPOSE to DIRECT (E(), dedup after a fan-out, in spelled from the child, M:N one hop, outE/inE, outV/inV): DIRECT 20, COMPOSE 12 of 67. A second hop stays refused pending the chained-hop decision. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
|
Warning Review limit reachedYour organization has reached its usage spending cap. Adjust your spending cap in the billing tab. Next included review available in 1 minute. View limit details
Warning Billing warning: we have not been able to collect payment for this subscription for more than 72 hours. Please update the payment method or pay any pending invoices in Billing to avoid service interruption. Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ef2752749e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| | second fan-out (fan-in carried) | traversal | V->V'' | bag | — | pure | YET | #1311 `many_to_many_two_hop_is_refused…`; #1312 §D | barrier / fan-in operand (G2) | | ||
| | outE/inE/bothE | traversal | V->E | edge rows | — | pure | COMPOSE | edge table as anchor | relation carrier | | ||
| | outV/inV/otherV/bothV | traversal | E->V | fk read | — | pure | COMPOSE | EqU32Via from edge row | relation carrier | | ||
| | outE/inE/bothE | traversal | V->E | edge rows | — | pure | DIRECT (G1-4b) | `V(edge).where(p())` with `p` over `out(src)`; anchored on the edge or child concept (tests/distinct.rs); `bothE` needs the union below | — | |
There was a problem hiding this comment.
Remove
bothE from the DIRECT capability row
This row marks the combined outE/inE/bothE capability as DIRECT and includes it in the reported DIRECT total, but the same plan keeps bothE queued at line 355, and compose still rejects every Step::Both unconditionally in gremlin.rs. Anyone relying on this matrix will therefore treat an unsupported traversal as available; split bothE into its own row or retain a non-DIRECT status for the combined row.
Useful? React with 👍 / 👎.
Stacked on #1518; merge that first. Until it merges, this diff also shows #1518's commits. This PR adds the last two commits.
What
Step 3 of the plan from the #1510–#1515 synergy review: the edge-table hop. Every hop's filter is applied at the source, and no program's output feeds another program.
V(edge).where(p()).out(end).count()is the bag (edge rows);V(edge).where(p()).out(end).dedup().count()is the set: a newFold::Distinct { rel }, the number of distinct live targets reached.EqU32Viaplus the liveness semijoin, as in glove-parity: functional relation carrier — out(rel) as a method (D-CMH-G1-4a) #1514.Fold::Distinctlowers to two parts:COUNT(DISTINCT key)over the key lane, usingTerminal::CountKeyRunsU32, which keeps two words of state and builds no target mask.LaneNotOrdered, never miscounted.ScatterCountU32(a seen-set the size of the population) is held for now, so it is not used. A distinct count over the other end needs the edges stored in that end's order, i.e. a second projection of the concept.dedup()afterout(rel)moves the cursor to the distinct targets.hascommutes with it, andcount()folds it. Ending on the distinct targets, or any other step after them, still returnsDedupThroughRelation.fold:distinct(rel)), and R2IL (FrontendGap { R2il, "GATHER" }).What stays refused
.claude/board/entries/2026-10-03-coresearch-chained-hop.md, and every multi-hop question in docs(D-SAG-2): Ruff × ONA closed-loop software-awareness validation, falsifiers and research #1510, D-IAM-SAG-0: map IAM stack onto dir_sim, OGAR and #1509 SAG (RFC + research + prompt) #1512 and docs: D-SAG-5 reflexive software cognition after #1509, OpenCog/NARS research and probes #1515 waits on it.V(parent).in(rel)spelling is still refused (FanOut). The same population is writtenV(child).out(rel).bothE.Evidence
tests/distinct.rshas 6 tests. The fixture is syntheticmethod,fieldandreadstables with dangling keys and dead rows in each, plus two projections ofreads: one stored by field, one by method. Every answer is checked against a row loop over the field text at n ∈ {1, 64, 65, 4097}, and the bag and set answers differ on this data.Each of these seven disable runs turns the test that checks it red:
COUNT(*);hasafterdedupdropped;required.tests/relation.rshad pinnedout(rel).dedup().count()as refused; that pin now coversdedup()withoutcount(), which is still refused.The vocabulary matrix moves six rows from COMPOSE to DIRECT. It now reads DIRECT 20, COMPOSE 12 of 67.
Gates:
cargo test(all suites),cargo clippy --all-targets -D warningsandcargo fmtpass for the crate.🤖 Generated with Claude Code
https://claude.ai/code/session_011BMJnDBAfzcuQh5HeT39Rh
Generated by Claude Code