Skip to content

fix(llm): switch models and add monitor auto-reset - #28

Merged
mertkaradayi merged 2 commits into
mainfrom
dev
Jan 5, 2026
Merged

fix(llm): switch models and add monitor auto-reset#28
mertkaradayi merged 2 commits into
mainfrom
dev

Conversation

@mertkaradayi

Copy link
Copy Markdown
Owner

Summary

  • Switch from unreliable nvidia model to xiaomi/mistral for LLM analysis
  • Add auto-reset for monitors stuck too far behind (50k checkpoint threshold)
  • Reorganize dashboard header layout with sort dropdown

Changes

Backend (LLM Fix)

  • Replace nvidia/nemotron-3-nano-30b-a3b:free with xiaomi/mimo-v2-flash:free as primary
  • Use mistralai/devstral-2512:free as single fallback (simplified from 3-tier to 2-tier)
  • Remove getSecondFallbackConfig and simplify retry logic

Backend (Monitor Reset)

  • Add resetMonitorCheckpoint() function to supabase.ts
  • Add auto-reset in sui-monitor when gap exceeds 50k checkpoints
  • Add POST /api/admin/reset-checkpoint endpoint for manual recovery
  • Export LIVE_BOOTSTRAP_OFFSET constant for reuse

Frontend

  • Move search bar next to Start Analysis button
  • Add sort dropdown (newest, oldest, highest/lowest risk)
  • Clean up unused imports and consolidate layout

Test plan

  • Deploy to Railway and verify monitors auto-reset if behind
  • Trigger LLM analysis and confirm xiaomi model responds with valid JSON
  • Test admin reset endpoint manually
  • Verify dashboard sort dropdown works correctly

- Replace unreliable nvidia model with xiaomi/mimo-v2-flash:free as primary
- Use mistralai/devstral-2512:free as single fallback tier
- Remove fallback2 (3-tier reduced to 2-tier) for simpler retry logic
- Add resetMonitorCheckpoint() function to supabase.ts
- Add auto-reset in sui-monitor when gap exceeds 50k checkpoints
- Add POST /api/admin/reset-checkpoint endpoint for manual recovery
- Export LIVE_BOOTSTRAP_OFFSET constant for reuse

The nvidia model was returning HTTP 200 with invalid JSON (empty {}),
causing parse failures that didn't trigger fallback. Monitor checkpoints
were stuck 3.5M behind due to old database values from prior deploys.
- Move search bar next to Start Analysis button for better UX
- Add sort dropdown (newest, oldest, highest/lowest risk)
- Remove unused Card import
- Clean up search result display styling
- Reduce file size by 120 lines through layout consolidation
@vercel

vercel Bot commented Jan 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
redflag Ready Ready Preview, Comment Jan 5, 2026 2:36pm

@mertkaradayi
mertkaradayi merged commit eac6f6b into main Jan 5, 2026
3 checks passed
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.

1 participant