Commit Graph

57 Commits

Author SHA1 Message Date
MarkLo127 5724cb612c 2026-03-13 15:48:37 +08:00
MarkLo127 1a409796d1 2026-03-12 23:07:36 +08:00
MarkLo127 8fa86ef6c0 Fix: Remove schema default from analysis_mode, rely on form defaultValues
- Removed .default('deep') from Zod schema to fix type inference
- The field is now purely required with no optional inference
- The default value is provided by useForm's defaultValues
- This cleanly separates schema validation from form defaults
2026-03-12 22:06:05 +08:00
MarkLo127 cad2889024 Fix: Remove .optional() from analysis_mode schema to fix type inference
- Changed from .optional().default() to just .default()
- This resolves the type mismatch with zodResolver and react-hook-form
- The field still defaults to 'deep' when not provided
2026-03-12 22:03:42 +08:00
MarkLo127 271175bb4d Fix: Resolve TypeScript error with analysis_mode field in AnalysisForm
- Changed analysis_mode schema from .default() to .optional().default()
- This fixes the type mismatch error in the resolver with zodResolver
- Allows the form to properly infer the field as optional with a default value
2026-03-12 21:54:34 +08:00
MarkLo127 9c0a9819e6 Implement Plan A1: Fast Mode Analysis
Features:
- Add analysis_mode parameter (fast/deep) to AnalysisRequest
- Fast mode (15-25 min): Disables investment and risk debates (max_debate_rounds=0)
- Deep mode (60 min): Default mode with debates enabled
- Update backend TradingService to handle analysis_mode
- Add analysis_mode form field to frontend with dropdown selector
- Update TypeScript interfaces to include analysis_mode

Changes:
- backend/app/models/schemas.py: Add analysis_mode field to AnalysisRequest
- backend/app/services/trading_service.py: Handle analysis_mode in create_config()
- backend/app/api/routes.py: Pass analysis_mode parameter to run_analysis()
- frontend/components/analysis/AnalysisForm.tsx: Add analysis_mode dropdown (fast/deep)
- frontend/lib/types.ts: Add analysis_mode to AnalysisRequest interface

When users select "fast mode", the system will:
1. Skip investment debate (max_debate_rounds = 0)
2. Skip risk debate (max_risk_discuss_rounds = 0)
3. Reduce analysis time from ~60 minutes to ~15-25 minutes
4. Still run all analyst reports with proper 500-1000 word counts
5. Provide initial decision without debate refinement

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-03-12 21:33:23 +08:00
MarkLo127 d95af6a64c 刪除claude被棄用的模型 2026-03-05 23:42:58 +08:00
MarkLo 16e513a921 新增英文語系支援 2025-12-24 01:20:33 +08:00
MarkLo 0f434546aa 2025-12-21 02:00:38 +08:00
MarkLo c673c52dda 2025-12-20 09:03:32 +08:00
MarkLo c4fc8904eb 2025-12-20 07:41:05 +08:00
MarkLo c9f6e6a8d1 2025-12-13 07:14:45 +08:00
MarkLo eed052abe9 2025-12-13 03:15:29 +08:00
MarkLo 5e48737ab8 2025-12-12 19:42:31 +08:00
MarkLo 5fa0ea027a 2025-12-12 19:32:11 +08:00
MarkLo 144f5793aa 2025-12-12 06:10:20 +08:00
MarkLo da7d05ecc9 2025-12-12 05:30:04 +08:00
MarkLo 71fb9844ee 2025-12-11 01:18:46 +08:00
MarkLo a51b31dc21 2025-12-11 00:37:19 +08:00
MarkLo 886694b62f 2025-12-10 23:51:07 +08:00
MarkLo 6c453ead59 2025-12-07 22:35:18 +08:00
MarkLo 0792830c3d 2025-12-07 16:51:11 +08:00
MarkLo 915ee9915c 2025-12-07 03:54:52 +08:00
MarkLo 43658df2a0 2025-12-06 02:28:43 +08:00
MarkLo a0e4365fc3 2025-12-06 01:50:41 +08:00
MarkLo 4f2327f5c2 2025-12-03 00:09:09 +08:00
MarkLo 0c955d4057 2025-12-02 23:46:59 +08:00
MarkLo 40f7d0bb92 2025-12-02 23:32:25 +08:00
MarkLo 34dc5b0f87 2025-12-02 23:03:41 +08:00
MarkLo 65c0033cca 2025-12-02 21:59:51 +08:00
MarkLo fd4aff76a1 2025-12-02 02:49:49 +08:00
MarkLo f2d73888a0 2025-12-01 19:52:45 +08:00
MarkLo 2bf7da4afd 2025-12-01 03:29:56 +08:00
MarkLo 409277abec 2025-12-01 03:11:49 +08:00
MarkLo 8304898d5c 2025-12-01 03:04:54 +08:00
MarkLo 196f723bd1 2025-12-01 02:28:16 +08:00
MarkLo 7e62df6ebf 2025-11-24 23:53:28 +08:00
MarkLo ae8f667eef 2025-11-24 12:23:00 +08:00
MarkLo 34774c587f 2025-11-24 12:18:01 +08:00
MarkLo 2137172e7b 2025-11-24 11:19:23 +08:00
MarkLo 6fcd6d896d 2025-11-24 11:08:34 +08:00
MarkLo 6c5a505282 2025-11-23 10:47:41 +08:00
MarkLo 58521527fd 2025-11-23 10:20:05 +08:00
MarkLo 02b83a6ddd 2025-11-23 07:31:00 +08:00
MarkLo 91ad37412b 2025-11-23 03:14:49 +08:00
MarkLo d42c22c5ce 2025-11-21 23:28:52 +08:00
MarkLo 540b5a9508 2025-11-21 05:44:26 +08:00
MarkLo e9fb61f1db 2025-11-21 05:41:26 +08:00
MarkLo e898ebb2b5 2025-11-21 05:12:02 +08:00
MarkLo d3c111640d 2025-11-21 04:57:35 +08:00