Skip to content

perf(answer): optimise ECG loading pulse - #1862

Merged
BigSimmo merged 5 commits into
mainfrom
codex/chat-ecg-pulse-optimisation-answer-ecg-animation
Aug 13, 2026
Merged

perf(answer): optimise ECG loading pulse#1862
BigSimmo merged 5 commits into
mainfrom
codex/chat-ecg-pulse-optimisation-answer-ecg-animation

Conversation

@BigSimmo

@BigSimmoBigSimmo commented Aug 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Optimises the existing ECG answer-loading trace with a shorter travelling pulse and faster, density-specific timing: 1.8s expanded and 1.6s compact.
  • Keeps the animation ultra-lightweight: one inline SVG sweep path animated by CSS stroke-dashoffset, with no JavaScript timer, canvas, new runtime state, or dependency.
  • Preserves a static ECG baseline for reduced-motion users, forced-colour support, compact follow-up placement, and removes the trace when generation completes or errors.

RAG impact: no retrieval behaviour change — this PR changes only answer-progress animation timing, pulse length, and browser coverage; retrieval, ranking, prompts, citations, and answer payloads are unchanged.

Verification

  • npm run verify:pr-local
    • Partial due repository coordinator contention: runtime, installed-lock parity, changed-file formatting, and lint passed; admission was then denied while another worktree held focused-test capacity.
  • npm run format — passed twice, including the final committed ledger state.
  • npm run check:design-system-contract — passed.
  • npm run typecheck — passed; the final isolated production build also completed TypeScript validation.
  • Focused Vitest — 41/41 passed (answer-progress.test.ts 8/8; tailwind-merge-config.test.ts 33/33).
  • Focused Chromium answer-progress journeys — expanded timing, compact follow-up timing, error cleanup, reduced motion, and forced colours passed. The compact journey was rerun 1/1 after explicitly selecting normal-motion media; the preceding full run's other 3 journeys passed.
  • Isolated production build — passed, including TypeScript and 1,710 generated pages.
  • npm run eval:rag:offline — fixture and manifest validation passed (36 golden cases, 23 suites); the command then exited nonzero because its follow-up Vitest admission was denied by another worktree's Playwright lease.
  • npm test
    • Ran once. Broad suite reported 25 unrelated Windows/harness failures, dominated by missing POSIX ln/Bash exit 127, temporary-directory EPERM cleanup, and hosted-Linux provenance fixtures. The focused changed-owner suites remained green.
  • npm run check:production-readiness
    • Ran and failed closed in the isolated worktree because Supabase/OpenAI credentials are intentionally absent. Node 24 and the query-hash boot guard passed; no provider call was made.
  • UI verification not run: the full verify:ui gate was not stacked after focused changed-owner Chromium proof.
  • Release verification not run: this PR is not a release or deployment.
  • Live retrieval/answer evals not run: retrieval, synthesis, prompts, citations, and answer payloads are unchanged.

Risk and rollout

  • Risk: Low. Animation-only CSS/SVG timing change. Residual visual/compositor risk remains on physical iOS Safari and installed PWA because local Chromium cannot prove those environments.
  • Rollback: Revert commits 55347084da56f7888b57f7811007b2146e60abe9 and 6a8f940f3a1a2521b17e52f85218755e43046269.
  • Provider or production effects: GitHub branch and this PR only. No deployment, production mutation, clinical data access, or model/provider request.

Clinical Governance Preflight

  • Source-backed claims still require linked source verification before clinical use
  • No patient-identifiable document workflow was introduced or expanded without explicit governance approval
  • Supabase target remains Clinical KB Database (sjrfecxgysukkwxsowpy)
  • Service-role keys and private document access remain server-only
  • Demo/synthetic content remains clearly separated from real clinical sources
  • Source metadata, review status, and outdated/unknown-source behavior remain conservative
  • Deployment classification/TGA SaMD impact was checked; clinical decision-support behavior is unchanged

Notes

  • Final scoped review found no P0–P3 defect.
  • The branch is 47 commits behind the refreshed remote base, but a read-only merge-tree check confirmed a clean merge. The append-only ledger preserves both histories.

Summary by CodeRabbit

  • Enhancements

    • Improved answer activity animations with faster, more responsive visual feedback.
    • Added optimized animation behavior for compact activity traces.
    • Shortened the highlighted activity-trace segment for clearer progress indication.
  • Accessibility

    • Enhanced reduced-motion and forced-colour handling for answer progress states.
  • Bug Fixes

    • Improved cleanup of activity indicators after invalid final responses.
  • Tests

    • Expanded coverage for animation timing, rendering, accessibility behavior, and follow-up generation.

@supabase

supabaseBot commented Aug 12, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai

coderabbitaiBot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: a8eaf254-5c0f-4d18-9434-4a7374ec8671

📥 Commits

Reviewing files that changed from the base of the PR and between 179ef20 and 921e076.

📒 Files selected for processing (5)
  • docs/branch-review-ledger.md
  • src/app/globals.css
  • src/components/clinical-dashboard/answer-status.tsx
  • src/lib/tailwind-merge.ts
  • tests/answer-progress-ui-smoke.spec.ts

📝 Walkthrough

Walkthrough

The pull request tunes answer activity trace animations, adds compact-density animation support, expands answer-progress smoke-test assertions, and appends August 11–12, 2026 review records to the branch ledger.

Changes

Answer activity trace animation

Layer / File(s)Summary
Animation tokens and trace rendering
src/app/globals.css, src/lib/tailwind-merge.ts, src/components/clinical-dashboard/answer-status.tsx
The default ECG animation is shortened to 1.8 seconds. Compact traces use a 1.6-second token. Tailwind merge recognizes the token, and the SVG dash pattern changes.
Answer progress animation validation
tests/answer-progress-ui-smoke.spec.ts
Smoke tests verify trace presence, animation properties, normal and reduced-motion behavior, and removal after invalid final payloads.

Branch review ledger

Layer / File(s)Summary
Append-only review records
docs/branch-review-ledger.md
The ledger adds August 11–12, 2026 records for reviews, CI updates, corrections, deferred items, and validated findings.

Estimated code review effort: 2 (Simple) | ~10 minutes

Mergeability Score:⚪ Minimal · up to 921e0

This PR only adjusts the ECG loading animation’s visual timing and preserves existing behavior. No actionable merge-blocking risk remains after normal checks and review.

Possibly related PRs

Suggested reviewers:claude

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check nameStatusExplanation
Title check✅ PassedThe title clearly and concisely describes the main change: optimizing the ECG answer-loading pulse.
Description check✅ PassedThe description covers the required summary, verification, risk, rollout, governance, and notes sections with clear results and reasons for incomplete checks.
Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check✅ PassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes check✅ PassedCheck skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/chat-ecg-pulse-optimisation-answer-ecg-animation

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed: dependency version conflict. Check your lock file or package.json.


Comment @coderabbitai help to get the list of available commands.

…at-ecg-pulse-optimisation-answer-ecg-animation
@BigSimmoChatGPT Codex Connector

Copy link
Copy Markdown
OwnerAuthor

@codex Fix the failing PR mergeability checks by merging the current origin/main into this existing feature branch, resolving any conflicts safely, running the smallest relevant repository checks, running npm run format, committing the result, and pushing with an ordinary non-force push. Verify the pushed 40-character head SHA and the resulting hosted checks. Do not rebase or rewrite history, force-push, merge or close the PR, enable auto-merge, delete or rename branches, push to any protected branch, deploy, access production data, or invoke live OpenAI/Supabase providers. If GitHub write access is unavailable, stop and report the exact missing capability without attempting credential workarounds.

@chatgpt-codex-connector

Copy link
Copy Markdown

Blocked: GitHub write capability unavailable

I stopped before fetching, merging, formatting, committing, pushing, or modifying the pull request because this environment has no authenticated GitHub write path:

  • gh auth status reports: “You are not logged into any GitHub hosts.”
  • No authenticated GitHub connector/MCP or make_pr capability is available in this session.
  • Repository policy requires reporting this platform limitation rather than attempting PAT, credential, remote-URL, or login workarounds. AGENTS.mdL1075-L1088

The checkout remains clean and unchanged at 55347084da56f7888b57f7811007b2146e60abe9. No commit or pull request was created, which avoids producing a local-only commit that could not be published or verified.

Checks

  • git status --short --branch — clean working tree on local branch work.
  • git rev-parse HEAD55347084da56f7888b57f7811007b2146e60abe9, matching the supplied PR head.
  • gh auth status — no authenticated GitHub host; therefore an ordinary push, pushed-head verification, hosted-check inspection, and PR creation/update cannot be performed.
  • ⚠️npm run format — not run because the trigger explicitly requires stopping when GitHub write access is unavailable; running it could create unpublished changes.
  • ⚠️ Merge and repository tests — not run for the same hard-stop condition.

View task →

@BigSimmo
BigSimmo enabled auto-merge August 12, 2026 21:43
@BigSimmo
BigSimmo disabled auto-merge August 12, 2026 21:51
@BigSimmo
BigSimmo enabled auto-merge August 12, 2026 21:54
@BigSimmo
BigSimmo disabled auto-merge August 12, 2026 22:06
@BigSimmo
BigSimmo enabled auto-merge August 12, 2026 22:08
@BigSimmo
BigSimmo disabled auto-merge August 12, 2026 22:48
@BigSimmo
BigSimmo enabled auto-merge August 12, 2026 23:08
@BigSimmo
BigSimmo disabled auto-merge August 12, 2026 23:17
@BigSimmo
BigSimmo enabled auto-merge August 12, 2026 23:38
@BigSimmo
BigSimmo disabled auto-merge August 12, 2026 23:50
@BigSimmo
BigSimmo enabled auto-merge August 13, 2026 00:07
@BigSimmo
BigSimmo disabled auto-merge August 13, 2026 00:17
…at-ecg-pulse-optimisation-answer-ecg-animation
@BigSimmo
BigSimmo merged commit cb001b9 into mainAug 13, 2026
29 of 30 checks passed
@BigSimmo
BigSimmo deleted the codex/chat-ecg-pulse-optimisation-answer-ecg-animation branch August 13, 2026 00:33
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@BigSimmo