Skip to content

Continuous enhancement: AI briefing evidence UI#239

Open
ryun6249 wants to merge 22 commits into
AI4Finance-Foundation:masterfrom
ryun6249:automation/continuous-enhancement-20260519-0902
Open

Continuous enhancement: AI briefing evidence UI#239
ryun6249 wants to merge 22 commits into
AI4Finance-Foundation:masterfrom
ryun6249:automation/continuous-enhancement-20260519-0902

Conversation

@ryun6249

Copy link
Copy Markdown

Continuous Enhancement Report

1. Current Status

  • Project purpose: Local financial research workstation combining market data, macro, quant/backtest, Quantamental, ML Forecast, AI Portfolio, and local LLM briefing surfaces.
  • Existing structure preserved: Yes. Static FastAPI UI, existing dashboard filters, API contracts, and deterministic Quantamental service boundaries were preserved.
  • Main issues found: Quantamental backend AI guardrails produced used_data and structured sections, but the AI tab only displayed summary/bull/bear text. The top-right quality badge could briefly retain stale observation metadata after a range-triggered reload started.

2. Changes Made

Compatibility

  • Preserved existing API contracts, dashboard tab flow, Core/Diagnostics/Operations/All filters, and advisory-only strategy/trading boundaries.

Data Consistency

  • Added a pending top-right quality state for range reloads so stale observations are cleared while new tab data is recalculated.

UI/UX

  • Added Quantamental AI Used Data / 사용 데이터 summary with basis date, period, source, observations, missing data, model, AI snapshot, and cache state.

Visualization

  • No chart renderer math changed; chart/range behavior was re-verified through browser smoke and contract tests.

AI Briefing

  • Exposed structured AI guardrail sections in the Quantamental AI tab: key changes, interpretation, scenarios, and user actions.
  • Added a cache-busted Quantamental UI module bundle version.

Translation

  • Added Korean/English labels for the new AI briefing evidence UI and verified no mojibake markers.

Performance

  • No extra network calls; new UI renders from the existing ai_report payload.

Tests / Validation

  • Added a focused Node-backed pytest contract for the Quantamental AI panel.

3. Changed Files

File Change Reason
app/web/modules/quantamental-ui.js Added AI used-data and guardrail section rendering Make AI briefing evidence visible and data-grounded
app/web/app.js Added range-reload pending quality state Avoid stale quality metadata during reloads
app/web/index.html Bumped Quantamental UI bundle version Ensure browser loads updated module
tests/test_quantamental_ui_ai_panel.py Added English/Korean AI panel contract Guard used-data and translation rendering
tests/test_ui_routing_contract.py Updated bundle/marker assertions Keep static UI contract aligned
scripts/check_ui_contract.py Updated bundle and pending-state markers Catch regression in static checks
scripts/ai_portfolio_ui_smoke.py Updated Quantamental module version Keep browser smoke selector current
docs/CONTINUOUS_ENHANCEMENT_LOG.md Added 09:02 run log and validation results Automation continuity and audit trail

4. Validation Results

Check Command / Tool Result Notes
Lint git diff --cached --check Passed No whitespace errors in staged files
Build npm/pnpm build Not run Repo root has no frontend package manifest; static UI served by FastAPI
Test python -m pytest tests/test_ui_routing_contract.py -q Passed 39 passed, 4 subtests
Test python -m pytest tests/test_quantamental_ui_ai_panel.py -q Passed 1 passed
Test python -m pytest tests/test_ui_modules.py -q Passed 2 passed
Test python -m pytest tests/test_quantamental_api.py -q Passed 20 passed
UI validation Playwright MCP on http://host.docker.internal:8392/ui/?range=1Y#quantamental Passed v12 module loaded, All active, no horizontal overflow
UI validation python scripts/quantamental_ui_smoke.py --base-url http://127.0.0.1:8392 --output reports/quantamental_ui_smoke_continuous_20260519_0902.json Passed Required tickers, GLOBAL resolver, screens, Q&A, audit smoke passed
UI validation python scripts/ai_portfolio_ui_smoke.py --base-url http://127.0.0.1:8392 --timeout-s 150 --output reports/ai_portfolio_ui_smoke_continuous_20260519_0902_retry.json Passed First parallel run timed out on Macro search; standalone retry passed
Data validation Direct Macro search API + Quantamental smoke Passed Macro search returned DGS10; Quantamental smoke verified data quality surfaces
AI briefing validation Quantamental API tests + browser DOM fixture Passed Used data and guardrail sections visible without unsupported-number generation

5. Remaining Risks

  • This branch is stacked on prior continuous-enhancement commits while earlier PRs remain open.
  • The working tree still contains unrelated dirty/untracked files that were not staged by this run.
  • app/web/modules/quantamental-ui.js was already referenced by tracked HTML but was untracked locally; this PR adds it so the updated bundle is self-contained.

6. Next Enhancement Suggestions

  1. Move the Quantamental module into a smaller set of domain components once the stacked PRs settle.
  2. Add a real end-to-end AI-tab smoke that uses a lightweight fixture route instead of DOM injection.
  3. Normalize Macro search smoke timing so parallel browser runs do not compete for the same local server.

7. Safety Notes

  • main/master was not modified directly.
  • Auto-merge was not enabled.
  • Secrets were not touched.
  • Trading/order execution logic was not modified.
  • Unsupported facts were not presented as verified.

Your Name added 22 commits May 15, 2026 01:04
Add browser-based validation gate, decision-grade research pipeline, web UI, tests, and docs.

Archive legacy FinGPT and finogrid sources under legacy/archive while keeping runtime artifacts ignored.
Adds the FinGPT-native Quant Lab router split, artifact-backed workflows, replay/freshness controls, strategy governance, export verification/history, offline package verification, and guarded cross-run cleanup documentation and tests.

Verified before commit: python -m pytest tests -q (367 passed, 3 subtests passed), node --check app\\web\\app.js, python scripts\\check_ui_contract.py, python -m core.preflight, scripts\\verify_production_path.ps1, and quant_lab_ui_smoke.py.
@BruceYanghy

Copy link
Copy Markdown
Member

Thanks a lot. @ryun6249 Would you mind creating a separate branch and pushing your changes there instead of directly to the master branch? That will make it easier for us to review and test the updates safely before merging.

Bruce

Sign up for free to 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.

2 participants