Repository navigation
docs(adr): ADR-0150 addendum — knowledge_source joins the package-scoped bucket beside skill and ai_context - #37330
Conversation
…ped bucket beside skill and ai_context A dated addendum under D1 writes the maintainer's ruling of 2026-11-25 (seat record 7168239918) into ADR-0150: a knowledge source is identified by (package, name), in bucket 3 beside skill and ai_context. The status line gains one appended Amended clause and the D1 table one dated row; no ruled sentence is rewritten. The addendum names the readers that move, moves none, and lists the points that go past the ruling's words. ADR-0161 gains one cross-reference note after K4's point 3. No sentence of it is changed. Docs only: no schema, no code, no changeset. Claude-Session: https://claude.ai/code/session_01JQwxbZjKjZ947xtTvgJuHX Co-authored-by: Claude <noreply@anthropic.com>
…red on the merged main main moved under six of the files the addendum anchors (the knowledge service, its plugin, the memory adapter and three spec contracts) between the first reading and this branch's merge of main. Every statement of "The tree today" and every anchor was read again on the merged tree and holds, so the two dated readings now name the main commit they were last measured on. Docs only: no schema, no code, no changeset. Claude-Session: https://claude.ai/code/session_01JQwxbZjKjZ947xtTvgJuHX Co-authored-by: Claude <noreply@anthropic.com>
|
repo:cloud#1 · os-warren · session_01JQwxbW5anP6GDaVi5LKi2U 维护者速读
席位意见: 建议合并。L1 ACCEPT;契约审核在同一提交 席位核对ACCEPT · repo:cloud#1 · PR #37330 · Tier H ( No must-fix, no should-fix for the dev. Read against GitHub and
The two questions the seat was asked to judge
Contract reviewServed-tier: Face: governed rules text (
① Derived judgments
② Semver levelNo changeset and none owed: ③ Boundary flags
④ Design judgment
Implemented-by: Independence: the diff was drafted in thread session VERDICT: PASS |
|
repo:cloud#1 · os-warren · session_01JQwxbW5anP6GDaVi5LKi2U Hand-off for approval (Tier H,
|
Requested by Warren · project thread
repo:cloud#1 · os-warren · session_01JQwxbZjKjZ947xtTvgJuHX
Fixes #37325
Clause-②: no
Metadata-protocol: none
维护者速读
What changes
Two files under
docs/adr/: 58 lines added, 1 line changed. No schema, no code, no changeset.ADR-0150 (Accepted) gains a dated addendum. No ruled sentence is rewritten.
ai_contextone. This is the one changed line: the clause is appended, and nothing before it is edited.ai_contextrow and before bucket 4.ai_contextaddendum and before D2, "Addendum (2026-11-25):knowledge_sourcejoins bucket 3". It writes the maintainer's ruling of that day into the record: the knowledge source type of ADR-0161 K4 is identified by(package, name), in bucket 3 besideskillandai_context.The ruling is quoted with its record id in the status clause, at the head of the addendum and in the ADR-0161 note: seat record
7168239918on the code card, decision card tapped B 「按应用+名字区分,都保留」 at 2026-11-25T16:34:09Z, against the card's recommendation.The addendum says, in this order:
NS-NAMEwhere its name crosses the AI face, which is insidesearch_knowledge: thesourceslist of an answer and thesourceIdsargument.mainatfbb62e1c. The type is not registered and is in none of the four lists. A source reaches the service through code only. The keys of an index are the bareid.ADR-0161 gains one cross-reference note after point 3 of K4 and before K5. No sentence of it is changed.
Not in this PR, by the card's contract: none of the four lists is edited, no reader is moved and no store is re-keyed. That is the code card's work, after this merge.
Tests
No package is touched, so no package build or test is owed. The checks that read these two files are the docs gates under Verification.
Acceptance notes
domain:serverfour lists and readers (precedent PR feat(core,objectql,spec,service-record-context,mcp,runtime)!: a context pack is identified by its package and its name; get_record_context selects a pack by its face on both MCP doors #37291)" and names none of them. In that PR the fourth list isNAMESPACE_UNIQUE_TYPES: one package holder of a name inside one namespace, refused at install and inos validate. So "Two packages shipping one source name both work" holds for two namespaces, and inside one namespace the second is refused. The list's header reserves a further type to the maintainer. The merge accepts this point. Struck, two co-owners of a namespace may ship one name, and the one face they derive is refused at the call._-led name that today'sidpattern admits. And a409names only the sources the tool may search (ADR-0161 K9).sourceIdanddocumentId, a stored document'ssourceId, the by-name members of the service contract); which coordinate a key carries, the package id or the namespace, and what removes an index left under the old key; which holder a source registered in code is; and an environment source under a name a package later ships.maingained the knowledge splitter (PR feat(service-knowledge)!: one splitter (whole / recursive / markdown, Chinese-aware), the chunk channel and the split key; KnowledgeChunk.metadata and knowledge.chunk_overlap retired #37287) under six of the files the addendum anchors.mainis merged into the branch (a merge commit, no rebase and no force-push). Every "today" sentence and every anchor was read again atfbb62e1c, and all hold. The two dated readings name that commit.node scripts/pm/overlap-check.mjs --branch=claude/project-thread-4uapwfansweredVERDICT clean exit 0at this head, againstorigin/mainand that PR's head. Whichever of the two lands second mergesmain.check:adr-symbol-anchorsrefuses a line anchor underdocs/adr/, so the record citespath#Symbol, and the line numbers are in the table under Verification.docs/adr/ships in no package, so this PR carriesskip-changeset.main, and its own status line says the record is in force from the merge of the PR that carried it. This PR adds one note to that record and does not touch its status line.Verification
Read first, by risk:
docs/adr/0150-…-literal-prefix.md, "Past the ruling's words" at the end of the addendum (lines 191 to 199). Point 1 is the one decision that is the maintainer's.Two-minute check: run
node scripts/check-adr-symbol-anchors.mjs. Expect4220 anchors across 163 records resolveand exit 0. Twenty-one of them are this diff'spath#Symbolanchors.Measured anchors on main at fbb62e1 (file:line)
skillandai_contextopen no environment overlaypackages/spec/src/kernel/metadata-plugin.zod.ts:798(DEFAULT_METADATA_TYPE_REGISTRY),:1384,:1388packages/spec/src/api/protocol.zod.ts:2753(PACKAGE_SLOTTED_METADATA_TYPES;skillat:2754)packages/metadata/src/package-slotted-store.ts:797(storeWriteKey),:820packages/core/src/package-scoped-resolution.ts:245(PACKAGE_SCOPED_TYPES;skillat:270),:740;packages/objectql/src/package-scoped-resolver.ts:149packages/objectql/src/package-scoped-read.ts:88(PACKAGE_SCOPED_READ_TYPES;skillat:96)packages/objectql/src/namespace-co-owner-names.ts:96(NAMESPACE_UNIQUE_TYPES),:27packages/services/service-knowledge/src/knowledge-service-plugin.ts:91(KnowledgeServicePlugin),:44,:220id; a second registration replaces the first with a warningpackages/services/service-knowledge/src/knowledge-service.ts:121(KnowledgeService),:123,:166,:168id, a:and the record idpackages/services/service-knowledge/src/knowledge-service.ts:1570(documentIdFor),:1571packages/spec/src/contracts/knowledge-adapter.ts:33(AdapterContext),:35idpackages/plugins/knowledge-memory/src/index.ts:44(KnowledgeMemoryAdapter),:48,:55packages/spec/src/contracts/knowledge-service.ts:107(IKnowledgeService),:127id; a hit showssourceIdanddocumentIdpackages/services/service-knowledge/src/knowledge-tools.ts:61(SearchKnowledgeSourceSummary),:70,:72,:222sourceIdsentry is refusedNOT_FOUNDpackages/services/service-knowledge/src/knowledge-tools.ts:246(createKnowledgeTools),:257,:260idpattern admits a_-led name; the bucket's pattern does notpackages/spec/src/ai/knowledge-source.zod.ts:174(KnowledgeSourceSchema),:176;packages/spec/src/kernel/address-grammar.ts:68(ROUTER_ADDRESSABLE_NAME_PATTERN)packages/spec/src/ai/face-name.ts:86(deriveAiFaceName)packages/mcp/src/skill-prompts.ts:373(lookupSkillPrompt)packages/spec/src/kernel/collection-item-owner-stamp.ts:129(judgeCollectionItemOwnerStamp),:100packages/metadata-protocol/src/protocol-package-bindings.ts:388(SEALED_ROW_SERVED_OVERRIDE_TYPES)packages/objectql/src/registry.ts:5328(uninstallPackage)packages/metadata/src/metadata-manager.ts:2880(unregisterPackage)Absence readings at the same commit, each with a positive control:
knowledge_sourcein the four list files, inpackages/metadata/src/package-slotted-store.tsand in the registry's rows: 0 lines each. Control:skillis in the first three lists and in the registry, at the lines the table gives.knowledgeSourcesinpackages/spec/src/stack.zod.ts, 0 lines. Control:aiContexts, 3 lines.knowledge_sourceunderpackages/,examples/,ui/,skills/andcontent/: 0 files. Control:ai_context, 60 files.KnowledgeServicePluginorregisterSourceunderexamples/: 0 files. Control: 25 files underpackages/.knowledge-pgvectororknowledge-turso: 0. Control:packages/plugins/knowledge-memory, 10 files.ai_context, 6 lines).Local gates at head 05f35b6: 21 derived, 21 run, all exit 0
Derived with
node scripts/pm/dispatch-gates.mjs --repo objectstack-ai/objectstack --commands, and reconciled with--ran:Each exit code was captured before any pipe:
check:doc-formula-expressionsreads the compiled output of@objectstack/formulaand@objectstack/lint. Those two and their dependencies were built first on the merged tree, under the shared verify lock (VERDICT command-exit 0).docs/adr/README.mdis generated from each record's status keyword. ADR-0150's keyword stays Accepted and ADR-0161's stays Proposed, so the index does not change and is not in this diff.Also at this head:
node scripts/check-commit-card-trailers.mjs --range origin/main..HEADexits 0 over the 3 commits of the branch.Not measured locally, and CI's to run: the type-check lanes, the
Plan Test Core shardsjob and the governed-merges audit, which take values only a CI run has.Generated by Claude Code