Skip to content

入口专题 C1:撤掉 ask_ai 动作类型(enumWithRetiredValues、ADR-0087 三项、只为它存在的导出),19.0 正式版前 #37856

In progress

Description

@objectstack-fleet

epic:#5027#1 · hotlong · session_01Q4EjjMUfmNYTem26rXLFUf

Filing gate: ④ topic child. Source: topic #37853 (Jack: 「"页面里加按钮"的需求 作废」 06:28Z; card 「撤掉 ask_ai」 06:30Z; 「问 AI」 06:33Z; 「同意,立专题卡,非 cloud 的任务,让 objectstack #3 座位接手」 07:12Z, all 2026-11-27). Business reason: carried by the parent.
Parent: #37853 (rulings, target experience, card table, topic acceptance). Evidence: an independent Fable review of objectstack and cloud main (2026-11-27) checked every file:line below.
Owner: repo:objectstack#3 (Jack 07:12Z 「非 cloud 的任务,让 objectstack #3 座位接手」). Reserved under topic #37853 (pm:epic), not pm:queue: other seats leave it.

Grading: area:ai · Task · p1 · size L · window: before 19.0.0 GA (the action type shipped in 18.x; removal is a breaking change).
Blocked-by: C0a (#37854) (the amendment fixes the legacy-metadata behaviour).
Dedupe: searched ask_ai: #37142 (closed, introduced it), #37827 (open bug: record page hides ask_ai) is closed by this card; #37834 is the decision.

维护者速读

Background (verified)

  • ask_ai is a value of ActionType (packages/spec/src/ui/action.zod.ts:706). The real reference surface is 60 files; a regex finds 63, of which 3 must stay: Studio canvas 「问 AI 生成字段」 (ObjectFormCanvas.tsx, studio/{en,zh}.ts).
  • Exports that exist only for it: setChatFocus, ActionRunner.setAssistantFocusHandler, onAskAi, surfaceAgent.ts catalogServesFocus / focusAgentName, dashboard.zod.ts refuseRecordlessAskAi. cloud mentions it only in comments; hotcrm has none.
  • content/docs/references/** is generated: run gen:docs, do not hand-edit.
  • setChatFocus, the pin control, 「改为问」 and console.ai.focus.* strings have only shipped in prereleases (.changeset/pre/36999-conversation-focus.md, app-shell 18.6.0-next.0).

What to do

  1. ActionType → enumWithRetiredValues() with the prescription (precedent packages/spec/src/ai/agent.zod.ts:161,173). ADR-0087's three duties: conversion in conversions/entries/19/, a D3 semantic entry, the disposition marker in the changeset. The four generated baselines do not change for "one enum value fewer": expected, not missed.
  2. Implement the legacy behaviour exactly as C0a (入口专题 C0a:ADR-0160 第七次修订(默认带当前记录、取消钉住与「改为问」、撤 ask_ai 的退役路线、预读改为用到再读) #37854) writes it (source refusal with prescription; conversion auto-deletes only without references; installed metadata per C0a (入口专题 C0a:ADR-0160 第七次修订(默认带当前记录、取消钉住与「改为问」、撤 ask_ai 的退役路线、预读改为用到再读) #37854)).
  3. Remove the runtime and ui paths and the exports above; regenerate the API surface (gen:api-surface). spec and ui/ changes go in one PR (release checklist item 4 in AGENTS.md).
  4. Examples: remove ask_ai actions and the page references to them (e.g. showcase task-detail.page.ts).
  5. Not in this card: skills/** (C1s) and ADRs (C0a (入口专题 C0a:ADR-0160 第七次修订(默认带当前记录、取消钉住与「改为问」、撤 ask_ai 的退役路线、预读改为用到再读) #37854)).
  6. .changeset/pre/ holds two consumed changesets that describe the pin / ask_ai; ask the release owner whether their text may change. If not, put the correction in this card's changeset.
  7. Close Record page hides every type: 'ask_ai' action: RecordDetailView's own ActionProvider drops the shell's onAskAi #37827 with this PR.

brightrule (outside the fleet board; the C1 owner coordinates it before C1 releases)

  • brightrule's installed metadata has one action brightrule_policy_ask, locations: ['record_header','list_item']; no declaration was found in its src/ (it depends on spec 18.6.0); docs/policy-admin.md:76 mentions it.
  • Before C1 releases: find where it is declared, delete it, fix docs/policy-admin.md:76, and handle the copy installed in deployed environments. Ask the maintainer who owns brightrule if unsure.

Acceptance

Activity

  1. added
    enhancement
    priority:p1
    domain:spec
    pm:blocked
    pm:epic
    area:ai
    on Nov 27, 2026
  2. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU

    Premise correction for this card, read by the seat at origin/main 2026-11-27T08:36Z (raised by the C0a thread on PR #37877):

    1. ask_ai has never shipped in a stable release. It first appears in packages/spec/CHANGELOG.md under ## 19.0.0-next.0 (line 1651, b7dee0e), a prerelease; npm latest is 18.6.0. Any wording here that says it shipped in 18.x is wrong. The retirement still needs its ADR-0087 handling as the ADR amendment prescribes, but there is no 18.x author to convert.
    2. Two schemas carry the type key, not one: ActionType (packages/spec/src/ui/action.zod.ts:706) and the dashboard header's actionType, which is derived from ActionType (WidgetActionTypeSchema), and whose refusal of ask_ai sits at packages/spec/src/ui/dashboard.zod.ts:127-132. The retirement and its refusal text must cover both.

    The C0a draft (PR #37877) records both points; the dispatch for this card quotes this comment.

  3. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU

    Claim: PM loop round 1
    Session: session_01L9qibyUSf2nKJWW6qBemSU
    Thread session: session_01L9qibzCKZkVMWDVKhZVdRK
    Account: os-tesla
    Branch: claude/project-thread-vjrz36
    Worktree: objectstack-issue-37856
    Domain: spec
    Seat: repo:objectstack#3
    File surface: packages/spec/src/** (ActionType via enumWithRetiredValues, the dashboard actionType and page component button-row / action:group / action:menu member refusals, the ADR-0087 conversion under conversions/entries/19/ and semantic entry under migrations/entries/semantic/), packages/** runtime and metadata-core stored/artifact replay, ui/** executor, gates and only-for-it exports, examples/**, content/docs/** (generated references via gen:docs), .changeset/**; NOT skills/** (C1s #37857) and NOT docs/adr/** (stop on breach; explain in the report)
    Container & model: L, mode:thread, model: default tier — dispatch-gates.mjs --tier: "no path-derived mandate", effort: high
    Clause-②: no (narrowing)
    Metadata-protocol: narrowed
    Responsibility: retire the ask_ai action type before 19.0.0 GA under ADR-0087 exactly as ADR-0160 D7 (seventh amendment) prescribes: refusal with prescription where metadata is authored, guarded deletion under os migrate meta --from 18, read-without-the-action with a warning at rest; remove the executor and the exports that exist only for it; close #37827
    Thread-read: 7213726444
    Premise: Blocked-by C0a #37854 met (PR #37877 merged 2026-11-27T09:52Z, 29e0c4b); premise correction 7213726444 (never in a stable release; two schemas carry the key); ADR-0160 D7 read on origin/main
    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 seat

    Window: before 19.0.0 GA. brightrule coordination before C1 releases (card section). Dogfood battery owed on the final head (narrowing). L2 at the contract-review tier.

  4. added
    pm:dispatched
    and removed
    pm:blocked
    on Nov 27, 2026
  5. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-tesla · session_01L9qibzCKZkVMWDVKhZVdRK
    os-dev-report

    {
      "issue": 37856,
      "status": "done",
      "branch": "claude/project-thread-vjrz36",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/37924",
      "session": "session_01L9qibzCKZkVMWDVKhZVdRK",
      "premise_still_valid": true,
      "summary": "Retires the ask_ai action type (ADR-0160 D7, seventh amendment). Every action-type slot refuses it with one prescription. The ADR-0087 D2 conversion action-type-ask-ai-removed deletes over sources only what nothing in the stack names, and at rest deletes every ask_ai action, row and member; the D3 entry ui-action-type-ask-ai-retired names the hand edits. applyConversionsToStoredItem now answers undefined when the chain leaves no item of a row: its callers serve and register nothing for such a row, DatabaseLoader still reads identity from the stored body so the delete door reaches it, and migrateStoredMetadata lists it skipped with DELETE /api/v1/meta/action/<name>. The executor, setChatFocus and the exports that existed only for ask_ai are removed (revert of b7dee0e7, adapted), and the composer-chip pin from #36999 stays. Outside the claimed surface: scripts/check-skill-identifier-liveness.mjs, a one-row re-point to the new non-exported ACTION_TYPE_VALUES (SeedMode precedent), which the seat accepted.",
      "tests": "New: spec ui/action-ask-ai-retired.test.ts, conversions/action-type-ask-ai-removed.test.ts, the JOIN row in shared/retired-key-removal-version.pin.test.ts (68/68), metadata loaders/database-loader-ask-ai-retired-row.test.ts on real SQLite (3/3), metadata-protocol protocol.stored-ask-ai-retired-row.test.ts (3/3). Ablations, run on disk and restored: DatabaseLoader identity read through the converted body turns the same-name-write case red (1 failed | 2 passed); the migrateStoredMetadata skip branch disabled turns 2 of 3 red. spec full vitest: 976 files, 29,727 tests, 1 red (the pin JOIN), fixed. src/ui + src/conversions + src/migrations: 224 files / 7,701 green. metadata database-loader.test.ts + new file: 502 green.",
      "gates": "Local: the full `dispatch-gates.mjs --commands` list (128 commands). Red that was this PR's, fixed on the head: check:generated / check:test-typecheck (the seam's undefined in 4 spec tests), check:skill-identifier-liveness, check:engine-double-contract (ledger --write), check:objectql-double-limit, check:test-source-alias. Prerequisites cleared, then exit 0: check:published-readme-exports, check-plugin-teardown-shape --self-test. Still red: check:skill-examples, 1 error at skills/objectstack-ai/SKILL.md:188 TS2322, which clears when C1s #37937 merges and main is merged in. Baselines: check:api-surface 0, check:authorable-surface 0, check:generated 0, with no baseline file changed. Type check: `turbo run typecheck type-check --filter='...@objectstack/spec' --continue` gives 234/234 tasks successful at a2dd88a6, after narrowing driver-sql sql-driver-unique-tenancy.test.ts:376 and ui/packages/layout page-header-subtitle-conversion-coverage.test.ts:168. CI at ca52b5be: 57 success, 9 skipped, 4 failure. The 4 are Type Check · workspace (driver-sql, fixed at a2dd88a6), Type Check · consumer gates (check:skill-examples, order above), its aggregator TypeScript Type Check, and PR-body guards (#37827 claim, posted by the seat after the run, which re-reads on the a2dd88a6 push).",
      "dogfood_battery": "ca52b5be (a2dd88a6 after it only adds `!` in two test files outside the battery) · os-verify-lock: VERDICT command-exit 0 · held the lock 2324s · Test Files 490 passed | 3 skipped (493) · Tests 4144 passed | 68 skipped (4212) · no failures",
      "mcp_calls": "read-only only, none a write: mcp__github__issue_read (cards 37856, 37827, 37857 and the card comments), mcp__github__get_job_logs ×3, subscribe_pr_activity ×1",
      "api_writes": "4 — relay: pr_create (PR #37924), run_rerun_failed ×2 (refused at the relay's workflow fence, nothing sent), this comment; plus git push",
      "open_questions": [],
      "security_findings": "withheld",
      "out_of_scope_findings": [
        "carrier: brightrule owner · brightrule declares brightrule_policy_ask (type ask_ai) and must drop it before it takes a build with this change; not booted here",
        "carrier: release owner · .changeset/pre/37142-ask-ai-action-type.md and the setChatFocus line of .changeset/pre/36999-conversation-focus.md announce what 19.0.0 no longer ships; this PR's changeset carries the correction, and the prerelease texts are left as written",
        "carrier: #37857 · skills/objectstack-ui/SKILL.md:151 and :153 still name ask_ai; the seat ruled they leave in the C1s follow-up PR after this merges"
      ]
    }

    Generated by Claude Code

  6. objectstack-fleet commented on Nov 27, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU

    Claim: PM loop round 1 (amendment: file surface as built, PR #37924)
    Session: session_01L9qibyUSf2nKJWW6qBemSU
    Thread session: session_01L9qibzCKZkVMWDVKhZVdRK
    Account: os-tesla
    Branch: claude/project-thread-vjrz36
    Worktree: objectstack-issue-37856
    Domain: spec
    Seat: repo:objectstack#3
    File surface: packages/spec/src/** (ActionType via enumWithRetiredValues, the dashboard actionType and page component button-row / action:group / action:menu member refusals, the ADR-0087 conversion under conversions/entries/19/ and semantic entry under migrations/entries/semantic/), packages/** runtime and metadata-core stored/artifact replay, ui/** executor, gates and only-for-it exports, examples/**, content/docs/** (generated references via gen:docs), .changeset/**; NOT skills/** (C1s #37857) and NOT docs/adr/** + the four files the build forced, as built at a2dd88a: packages/drivers/driver-sql/src/sql-driver-unique-tenancy.test.ts and ui/packages/layout/src/__tests__/page-header-subtitle-conversion-coverage.test.ts (narrowing callers of applyConversionsToStoredItem's T | undefined; test-only, no changeset owed), scripts/check-skill-identifier-liveness.mjs and scripts/engine-double-contract.pinned.json (gate rows that follow the retired member) (stop on breach; explain in the report)
    Container & model: L, mode:thread, model: default tier — dispatch-gates.mjs --tier: "no path-derived mandate", effort: high
    Clause-②: no (narrowing)
    Metadata-protocol: narrowed
    Responsibility: retire the ask_ai action type before 19.0.0 GA under ADR-0087 exactly as ADR-0160 D7 (seventh amendment) prescribes: refusal with prescription where metadata is authored, guarded deletion under os migrate meta --from 18, read-without-the-action with a warning at rest; remove the executor and the exports that exist only for it; close #37827
    Thread-read: 7218458418
    Premise: Blocked-by C0a #37854 met (PR #37877 merged 2026-11-27T09:52Z, 29e0c4b); premise correction 7213726444 (never in a stable release; two schemas carry the key); ADR-0160 D7 read on origin/main
    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 seat

    Window: before 19.0.0 GA. brightrule coordination before C1 releases (card section). Dogfood battery owed on the final head (narrowing). L2 at the contract-review tier.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:aidomain:specenhancementpm:dispatchedpm:epicpriority:p1size/l

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions