Repository navigation
Description
epic:#5027#1 · hotlong · session_01Q4EjjMUfmNYTem26rXLFUf
Filing gate: ④ topic child. Source: topic #37871 (Jack 2026-11-27: 「用户体验相关的非常关键,要启动」 06:56Z; card 「按 v2 立卡,顶替输入框」 08:05Z; 「交给 objectstack #3」 08:06Z). Business reason: carried by the parent.
Parent: #37871 (decisions D1–D6, relations, topic acceptance). Evidence: an independent Fable review of objectstack main adb65d1 and cloud main 9729319 (2026-11-27) checked every file:line below.
Owner: repo:objectstack#3 (Jack 08:06Z 「交给 objectstack #3」; 07:51Z 「你只处理 cloud 的任务,其他任务都交给 objectstack 座位哦」). Reserved under topic #37871 (pm:epic), not pm:queue: other seats leave it.
Grading: area:ai · Task · p1 · size S · reach: every console conversation where the AI asks a question.
Dedupe: searched AskQuestion, question envelope: none.
维护者速读
- 是什么:在 spec 里定义"问题信封":云端工具写、控制台读,画问题卡用。兼容现在
ask_which的旧格式。
What to do
- New
packages/spec/src/ai/ask-question.zod.ts:
AskQuestionEnvelope = {
success: true,
status: 'asked',
reply: string, // the text that ended the turn; the console checks the question took effect
preface?: string, // stage 2: one lead-in sentence, ≤ 80 chars
questions: [ // 1–2
{ header?: string, // ≤ 16, used to compose a two-question answer
question: string, // ≤ 120
options: [ // 2–4, mutually exclusive, labels unique
{ label: string, // ≤ 24
description?: string, // ≤ 60
recommended?: boolean } // at most one
] }
]
}
"Type something else" is not in the envelope (the console always offers it). No multi-select in v1.
2. Legacy compatibility, the only real producer in stage 1: { success, status:'asked_which', question, readings: string[], reply } (cloud ask-which.tool.ts:116) reads as one question whose options have no description. Tests must cover it.
3. parseAskQuestionEnvelope(obj): takes an already-unwrapped object (unwrapping {type:'text', value} stays in the console's toolResultParsers.ts:76-109); a bad envelope returns null (the console falls back to text).
4. Export publicly; regenerate api-surface and generated docs; changeset (@objectstack/spec minor, Metadata-protocol: added).
Acceptance
- Positive and negative parse cases: limits, 1 vs 3 questions, 1 vs 5 options, duplicate labels, two
recommended, legacyasked_which, garbage →null.
Activity
objectstack-fleet commentedon Nov 27, 2026
repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU
Claim: PM loop round 1
Session:
session_01L9qibyUSf2nKJWW6qBemSUThread session:
session_01L9qibvQHY8a6PKzfR6E7SDAccount:
os-teslaBranch:
claude/project-thread-8w7xfxWorktree:
objectstack-issue-37872Domain:
specSeat:
repo:objectstack#3File surface:
packages/spec/src/ai/ask-question.zod.ts(new),packages/spec/src/ai/index.ts, its tests, the generated baselines and references the gates derive, a new.changeset/*.md; NOTskills/**, NOTdocs/adr/**, NOTui/**(Q2a/Q2b) (stop on breach; explain in the report)Container & model:
S,mode:thread,model: default tier — dispatch-gates.mjs --tier: "no path-derived mandate",effort: high, reason: size S but not mechanical — it fixes a new published schema shapeClause-②: yes
Metadata-protocol: added
Responsibility: the spec question envelope of topic #37871: AskQuestionEnvelope, compatibility with the legacy asked_which, parseAskQuestionEnvelope; Q2b #37874 builds on it
Thread-read: none
Premise: topic #37871 (Jack 08:06Z 「交给 objectstack #3」; Tesla 08:25Z 「接下,放进问 AI 专区」); no Blocked-by on the card; the thread runs the premise check at 73d5e34
Serial constraints cleared:
overlap-check.mjs runs on the thread's first push (branch not yet pushed); no in-flight claim on these files named by any seatClause-② yes ⇒ L2 at the contract-review tier before the queue. Ask-AI own cap of 5 (Tesla 「给问ai单独5个并发」 2026-11-27T11:21Z).
objectstack-fleet commentedon Nov 27, 2026
repo:objectstack#3 · os-tesla · session_01L9qibvQHY8a6PKzfR6E7SD
os-dev-report
{ "issue": 37872, "status": "done", "branch": "claude/project-thread-8w7xfx", "pr": "https://github.com/objectstack-ai/objectstack/pull/37930", "session": "session_01L9qibvQHY8a6PKzfR6E7SD", "premise_still_valid": true, "summary": "New packages/spec/src/ai/ask-question.zod.ts exported from @objectstack/spec/ai: AskQuestionEnvelopeSchema / AskQuestionSchema / AskQuestionOptionSchema (closed at every level, 1-2 questions, 2-4 options, card's length limits exported as ASK_QUESTION_LIMITS, unique trimmed labels per question, at most one recommended) and parseAskQuestionEnvelope(value) answering the parsed envelope or null. The legacy ask_which result (success, status asked_which, question, readings, reply) converts to one question whose options are the readings and is held to the same schema and limits; the legacy reader is open (extra keys ignored) and not exported. Generated artifacts regenerated; dropped-refinements.baseline.json gains the two superRefine sites (rows + header totals); llms.txt ai count 16 to 17.", "tests": "head a8d843b3: packages/spec src/ai/ask-question.test.ts 17/17; vitest src/ai + src/shared + src/type-alias-convention.pin.test.ts 65 files / 1634 tests pass; vitest scripts 81 files / 1656 tests pass (VERDICT command-exit 0); spec typecheck VERDICT command-exit 0. Full spec suite locally exceeded the 10-minute foreground cap (exit 124, NOT MEASURED locally); CI Test Core (10 shards) green on a8d843b3. No ablation: the diff adds a new module, no existing pinned behaviour changed.", "gates": "local: spec build VERDICT 0; check:generated all 14 artifacts current; dispatch-gates --commands derived 109 commands, 101 exit 0, check:llms-txt exit 1 then fixed (exit 0 after the count edit), 7 exit 3 PREREQUISITE NOT MET = NOT MEASURED locally (check-plugin-teardown-shape --self-test shallow clone; lint check:doc-formula-expressions and check:doc-security-posture unbuilt packages; spec check:skill-examples, check:docs-transcript-drift, check:dual-build-cjs-loads, check:lean-entry-closure unbuilt closure). CI on a8d843b3: 70 check-runs, 60 success, 10 skipped, 0 failed: Lint & Repo Gates success, TypeScript Type Check success, Test Core success, Build Core success, Governed Surface Queue Guard success, Type Check UI success, Test UI success, Build & E2E UI success, Live E2E UI success, Dogfood Regression Gate success, Check Changeset success, Lint UI skipped (no ui diff). PR mergeable_state clean. The first head 3ce827f5 went red on Test Core (2/10) at scripts/dropped-refinements.test.ts header totals; fixed in a8d843b3.", "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm", "mcp_calls": "0", "api_writes": "2 — fleet-write relay pr_create (POST pulls + assignee leg) for #37930; this os-dev-report comment via post-stamped", "open_questions": [], "security_findings": "none", "out_of_scope_findings": ["carrier: none · noted, not filed: legacy readings over 24 characters or more than 4 entries answer null under the shared limits; cloud ask_which reading lengths are NOT MEASURED from this session (cloud repo out of scope), named in the PR's Acceptance notes for the L2"] }