Commit Graph

544 Commits

Author SHA1 Message Date
Jesse_Chen e1db576284 fix(consult): let the declared domain decide the route, not the question text
Independent Staging Quality Gate / validate (push) Successful in 14m21s
Independent Staging Quality Gate / publish (push) Has been cancelled
A staging consultation asked one question about two domains, career and
wealth. The model planned both, and all four attempts failed identically with
calculation_failed. The server resolves the workflow route from the question
text — an explicit-timing check, then keyword domain_tokens, falling back to
the themes argument only when the text yields nothing — while the frontend
declares strict_workflow_route from the domain it chose. The plan contract then
requires the text-derived route to equal the declared one, and each
RouteContract allows exactly one, so the mismatch became
ConsultationPlanContractError, BadRequest, HTTP 400, workflow_bad_request.
Here "事业" is in the career token list and "财运" is not in the wealth one, so
both calls resolved to career and the wealth call was rejected every time.

Widening the token list would only move the contradiction to the next
phrasing. The frontend sends one Python call per domain with the same question
text, so text routing can agree with at most one domain of a multi-domain plan
and every other domain is refused by construction. Now that 1955ba8c caps the
plan at three domains and merges the per-domain packets into one top-level
contract, two- and three-domain plans are expected to work end to end and this
is what stops them.

Make the server-issued declaration authoritative. declared_workflow_route()
returns the route a complete, version-supported, allowlisted plan declares, and
resolve_route() honours it instead of reading the text; a caller that sends no
plan metadata keeps the text heuristics verbatim, so the MCP strict_workflow
tool and the research callers behave exactly as before. The route packet
records which rule decided, because routing now has two legitimate sources.

This is not a way to silence the 400: the whole packet comes from the declared
domain's RouteDefinition, so the sync steps, the consumer_context required
layers, the evidence packet and the frontend's themes[primary_theme] lookup all
land on the domain that was declared. A call declaring wealth can no longer
execute career and label career evidence as wealth. The contract stays
fail-closed — a route off the allowlist is refused before execution, and
themes, layers, boundary, domains, categories, depth, horizon and precision are
still checked one by one. The surviving resolved_routes check changes meaning
rather than going away: it now asserts the workflow executed what was declared.

The timing prefix "应期与阶段问题:" existed only to inject 应期 so the text
router would agree with the declared route for one domain out of ten. With the
declaration authoritative it fixes nothing and still rewrites the question the
model's answer derives from, so it goes. It influences no other server
behaviour: it matches none of the consumer-context domain regexes, and the
timing route already sets precise_timing_requested.

test_consultation_workflow_domains.py deliberately sent no plan metadata, which
is why this was never caught — its per-domain question happened to route to its
own domain. It now sends the real plan for all ten canonical domains behind one
question whose text routes to career; nine of them fail without this change.

Refs BUG-259.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-17 18:10:00 +08:00
Jesse_Chen e8d201dd9a perf(chat): isolate the composer, split heavy chunks, fix dead tokens
Independent Staging Quality Gate / validate (push) Successful in 13m15s
Independent Staging Quality Gate / publish (push) Successful in 10m9s
Second batch from the staging UX audit (BUG-248..253).

- css: expose the 32 palette tokens through @theme. Seven utilities
  including text-ink, text-danger and text-warning compiled to no CSS
  at all, so 30 call sites had been silently inert (BUG-248)
- chat: move the composer into its own component behind a draft store,
  so a keystroke no longer re-renders a 2723-line component, and
  persist the draft across reloads (BUG-249)
- chat: load gsap, react-markdown and thinking-orbs on demand. First
  Load JS for / drops 549.5 kB to 476.3 kB gzipped (BUG-250)
- chat: route the five in-app destinations through router.push, and
  keep the five auth redirects and the bootstrap retry as hard loads
  on purpose (BUG-251)
- a11y: announce reply completion, and move the live region out of the
  aria-busy subtree that was likely suppressing even the start
  announcement (BUG-252)
- docs: give the 27 collided bug ids unique numbers and repair their
  inbound references; require search rather than a full read of a
  3690-line file (BUG-253)

Verified: tsc, eslint, next build, and 1592 assertions across the 199
non-database test files.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-17 14:16:05 +08:00
Jesse_Chen 5bcc283d26 merge: integrate consultation runtime v2 into staging 2026-08-15 12:28:28 +08:00
Jesse_Chen 24fc83d972 Merge codex/pr2-final-response into staging integration 2026-08-15 12:27:00 +08:00
Jesse_Chen 3756c0ed9d merge: integrate upstream governance into staging 2026-08-15 12:17:22 +08:00
Jesse_Chen 8abd248f49 feat(governance): pin selective upstream import contract 2026-08-15 12:13:09 +08:00
Jesse_Chen 6d192ad175 feat: add consultation and product domain registries 2026-08-15 06:04:23 +08:00
Jesse_Chen 5012ff7212 feat: add persistent personal report document v2 2026-08-15 05:10:37 +08:00
Jesse_Chen 83fef19779 feat: add rectification event decision contract v2 2026-08-15 00:56:06 +08:00
Jesse_Chen 65a75ab29f feat(consultation): enforce server plan boundaries 2026-08-14 20:22:52 +08:00
Jesse_Chen c1f1819de1 feat(skill): add immutable package registry and receipts 2026-08-14 16:37:53 +08:00
Jesse_Chen 620131d6a8 fix: keep foreground consultations responsive 2026-08-11 11:59:14 +08:00
Jesse_Chen 10724e9dab fix: request official VedAstro evidence in gateway
Staging Backend Quality Gate / validate (push) Successful in 11m17s
Staging Backend Quality Gate / publish (push) Successful in 6m26s
2026-08-10 20:17:35 +08:00
Jesse_Chen b637528f14 fix: propagate consultation evidence before audit
Staging Backend Quality Gate / validate (push) Successful in 12m37s
Staging Backend Quality Gate / publish (push) Successful in 8m25s
2026-08-10 19:40:11 +08:00
Jesse ed2294875b merge: sync origin/main (22bbf8ab) into docs/correct-report-smoke
Staging Backend Quality Gate / validate (push) Successful in 11m30s
Staging Backend Quality Gate / publish (push) Successful in 6m49s
Resolve conflicts:
- globals.css: keep origin/main disabled opacity 1 (BUG-140 parity)
- consultation-entrypoint.test.ts: keep origin/main sticky-hover + disabled rules
- BUG_HISTORY.md: keep origin/main BUG-139 (staging admin), renumber local
  Python prework fix to BUG-158
2026-08-10 17:59:37 +08:00
Jesse 8fb6b65b01 wip: local BUG-139/BUG-140 fixes before syncing origin/main
- pre_work_check.py: prefer repo .venv Python >=3.11, strict JYOTISH_PRE_WORK_PYTHON override, fail closed
- tests/test_pre_work_check.py: regression coverage for venv preference / system 3.9 / strict override
- globals.css: transient :active pressed feedback for entrypoint cards, hover only under (hover: hover)
- consultation-entrypoint.test.ts: sticky-hover regression test
- BUG_HISTORY.md: BUG-139 / BUG-140 records
- pre_work_error_ledger.md: ERR-078 resolved entry
2026-08-10 17:57:06 +08:00
Codex 65bcef3001 feat: add global asynchronous report center
Staging Backend Quality Gate / validate (push) Has been cancelled
Staging Backend Quality Gate / publish (push) Has been cancelled
2026-08-09 20:24:09 -07:00
Jesse_Chen 61673d3a8b test: register membership orders route
Staging Backend Quality Gate / validate (push) Successful in 13m3s
Staging Backend Quality Gate / publish (push) Has been cancelled
2026-08-09 09:00:43 +08:00
Jesse 0ff9dc039f test(audit): register membership app route
Staging Backend Quality Gate / validate (push) Failing after 11m19s
Staging Backend Quality Gate / publish (push) Has been skipped
2026-08-07 18:43:02 +08:00
Jesse_Chen f3946eaa6f chore: retire legacy rectification runtime
Staging Backend Quality Gate / validate (push) Failing after 9m57s
Staging Backend Quality Gate / publish (push) Has been skipped
2026-08-07 12:55:32 +08:00
Jesse_Chen de2caf6249 test(audit): include billing admin routes
Staging Backend Quality Gate / validate (push) Failing after 10m43s
Staging Backend Quality Gate / publish (push) Has been skipped
2026-08-06 20:50:42 +08:00
Jesse 58894b201b test(report): register report reader in capability audit
Staging Backend Quality Gate / validate (pull_request) Failing after 12m13s
Staging Backend Quality Gate / publish (pull_request) Has been skipped
2026-08-06 13:21:04 +08:00
Jesse 82dab96b07 feat(report): add personal report contract and persistence 2026-08-06 12:43:10 +08:00
Jesse 03d3b58ff7 feat(skill): merge upstream reader-report contract 2026-08-06 11:31:51 +08:00
Jesse 685ed00e2f feat(sync): enforce one-way yinduzhanxing import policy 2026-08-06 11:25:34 +08:00
Jesse_Chen 5957803de4 Merge GitHub upstream into Gitea primary 2026-08-05 11:13:34 +08:00
Jesse_Chen a7a11a1a7a feat(rectification): drive questions from candidate contrast 2026-07-31 13:17:00 +08:00
Jesse_Chen bab5647afc fix(rectification): enforce director evidence boundaries 2026-07-31 06:13:47 +08:00
Jesse_Chen 0e3ce47678 refactor(rectification): let director agent own interview flow 2026-07-30 17:56:10 +08:00
linmeng f4e35974c6 Revert "merge: sync GitHub staging to Gitea"
Deploy staging to test server / deploy (push) Failing after 14m49s
This reverts commit a55c69115d, reversing
changes made to 02c9c9f3d6.
2026-07-30 14:38:17 +08:00
Jesse_Chen 31e5709f33 feat: add VedAstro rectification post-validation 2026-07-30 11:48:02 +08:00
Jesse_Chen 2384faf367 feat: harden rectification candidate validation 2026-07-30 10:55:39 +08:00
Jesse_Chen a5f409a500 fix: align rectification spec hashes across runtimes 2026-07-29 22:49:17 +08:00
Jesse_Chen 163d3fd1be fix: stabilize rectification staging release 2026-07-29 18:17:46 +08:00
Jesse_Chen 8ade6ed5c8 refactor: rebuild birth time rectification agent 2026-07-28 13:04:30 +08:00
Jesse_Chen 2ca245d643 feat: rebuild birth time rectification workflow 2026-07-27 09:57:14 +08:00
Jesse_Chen 0e6ed6ba79 fix: make conversational rectification converge 2026-07-25 11:50:41 +08:00
Jesse_Chen 8150df8942 fix: preserve rectification streaming and history 2026-07-25 02:08:10 +08:00
Jesse_Chen 3ca30ed7de feat: complete minute birth-time rectification flow 2026-07-25 01:17:14 +08:00
732642856 0013a4e633 sync: add remaining observation packets 2026-07-23 21:58:15 +08:00
732642856 2c882ef067 merge: update main before timing rectification sync 2026-07-23 20:50:53 +08:00
732642856 3ce3f63692 sync: add timing freeze and gulika fix 2026-07-23 20:35:14 +08:00
732642856 91e9da4c1c sync: add timing rectification freeze packet 2026-07-23 20:21:27 +08:00
Jesse_Chen 0850619eaf fix: preserve trusted rectification history 2026-07-23 14:58:56 +08:00
Jesse_Chen 1d841ec80a merge: conversational birth-time rectification
# Conflicts:
#	docs/BUG_HISTORY.md
2026-07-23 13:17:04 +08:00
Jesse_Chen f9010c8797 feat: make birth-time rectification conversational 2026-07-23 13:12:09 +08:00
732642856 32b10cb06a sync: add keyed VedAstro observation packet 2026-07-23 12:52:26 +08:00
732642856 543c857c4a sync: add pyjhora boundary matrix 2026-07-23 12:39:10 +08:00
732642856 8b9671ed27 sync: import research boundary evidence packets 2026-07-23 12:03:58 +08:00
732642856 67f667b54e sync: import technique closure packets round 2 2026-07-22 23:40:59 +08:00