Repository navigation
docs: the docs and spec comments describe trackHistory by the field-history model - #38238
Conversation
The data-modeling pages, the ObjectQL protocol pages and the metadata-driven concepts page glossed object `enable.trackHistory` as "field history tracking", and the field-types table called field `trackHistory` the activity-timeline switch. Field history is on by default: a changed field's old -> new values show on the activity stream, `fieldHistory: false` turns them off, and field `trackHistory` only opts a media or structured-JSON field in. Object `enable.trackHistory` shows the compliance ledger's field changes on the record page and gates the `history` verb; capture is always on, so it adds no write overhead either. The two spec comments that listed object/field `trackHistory` as the audit authoring surface say the same, and the security-context reference page is regenerated from the edited docblock. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L9qibwWRQzuBbuvfHQMtYc
📓 Docs Drift Check
What this run could not see
Coarse fallback — 177 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): |
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 Contract-review-claim: session_01L9qibwSEecrzDjKjbk24r1 · head 92b38c0 · 2026-11-28T10:07Z |
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 Contract reviewServed-tier: PR #38238, card #38154, PR 1 of 2 ( Inputs read: the card body and its three comments (triage 7234566550, claim 7236959512, os-dev-report 7237313116), the PR body, its two comments (docs-drift 7237319190, review claim 7237696348), its file list, the net diff, and the head's check-runs: 70 runs, 60 success, 10 skipped, none failed, none pending. ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgment
Against the card: Ask 1's object half (ledger view and No must-fix, no should-fix.
Implemented-by: VERDICT: PASS |
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 The brief the contract reviewer above was handed, filled, for the seat to read before it adopts the record: Contract review brief — PR #38238 @
|
|
repo:objectstack#3 · os-tesla · session_01L9qibwSEecrzDjKjbk24r1 L1-a ACCEPT at
|
|
repo:objectstack#3 · os-tesla · session_01L9qibyUSf2nKJWW6qBemSU Landing · 2026-11-28T10:17Z · zone
|
…, not trackHistory (objectstack-ai#38281) <!-- claude-projects-attribution: {"github_login":"os-tesla"} --> _Requested by **Tesla** · [project thread](https://claude.ai/code/project/chan_01AXsQkLFKRdQCqQ3RTr6Jao?thread=cmsg_01AXsQkLFKRdQCqQ3RTr6JaoUmHUYZvTYLKjq2dHpiHW6x)_ Fixes objectstack-ai#38154 repo:objectstack#3 · os-tesla · session_01L9qibwWRQzuBbuvfHQMtYc Clause-②: no Metadata-protocol: none ## 维护者速读 - 用户无感:项目技能自带的一道评测题,标准答案不再说「要字段历史就去设 trackHistory」,改成「字段改动的新旧值默认就显示」;评测 AI 写配置的能力时不再把错误做法当正确答案。 - 接上一个已合入的文档改写,这张卡的最后一半,替被这道题打分的 AI 和看评分的人纠正标准答案。 - 只改评测题标准答案里的半句话,题目和判分断言不变;若说法有误,最多是这道题评分不准,可以直接撤回。 - 无 ## What changes - `skills/objectstack-project/evals/project-process.json`, eval 9 (users need to see who changed which field on a record and when), one clause of `expected_output`: - before: "Leaves `activities` on, sets `trackHistory` where field-level history is wanted, and points the users at the timeline;" - after: "Leaves `activities` on, where a changed field's old and new values show by default (`fieldHistory`), and points the users at the timeline;" - The eval's `prompt`, its other sentences and its `assertions` are byte-identical: `must_contain` is still `sys_audit_log`, `sys_activity`; `must_not_contain` is still `name: 'audit_entry'`, `event: 'afterUpdate'`. - The replacement clause was drafted by an isolated `claude-fable-5-2` subagent (the tier `skills/**` mandates), read against the live source: `resolveFieldHistory` and `FIELD_HISTORY_DEFAULT_OFF_TYPES` in `packages/spec/src/data/field-history-default.ts`; the `enable.trackHistory`, `enable.fieldHistory` and `activities` describe text in `object.zod.ts`; the field `trackHistory` / `fieldHistory` describe text in `field.zod.ts`; and the plugin-audit writer, which mirrors to `sys_activity` when `enable.activities` is not false and decides values through `resolveFieldHistory`. - `@objectstack/skills` patch changeset: the package's build copies `skills/**` byte for byte into its published `dist/`. ## Tests - No test changes. The eval is a fixture read by the skill eval runner; its assertions are unchanged. <details><summary>Readings at 2c62317 (base origin/main d994002a, which carries PR objectstack-ai#38238)</summary> - Skills readings (whole file and whole bundle, lines): - `skills/objectstack-project/evals/project-process.json`: 176 → 176 lines; 11967 → 11987 bytes (+20). - Bundle, all `skills/*/SKILL.md`: 4940 → 4940 lines (no `SKILL.md` changed). Eval fixtures are outside the shipped-token ratchet's budgeted population. - `must_contain` unchanged: read from the parsed file, `['sys_audit_log', 'sys_activity']`. - Acceptance grep: `grep -rn trackHistory skills/objectstack-project/` → 0 hits. With PR objectstack-ai#38238 (PR 1 of this card) merged into this base, the card's grep over `content/docs`, `packages/spec/src/system` and the project skill's evals has no sentence that calls `trackHistory` the field-history switch. - Derived local gate set at 2c62317 (re-run after the rebase onto d994002a; same 44-family list as at e95f960d): `dispatch-gates --ran` reconciles 44 derived, 43 run (all exit 0), 1 NOT MEASURED (exit 3), 0 unrun. Left to CI: `check:dual-build-cjs-loads` (needs a full `pnpm build`; this diff moves no package's build shape). Built first: `@objectstack/spec`, `formula`, `lint`, `objectql` (14/14 tasks). </details> ## Acceptance notes - PR 2 of 2 for objectstack-ai#38154, as the claim set it. PR 1, objectstack-ai#38238, carried the docs pages and the spec comments. - The subagent's read of the rest of eval 9: "`sys_activity` (the record timeline, `enable.activities`, on by default)" and "`sys_audit_log` (every write is recorded)" hold against `object.zod.ts`; nothing else in the eval is the same defect. ## Verification Read first: `skills/objectstack-project/evals/project-process.json` eval 9 `expected_output` (the one changed clause). Two-minute check: `grep -rn trackHistory skills/objectstack-project/` prints nothing. --- _Generated by [Claude Code](https://claude.ai/code/session_01L9qibwWRQzuBbuvfHQMtYc)_ Co-authored-by: Claude <noreply@anthropic.com>
Requested by Tesla · project thread
Part of #38154
repo:objectstack#3 · os-tesla · session_01L9qibwWRQzuBbuvfHQMtYc
Clause-②: no
Metadata-protocol: none
维护者速读
What changes
resolveFieldHistoryenforces (the refusals merged in PR fix(spec): retired-key refusals prescribe the field-history model, not trackHistory #38064 say the same):content/docs/data-modeling/field-types.mdx: the fieldtrackHistoryrow now says it opts a media or JSON field into old → new values, that other fields show them already, and thatfalsedoes not hide them (fieldHistory: falsedoes).content/docs/data-modeling/objects.mdx(code comment and theenabletable row),content/docs/data-modeling/schema-design.mdx,content/docs/protocol/objectql/index.mdx,content/docs/concepts/metadata-driven.mdx: objectenable.trackHistoryis glossed as showing the audit ledger's field changes on the record page, not as "field history tracking". Theobjects.mdxrow adds thehistoryverb and says that every write is recorded either way and that values on the activity stream arefieldHistory's.content/docs/protocol/objectql/schema.mdx: the same gloss on theenableexample; the "Performance Impact" bullet no longer saystrackHistory: trueadds inserts to the audit table (the ledger records every write either way); the "When to enable" bullet says what it shows.packages/spec/src/system/index.tsand thesecurity-context.zod.tsmodule docblock no longer list fieldtrackHistoryas part of the audit authoring surface. They name the object'senable.trackHistory(ledger view,historyverb) beside the lifecycleauditretention, and say that field-change values arefieldHistory's.content/docs/references/system/security-context.mdxregenerated from that docblock (gen:schemathengen:docs; this one file changed).@objectstack/specpatch changeset: the edited.zod.tsdocblock ships in the package'sfiles[].Tests
check:generated/check:docs(readings below).Readings at 92b38c0 (base origin/main 9957484)
git grep -n -i "trackHistory" -- content/docs packages/spec/src/system skills/objectstack-project/evals ':!content/docs/releases' ':!content/docs/references', filtered for "field history", "history track", "track field", "field-level history", "timeline switch", "object/field": 0 hits incontent/docsandpackages/spec/src/system. The one remaining hit is the project skill's eval line, which is PR 2 of this card (below).content/docs/references/system/security-context.mdx):pnpm --filter @objectstack/spec buildexit 0 (lock VERDICT command-exit 0).dispatch-gates --ranreconciles 101 derived, 99 run (all exit 0), 2 NOT MEASURED (exit 3), 0 unrun. Five gates first answered PREREQUISITE NOT MET and were re-run afterturbo run buildof@objectstack/formula,@objectstack/lint...,@objectstack/objectql,@objectstack/client,@objectstack/client-react(47/47 tasks):check:doc-formula-expressions,check:doc-security-posture,check:skill-examples,check:docs-transcript-drift,check:lean-entry-closure, each exit 0.check:generatedandcheck:docsexit 0 with the regenerated page.check-plugin-teardown-shape.mjs --self-test(its fixture commit is out of this shallow clone's reach) andcheck:dual-build-cjs-loads(needs a fullpnpm build; this diff moves no package's build shape).Acceptance notes
protocol/objectql/schema.mdx"Performance Impact" (false: capture is always on) and "When to enable" bullets, same file and defect class.content/docs/releases/**(release history),content/docs/ui/pages.mdx(it already describes the object flag's ledger changes in the timeline),packages/lint/src/rule-explanations.ts(object meaning, correct), and the generated references other than the regenerated one (already in the fix(spec): retired-key refusals prescribe the field-history model, not trackHistory #38064 wording).trackHistory.trackChanges,feedTrackedandtrackedget thefieldHistoryanswer; their case and underscore variants (trackchanges,track_changes,FeedTracked,Tracked, …) get only the generic unrecognized-key refusal. Adding guidance for them is runtime refusal text, out of this card.Fixes #38154), after this one merges: theskills/objectstack-project/evals/project-process.jsoneval id 9 line that still "setstrackHistorywhere field-level history is wanted".Verification
Read first (by risk):
content/docs/data-modeling/objects.mdx: theenabletable'strackHistoryrow (the longest restatement).content/docs/protocol/objectql/schema.mdx: the "Performance Impact" bullet.packages/spec/src/system/index.ts: the audit-surface comment.Two-minute check:
git grep -n -i "field history track\|track field history\|enable field history" -- content/docsprints nothing.Generated by Claude Code