You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
mcp: register the dataset tools on McpDataBridge under data:read (ADR-0149 D2) #31590
Filing gate: ② a child card of an Accepted ADR. ADR-0149 D7 card 3. Parent: #31503, landed by PR #31535.
Reader: the domain:server lane (MCP bridge / runtime). It may run beside the service-analytics card once the bridge members are typed.
Dedupe (open AND closed): "McpDataBridge listDatasets registerDatasetTools" found nothing.
维护者速读
问题: 让 MCP 客户端也能用同一对数据集工具:注册到 MCP,权限范围 data:read。
影响面: MCP 新增两个工具,与产品内问数共用同一定义,口径一致。
需要您做的: 无,由 server 车道实现。
Task
D2: optional members McpDataBridge.listDatasets / .queryDataset, implemented in both bridge implementations.
registerDatasetTools in wireBridgeTools, under data:read.
The skill prompt text that teaches the D3 selection rule to MCP clients.
Claim: PM loop round 8 · 2026-11-09T02:31Z
Session: session_01ADHkmQuUSo11ZX1avrvbez (card thread, dev) · seat session_01ADHkmQKZzp4DLtqiCkZZRM
Account: os-steve
Branch: claude/project-thread-fkif3v
Worktree: objectstack-issue-31590
Domain: domain:server
Seat: domain:server#2
File surface: packages/mcp/src/** (bridge interface, wireBridgeTools, skill-md.ts), the bridge implementations (packages/runtime/src/domains/mcp.ts among them), tests, root .changeset/. ⛔ No packages/spec/**, packages/services/service-analytics/**, ui/**
Container & model: M, mode:thread, model: default tier, effort: medium
Clause-②: yes (widening)
Metadata-protocol: none
Responsibility: ADR-0149 D7 child of #31503 (parent landed by PR #31535)
Thread-read: none
Premise: holds as filed, read at claim on origin/main0105a687: McpDataBridge (packages/mcp/src/mcp-http-tools.ts) has no dataset members and wireBridgeTools registers no dataset tool
Serial constraints cleared: takes its tool definitions from #31589 (same seat): reads that branch until it merges, then merges main and lands after it; stays off E8 #31680's by-name readers in packages/mcp (same seat, parked)
Scope: Fixes #31590. Optional bridge members listDatasets / queryDataset in both implementations, registerDatasetTools under data:read, the D3 selection rule in the MCP skill prompt; one definition, shared with #31589. Order: /mnt/project-files/server-seat2/standard-order.md + /mnt/project-files/server-seat2/31590-delta.md. Summons: the maintainer's 「server 任务很多,你应该跟进并发5」 (project chat, 2026-11-09T02:28Z).
{
"issue": 31590,
"status": "done",
"branch": "claude/project-thread-fkif3v",
"pr": "https://github.com/objectstack-ai/objectstack/pull/31773",
"session": "session_01ADHkmQuUSo11ZX1avrvbez",
"premise_still_valid": true,
"summary": "McpDataBridge gains three optional members (listDatasets, queryDataset(input,{maxRows}), datasetToolDefinitions); registerDatasetTools in wireBridgeTools registers list_datasets/query_dataset only when all three are present and the grant admits data:read, with descriptions from the service-analytics definitions and the spec input schemas taken whole. Both bridges carry the members over AnalyticsService.datasetTools (seat ruling C): HTTP resolves the analytics service per request and binds merged dataset read + translateMetaList + the request's narrowing probe + the page cap; stdio resolves it in start(). SKILL.md renders both tools and the D3 selection rule where they register. Lands after #31589.",
"tests": "head 5078be21: mcp 62/62 files, 979/979; runtime 564/564 files, 9065 passed 19 skipped; mcp+runtime typecheck exit 0 on 37710911. Red on main: 12 failed | 5 passed (17) with origin/main mcp-http-tools.ts + skill-md.ts. Ablations A1 scope gate, A2 all-three members, A3 HTTP seam method test, A4 stdio guard: each red, each restored blob==HEAD (src-imported tests, no dist leg).",
"gates": "dispatch-gates on 5078be21: 68 derived, 67 exit 0, 1 NOT MEASURED (check:dual-build-cjs-loads exit 3, needs full workspace build; CI). teardown self-test exit 0 after fixture fetch. --ran: 0 UNRUN. eslint --no-inline-config packages/mcp packages/runtime exit 0. PR check-runs: in_progress at report time.",
"dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm",
"mcp_calls": "3 — issue_read get, issue_read get_comments, pull_request_read get (reads only)",
"api_writes": "2 — fleet-write pr_create (#31773), this os-dev-report comment via post-stamped",
"files_changed": [
".changeset/31590-mcp-dataset-tools.md",
"packages/mcp/src/mcp-http-tools.ts",
"packages/mcp/src/skill-md.ts",
"packages/mcp/src/stdio-data-bridge.ts",
"packages/mcp/src/plugin.ts",
"packages/mcp/src/mcp-dataset-tools.test.ts",
"packages/mcp/src/skill-md-surface-guard.test.ts",
"packages/runtime/src/domains/mcp.ts",
"packages/runtime/src/mcp-dataset-tools-bridge.test.ts"
],
"line_budget": "+861 / -7 over 9 files (PR additions/deletions)",
"deviations": [
"Forced test edit: skill-md-surface-guard.test.ts full bridge gains the dataset members and renders pass datasetTools:true.",
"Runtime typecheck needed driver-turso built first (untouched kernel test imports it); typecheck read on 37710911, the later commits being the changeset and a merge with no mcp/runtime file.",
"stdio datasets not localized (no request locale on an API-key principal); stdio passes no narrowing probe, as query_records there."
],
"open_questions": [
{
"question": "New names: McpDataBridge.listDatasets/queryDataset/datasetToolDefinitions, exported registerDatasetTools + hasDatasetTools (module export, not on the package index), skill option datasetTools, runtime McpDatasetToolsService / stdio StdioDatasetToolsService (structural seam types). Accept?",
"options": [
"A accept as named",
"B rename"
],
"recommendation": "A, they follow the aggregate/fileTools/McpRecordFileService spellings"
},
{
"question": "Input schema source: the MCP tool takes the spec zod declarations (ListDatasetsInputSchema/QueryDatasetInputSchema) whole, of which the definition's parameters is the projection, instead of z.fromJSONSchema(definition.parameters). Keep?",
"options": [
"A spec zod whole (keeps the spec's alias prescriptions on refusal; aggregate_records precedent)",
"B convert definition.parameters (prescriptions reduce to a bare Unrecognized key)"
],
"recommendation": "A, one declaration either way and the refusal stays fixable"
}
],
"security_findings": "none",
"out_of_scope_findings": []
}
Both bridges (HTTP and stdio) carry the optional members listDatasets / queryDataset / datasetToolDefinitions only when the kernel analytics service exposes datasetTools (ruling C). Without it, or without data:read, the pair is not registered.
Activity
objectstack-fleet commentedon Nov 8, 2026
triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U
Path: none
Triage:
domain:server· p2 ·pm:blockedon #31587 · 2026-11-08T16:28Z⛔ Not a claim.
domain:server. The fix is in the MCP bridge (McpDataBridge,wireBridgeTools).domain:devxanddomain:serveras separate lanes, or merge them? Measured load and boundary friction, 2026-11-08 #31424 rule 5 it goes on a skills child card, not in this PR.Generated by Claude Code
objectstack-fleet commentedon Nov 9, 2026
triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U
Path: none
Triage: unblocked ·
pm:blocked→pm:queue· 2026-11-09T02:11Z⛔ Not a claim.
Blocked-by:target is done: spec: dataset vocabulary keys (synonyms, member description) and dataset tool I/O schemas (ADR-0149 D1/D2) #31587 (closed; PR feat(spec): dataset member vocabulary and the list_datasets / query_dataset tool schemas (ADR-0149 D1, D2) #31652).Generated by Claude Code
objectstack-fleet commentedon Nov 9, 2026
domain:server#2 · os-steve · session_01ADHkmQKZzp4DLtqiCkZZRM
Claim: PM loop round 8 · 2026-11-09T02:31Z
Session:
session_01ADHkmQuUSo11ZX1avrvbez(card thread, dev) · seatsession_01ADHkmQKZzp4DLtqiCkZZRMAccount:
os-steveBranch:
claude/project-thread-fkif3vWorktree:
objectstack-issue-31590Domain:
domain:serverSeat:
domain:server#2File surface:
packages/mcp/src/**(bridge interface,wireBridgeTools,skill-md.ts), the bridge implementations (packages/runtime/src/domains/mcp.tsamong them), tests, root.changeset/. ⛔ Nopackages/spec/**,packages/services/service-analytics/**,ui/**Container & model: M,
mode:thread,model: default tier,effort: mediumClause-②: yes (widening)
Metadata-protocol: none
Responsibility: ADR-0149 D7 child of #31503 (parent landed by PR #31535)
Thread-read: none
Premise: holds as filed, read at claim on
origin/main0105a687:McpDataBridge(packages/mcp/src/mcp-http-tools.ts) has no dataset members andwireBridgeToolsregisters no dataset toolSerial constraints cleared: takes its tool definitions from #31589 (same seat): reads that branch until it merges, then merges main and lands after it; stays off E8 #31680's by-name readers in
packages/mcp(same seat, parked)Scope: Fixes #31590. Optional bridge members
listDatasets/queryDatasetin both implementations,registerDatasetToolsunderdata:read, the D3 selection rule in the MCP skill prompt; one definition, shared with #31589. Order:/mnt/project-files/server-seat2/standard-order.md+/mnt/project-files/server-seat2/31590-delta.md. Summons: the maintainer's 「server 任务很多,你应该跟进并发5」 (project chat, 2026-11-09T02:28Z).objectstack-fleet commentedon Nov 9, 2026
domain:server#2 · os-steve · session_01ADHkmQuUSo11ZX1avrvbez
os-dev-report
{ "issue": 31590, "status": "done", "branch": "claude/project-thread-fkif3v", "pr": "https://github.com/objectstack-ai/objectstack/pull/31773", "session": "session_01ADHkmQuUSo11ZX1avrvbez", "premise_still_valid": true, "summary": "McpDataBridge gains three optional members (listDatasets, queryDataset(input,{maxRows}), datasetToolDefinitions); registerDatasetTools in wireBridgeTools registers list_datasets/query_dataset only when all three are present and the grant admits data:read, with descriptions from the service-analytics definitions and the spec input schemas taken whole. Both bridges carry the members over AnalyticsService.datasetTools (seat ruling C): HTTP resolves the analytics service per request and binds merged dataset read + translateMetaList + the request's narrowing probe + the page cap; stdio resolves it in start(). SKILL.md renders both tools and the D3 selection rule where they register. Lands after #31589.", "tests": "head 5078be21: mcp 62/62 files, 979/979; runtime 564/564 files, 9065 passed 19 skipped; mcp+runtime typecheck exit 0 on 37710911. Red on main: 12 failed | 5 passed (17) with origin/main mcp-http-tools.ts + skill-md.ts. Ablations A1 scope gate, A2 all-three members, A3 HTTP seam method test, A4 stdio guard: each red, each restored blob==HEAD (src-imported tests, no dist leg).", "gates": "dispatch-gates on 5078be21: 68 derived, 67 exit 0, 1 NOT MEASURED (check:dual-build-cjs-loads exit 3, needs full workspace build; CI). teardown self-test exit 0 after fixture fetch. --ran: 0 UNRUN. eslint --no-inline-config packages/mcp packages/runtime exit 0. PR check-runs: in_progress at report time.", "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm", "mcp_calls": "3 — issue_read get, issue_read get_comments, pull_request_read get (reads only)", "api_writes": "2 — fleet-write pr_create (#31773), this os-dev-report comment via post-stamped", "files_changed": [ ".changeset/31590-mcp-dataset-tools.md", "packages/mcp/src/mcp-http-tools.ts", "packages/mcp/src/skill-md.ts", "packages/mcp/src/stdio-data-bridge.ts", "packages/mcp/src/plugin.ts", "packages/mcp/src/mcp-dataset-tools.test.ts", "packages/mcp/src/skill-md-surface-guard.test.ts", "packages/runtime/src/domains/mcp.ts", "packages/runtime/src/mcp-dataset-tools-bridge.test.ts" ], "line_budget": "+861 / -7 over 9 files (PR additions/deletions)", "deviations": [ "Forced test edit: skill-md-surface-guard.test.ts full bridge gains the dataset members and renders pass datasetTools:true.", "Runtime typecheck needed driver-turso built first (untouched kernel test imports it); typecheck read on 37710911, the later commits being the changeset and a merge with no mcp/runtime file.", "stdio datasets not localized (no request locale on an API-key principal); stdio passes no narrowing probe, as query_records there." ], "open_questions": [ { "question": "New names: McpDataBridge.listDatasets/queryDataset/datasetToolDefinitions, exported registerDatasetTools + hasDatasetTools (module export, not on the package index), skill option datasetTools, runtime McpDatasetToolsService / stdio StdioDatasetToolsService (structural seam types). Accept?", "options": [ "A accept as named", "B rename" ], "recommendation": "A, they follow the aggregate/fileTools/McpRecordFileService spellings" }, { "question": "Input schema source: the MCP tool takes the spec zod declarations (ListDatasetsInputSchema/QueryDatasetInputSchema) whole, of which the definition's parameters is the projection, instead of z.fromJSONSchema(definition.parameters). Keep?", "options": [ "A spec zod whole (keeps the spec's alias prescriptions on refusal; aggregate_records precedent)", "B convert definition.parameters (prescriptions reduce to a bare Unrecognized key)" ], "recommendation": "A, one declaration either way and the refusal stays fixable" } ], "security_findings": "none", "out_of_scope_findings": [] }Stamped 2026-11-09T03:21Z.
Generated by Claude Code
objectstack-fleet commentedon Nov 9, 2026
domain:server#2 · os-steve · session_01ADHkmQKZzp4DLtqiCkZZRM
ACCEPT → PR #31773 comment 6732462672 · head
05891994· 2026-11-09T04:46Z · landing: pr_ready + automerge_enableobjectstack-fleet commentedon Nov 9, 2026
domain:server#2 · os-steve · session_01ADHkmQKZzp4DLtqiCkZZRM
落地 · 2026-11-09T05:17Z
34a30e8a(ACCEPT 6732462672; TIER_DEFAULT contract review PASS posted on the PR)Fixes #31590)Landed:
data:readgetlist_datasets/query_dataset. Their names, descriptions and input schemas come from service-analytics: list_datasets / query_dataset AI tools with the D3 selection rule and provenance (ADR-0149 D2-D4) #31589's one definition and the spec's D2 schemas;packages/mcpholds no copy and does not depend on the analytics package.listDatasets/queryDataset/datasetToolDefinitionsonly when the kernelanalyticsservice exposesdatasetTools(ruling C). Without it, or withoutdata:read, the pair is not registered./admin/sso/*-groups-claimroutes, not on this PR. It was re-queued and merged on the next run.