Skip to content

ADR-0161 dated note: a knowledge_source declares how its hits are ordered for the asker and what a hit brings with it (amends K1) #38502

Description

@objectstack-fleet

repo:objectstack#5 · os-project-manager · session_01FEkQ5mzSTSPADAvwapnhxr

Filing gate: ① ruled. Ruling-ref: 7251603512 on #38412 (maintainer 「A 精简:排序加带出」, option A-lean; analysis 7251063339).
Grading: area:ai · Feature (governed text) · p3, dispatched in the topic's order · reach: every app whose right answer depends on who asks · Tier H: the maintainer approves the PR.
Part of #38346.

维护者速读

What

One dated note on docs/adr/0161-* (ADR-0161) that:

  1. Amends by name K1's sentence "The service does not choose a model, compute a vector, score a candidate, rerank or parse a file": the service may re-order the returned unit by a source's declared ordering, and nothing else.
  2. Fixes the authorable shape on knowledge_source (key names are the note's to choose): affinity entries (a declared field against a fact about the caller, as a boost or as nearest in a hierarchy) and expand (neighbouring content, and one declared lookup hop).
  3. Designs the two open points the ruling left to the note: how a boost combines with the stores' scores, and how neighbouring passages are read (no adapter member reads a passage by position today, packages/spec/src/contracts/knowledge-adapter.ts; a new member reopens K8's closed list, a re-split of the live record does not).

Execution conditions carried from the ruling, not asked again:

  • No filter mode: narrowing stays the search scope, visibility stays sharing.
  • The caller fact is a closed list the platform resolves, never a value a client or a model supplies.
  • Several affinity entries add; a source declares at most one nearest.
  • The re-order applies to the unit returned (passage, record or group) inside the existing refill bound, and reports no count.
  • No opt-out argument on the tool until a consumer asks.
  • Date decay (recency) is not in this note; it returns by a dated note with its first consumer.

Acceptance

  • The note is on main, approved by the maintainer, and names the slice cards that build it.
  • Contract-tier review PASS before the hand-off.

Not in scope: any code; the three slices (their own cards, each Blocked-by: this one).

Dedupe: ADR-0161 dated note affinity 0 open.

Activity

  1. added
    domain:spec
    area:ai
    on Nov 29, 2026
  2. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5oQLfL8thb6wtUHnTb
    Claim: PM loop round 1 · 2026-11-29T06:13Z
    Session: session_01FEkQ5oQLfL8thb6wtUHnTb
    Account: os-project-manager
    Branch: claude/issue-38502-adr-0161-declared-ordering
    Worktree: objectstack-issue-38502
    Domain: domain:skills
    Seat: repo:objectstack#5
    Area: o5-ai37000
    File surface: docs/adr/0161-knowledge-platform-boundary-platform-owns-assembly-sync-split-record-return-knowledge-source-is-a-governed-type.md (stop on breach; explain in the report)
    Container & model: S, mode:subagent, model: ceiling (dispatch-gates --tier at 545a4fa, Model tier — MANDATORY: claude-fable-5-2 ⇢ 'docs/adr/'), effort: xhigh (reason: ADR revision, 定档 「ADR 修订(改 docs/adr/ 的卡)effort 照常设令 xhigh」)
    Clause-②: no
    Metadata-protocol: none
    Responsibility: n/a — not a defect card
    Thread-read: 7251704651
    Premise: holds at 545a4fa — ADR-0161 K1 line 110 reads "The service does not choose a model, compute a vector, score a candidate, rerank or parse a file."; the record carries three dated notes so far (lines 19–21, the third from #38368); packages/spec/src/contracts/knowledge-adapter.ts has no member that reads a passage by position.
    Serial constraints cleared: check-handover --inflight at 545a4fa2: clear for ADR-0161; no open PR names it; slice cards #38503 #38504 #38505 are Blocked-by this card; overlap-check before every push
    Pre-claim lane: docs/adr/** ⇒ domain:skills (file ownership only); filed by seat repo:objectstack#5 under #38346 for this area (routing record 7251704651); governed (Tier H): the maintainer approves the merge, the seat lands it, this area does not.
    Pre-claim deps: none (no Blocked-by: on the card).
    Prior rulings read: record 7251603512 on #38412 (maintainer 「A 精简:排序加带出」; analysis 7251063339, its execution conditions are the card's and are not asked again); ADR-0161 K8 rules (a change is a dated note on the record) and the three earlier dated notes; ruling 7248214179 on #38368 (the held state the affinity facts read under).

  3. added
    pm:dispatched
    on Nov 29, 2026
  4. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5oQLfL8thb6wtUHnTb
    os-dev-report

    {
      "issue": 38502,
      "status": "done",
      "branch": "claude/issue-38502-adr-0161-declared-ordering",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/38511",
      "session": "session_01FEkQ5oQLfL8thb6wtUHnTb",
      "premise_still_valid": true,
      "summary": "The dated note is written and pushed as draft pull 38511 (head d9de430a7f, one file, +25 -0 against base 545a4fa278): a fourth Amended line in the header, the note under K1's list \"What follows from the two lists\", and one cross-reference line under K4. The note amends K1's sentence by name and gives its new reading, carries every execution condition of ruling record 7251603512 as written (no filter mode; a closed platform-resolved caller list; several affinity entries add, at most one nearest; the re-order applies to the returned unit inside the refill bound and reports no count; no opt-out argument; no recency), and names the slice cards 38503, 38504 and 38505. Both Zone 2 points are decided in the note and marked: (1) a boost combines by POSITION, never by score, per source, with nearest as tiers and boost as places moved up inside a tier; (2) neighbouring passages are cut again from the live record after a docHash match, and no adapter member is added, so K8's list stays closed. Neither needed a fact only the maintainer has. Four more shapes the note chooses are marked the same way (keys on the object arm as source.affinity and source.expand; the caller facts are user and business_unit; expand.follow brings object, id and title; an expansion rides on the tool's hit, not on KnowledgeHit). The premise held at 545a4fa278: the K1 sentence, the three earlier notes and the absence of a by-position passage read are as the claim says. The pull is draft and Tier H: never readied, queued or armed by this run.",
      "tests": "No package is touched and no tested behaviour changes: no closure build owed, no package test, no ablation. The one build run was a gate prerequisite: `pnpm exec turbo run build --concurrency=2 --filter=@objectstack/formula --filter=@objectstack/lint` under os-verify-lock, VERDICT command-exit 0, held 81s, waited 0s. All gate readings below were taken at head d9de430a7f, after the last commit.",
      "gates": "Local: `node scripts/pm/dispatch-gates.mjs --commands` (no path passed) derived 21 commands for 1 changed path (+25 / -0, merge base 545a4fa27); each was run at d9de430a7f with its exit code captured to a file before any pipe, and `--ran` answers \"21 derived famil(ies) accounted for — 21 run, 0 NOT-MEASURED (a DERIVED zero — all 21 recorded an exit code and none of them is 3)\". Exit 0 each: check-adr-links (+ --self-test) \"1281 relative link destination(s) under docs/adr/ resolve\"; check:adr-anchors; check:adr-index \"docs/adr/README.md is current, every record parsed\"; check:adr-symbol-anchors \"4561 anchors across 165 records resolve ... 0 line anchors survive\"; check:doc-authoring; @objectstack/lint check:doc-formula-expressions; check-closing-keyword-parity (+ --self-test); check-comment-mask-corpus \"24362 files, 0 disagree, 0 unparseable\"; plan-test-core-shards --self-test; check:ci-filter-parity; check:closed-ceremony-text; check:cross-package-test-inputs; check:driver-memory-census; check:gitlink-declared; check:nul-bytes; check:pm-governed-merges; check:pm-prior-rulings; check:refd-timer-probe; check:watch-hint-literal. On the first pass 7 of them exited 3 (PREREQUISITE NOT MET: no node_modules in a --no-install worktree, then two unbuilt packages); read as NOT MEASURED and run again after `pnpm install --frozen-lockfile` and the build, exit 0. CI on pull 38511 at d9de430a7f, read once and not waited on: `Check Changeset` completed success; skipped: Auto Label, Queue verdict, Borrowed queue verdict, Schedule gate, the opt-in 18.x upgrade harness and packed-tarball smoke; in_progress when read, so NOT MEASURED here, reason: this report is delivered when local verification ends: Lint · docs & code guards, Lint · repo & tooling gates, Lint · PM dispatch-gates, Lint · CI, release & engine gates, Lint · ESLint, Lint · scoped (three), Type Check (workspace, source gates, consumer gates, debt ledger), Check Documentation Links, PR-body guards, Governed Surface Queue Guard, Check PR Size, filter.",
      "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
      "mcp_calls": "0",
      "api_writes": "2 relay strokes — (1) pr_create, request fw-20261129T064245Z-ee5ede, run 46234710294 success: POST /repos/objectstack-ai/objectstack/pulls (draft), POST /repos/objectstack-ai/objectstack/issues/38511/assignees (os-project-manager), POST /repos/objectstack-ai/objectstack/issues/38511/labels (skip-changeset); read-back: 10494 bytes sent, 10494 stored, identical; assignee and label both listed. (2) this os-dev-report comment through post-stamped.mjs: POST /repos/objectstack-ai/objectstack/issues/38502/comments. Not REST writes: 3 git pushes of the work branch (the empty-branch probe, then two commits).",
      "open_questions": [],
      "deviations": [
        "The 维护者速读 has four lines and two sub-lines under the fourth: the order asks for the two marked choices in one line each, the agent file caps the section at four lines. Reported, not chosen silently.",
        "The PR body ends with the one footer line the order names; it carries no session-URL line and no signed trailer, since the order asked for neither.",
        "Commit trailer pair is the order's spelling (Co-Authored-By: Claude, then Claude-Session), model-free; the pre-push hook accepted both commits.",
        "The worktree was built with --no-install; `pnpm install` ran later, when seven gates named it as their prerequisite.",
        "A K4 cross-reference line was added beside the header line and the note, following the form of the 2026-11-28 note; the order's Form paragraph names only the first two. It is add-only and inside the claimed file."
      ],
      "security_findings": "none",
      "out_of_scope_findings": [
        "carrier: #38503 · noted, not filed — the caller-identity resolver on branch claude/issue-38363-mcp-asker-identity (0cea24a56c, draft, no pull open when read) lives in packages/runtime/src/domains/mcp.ts, a package service-knowledge does not depend on; the note leaves where it lives to the affinity slice and card 38363",
        "carrier: #38504 · noted, not filed — the slice card asks for work in both stores; under the note no store changes, neighbours are cut again from the record, so the card's What wants rewording by the seat",
        "carrier: #38505 · noted, not filed — the slice card's acceptance says the followed record's declared fields; the note fixes object, id and title and sends a field list to a later dated note"
      ]
    }
  5. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · sunhaolin · session_017xRBcSxvUE3fDrox79CL9t

    Triage (record; in flight, labels untouched): lands in docs/adr/0161-… (one dated note, draft PR #38511) · area:ai · Feature · p3 · size S. Rationale: it carries out the maintainer's #38412 ruling (record 7251603512, 「A 精简:排序加带出」), which names this note and its conditions, so the ADR text is pre-authorised. Tier H: the maintainer approves the PR. Note for the seat: docs/adr/** is domain:skills by the table, the claim reads domain:skills, and the label says domain:spec. It is not changed in flight.
    Recorded 2026-11-29T06:58Z.

  6. objectstack-fleet commented on Nov 29, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#5 · os-project-manager · session_01FEkQ5oQLfL8thb6wtUHnTb
    os-dev-report

    {
      "issue": 38502,
      "status": "done",
      "branch": "claude/issue-38502-adr-0161-declared-ordering",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/38511",
      "session": "session_01FEkQ5oQLfL8thb6wtUHnTb",
      "premise_still_valid": true,
      "summary": "Rework round on contract review 7252134389 (PASS, one should-fix). New head ec46fbc98678c0e3f974bd6d5562d7e7fb4cc97b, one commit on d9de430a7f, ADR file only (5 lines changed in place; the pull is still +25 -0 against its merge base). S1 is closed by the second rule the review offered: neighbours are attached only when the content of the passage cut at the hit's chunkId is the hit's snippet, character for character. It is stated in the bullet on the re-cut with its reason (the fingerprint is an optional member and docHash does not cover the split) and added as a case to \"When a hit brings no neighbours\". Chosen over the indexStatus rule because it judges the text the service holds and not a report from an optional member, so it is one rule for an adapter with indexStatus and one without, and it fails closed where a snippet is not the passage. N1, N2 and N3 are taken, one line each: expand.window carries the mark and names the heading-bounded siblingsBy mode as left out; places has no bound in the note and 38503 sets one; a follow whose target the record tools serve to no caller is among the write-time refusals. The PR body names the rule and why. The pull stays draft, Tier H, untouched otherwise.",
      "tests": "None owed: one Markdown file under docs/adr, no tested behaviour changes, no ablation. Gate prerequisite build under os-verify-lock: VERDICT command-exit 0, held 1s, waited 284s. All readings at head ec46fbc986, after the last commit.",
      "gates": "`node scripts/pm/overlap-check.mjs` before the push: \"against origin/main (a2205a85a3) and 0 PR head(s) ... origin/main: merges cleanly ... VERDICT clean exit 0\". `dispatch-gates --commands` derived the same 21 commands as the first round; all 21 run at ec46fbc986, exit code captured to a file before any pipe, exit 0 each; `--ran`: \"21 derived famil(ies) accounted for — 21 run, 0 NOT-MEASURED (a DERIVED zero — all 21 recorded an exit code and none of them is 3)\". CI on the new head: NOT MEASURED, reason: not read; the report is delivered when local verification ends.",
      "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
      "mcp_calls": "0",
      "api_writes": "2 relay strokes this round — (1) issue_patch on pull 38511 (PATCH /repos/objectstack-ai/objectstack/issues/38511, body only), request fw-20261129T070826Z-facf0b, run 46236616421 success, 11466 bytes sent and stored, identical; (2) this comment through post-stamped.mjs (POST /repos/objectstack-ai/objectstack/issues/38502/comments). One earlier issue_patch attempt was refused by the tool before anything was sent (body edit of a pull needs the signed trailer as its last line). One git push.",
      "open_questions": [],
      "deviations": [
        "The PR body now ends with the signed trailer line the body-edit tool requires; the first-round body ended with the footer line the order named.",
        "The rework worktree was built with `git worktree add` on the existing local branch: dev-worktree.sh refuses a local branch that already exists."
      ],
      "security_findings": "none",
      "out_of_scope_findings": [
        "carrier: #38503 · noted, not filed — the note now says #38503 sets and states the upper bound of `places`; the card's text does not mention a bound yet"
      ]
    }
  7. added a commit that references this issue on Dec 1, 2026
    be1cc06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area:aidomain:specpm:dispatchedpriority:p3

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions