Commit Graph

270 Commits

Author SHA1 Message Date
63f8f3562a feat: add VLM tags display to search result cards
- Shows up to 5 tags per card
- Uses localized language (tag.local) if available, falls back to English
- Styled with small rounded badges
2026-10-27 06:32:03 +08:00
7f31453723 fix: startNewChat now always creates new session
- Changed startNewChat to async and always create a new session
- No longer depends on currentSession existing
2026-10-27 06:17:35 +08:00
06217bc314 fix: improve session initialization flow
- Fixed onMounted to properly set currentSession after creating default
- Ensure loadSessions is called after createSession to refresh list
2026-10-27 06:16:17 +08:00
433b5dc797 fix: ensure currentSession is set before saving messages
- Added check to set currentSession from sessionList if null
- This ensures messages are always saved to a session
2026-10-27 06:14:28 +08:00
f5dd8577b2 fix: improve session initialization and save logic
- Fixed onMounted to properly set currentSession after creating default
- startNewChat now creates a new session when called
- Ensure authToken before all session API calls
2026-10-27 06:11:28 +08:00
ac281b0766 fix: startNewChat now creates new session
- Updated startNewChat to call handleNewSession if currentSession exists
- This ensures + New button also creates a new session in MarkBase
2026-10-27 05:41:54 +08:00
bd52128031 fix: auto-login with demo credentials for session API
- Added ensureAuthToken() function that auto-logs in with demo/demo123
- All session API functions now call ensureAuthToken() first
- Fixes 'Missing Authorization header' errors
- Sessions now save correctly without manual admin login
2026-10-27 05:36:16 +08:00
fe91afff98 feat: integrate MarkBase Search Session API into Studio
- Created useSearchSession composable for session management
- Added 7 API endpoints in api/index.ts
- Updated SearchView.vue to use sessions instead of history
- Session sidebar with create, rename, delete functionality
- Auto-save messages to current session after each search
- Auto-create default session on first load
- Updated CSS for session active state and new session button
2026-10-27 05:06:03 +08:00
86d90f4f53 fix: remove scene thumbnail_url from all VLM search result mappings
- Removed thumbnail_url from VLM scene results (lines 901, 1312)
- Scene thumbnail files often don't exist for unprocessed videos
- Frontend now falls back to regular thumbnail loading mechanism
- Eliminates 404 errors in browser console
2026-10-27 03:31:11 +08:00
1afdb52373 fix: remove scene thumbnail URL from VLM search results
- Scene thumbnails often don't exist for unprocessed files
- Use regular thumbnail fallback instead of scene-specific URLs
- Eliminates 404 errors in browser console for scene_*.jpg requests
2026-10-27 03:28:37 +08:00
49e23c39f3 fix: hide broken scene thumbnail images with @error handler
- Scene thumbnails may not exist for all files
- Added @error handler to hide broken images instead of showing 404
- Cleaner UI when scene data is incomplete
2026-10-27 03:21:39 +08:00
712b5a6527 fix: remove debug console.error from ensureFiles
- Removed '[ensureFiles] starting' console.error
- Not an actual error, just debug log
- Follows 'no dev residue' guideline
2026-10-27 03:16:02 +08:00
8b5d5cfd0d fix: remove loadMbeModels call from onMounted
- /api/v2/mbe/models endpoint doesn't exist on MarkBase
- Removing the call eliminates the 404 error on page load
- MBE model selector dropdown will remain empty but functional
2026-10-27 03:09:44 +08:00
3d630afc4e fix: auto-create config directory when saving admin config
- save_admin_config_handler now creates parent directory if it doesn't exist
- Prevents 500 error when config/ directory is missing
- Enables first-time config save without manual directory creation
2026-10-27 03:07:12 +08:00
1f885406dd fix: allow saving admin config when config file doesn't exist
- saveConfig no longer throws error when current config returns 404
- Creates new config file with current values if none exists
- User can save config for the first time without errors
2026-10-27 02:40:45 +08:00
776cf197c8 fix: handle 404 gracefully for admin config endpoint
- loadConfig now uses default values when config file doesn't exist (404)
- No error shown to user when config file is missing
- Config tab loads with empty defaults instead of error message
2026-10-27 02:37:30 +08:00
969b4d85ef fix: suppress 404 errors for optional MBE models endpoint and defer user loading
- loadMbeModels no longer logs console.error for 404 (endpoint may not exist)
- loadUsers removed from onMounted - only called after admin login
- Prevents 401 errors on page load before user has authenticated
- Users tab now only loads data after successful login
2026-10-27 02:32:54 +08:00
1caca73614 feat: integrate settings validation API before saving upload path
- saveUploadPath now validates path via POST /api/v2/settings/validate
- Shows clear error message if path doesn't exist or isn't writable
- Only saves if validation passes (valid: true)
- 5 validation checks: format, existence, type, read/write permissions
2026-10-27 02:28:49 +08:00
3b638f0416 feat: integrate MarkBase Admin API with Bearer token authentication
- Added useAdminAuth composable for login/logout/token management
- Admin Users tab now requires login before showing users
- loadUsers/loadShares now use direct fetch with Bearer token
- Added login form with username/password fields
- Token stored in localStorage with expiry check
- Default credentials: demo/demo123
2026-10-27 02:17:41 +08:00
4129c174ed feat: integrate MarkBase Settings API (GET/POST /api/v2/settings)
- Replaced deprecated /api/v2/config with new /api/v2/settings
- loadSettings() now uses GET /api/v2/settings (structured JSON)
- saveUploadPath() now uses POST /api/v2/settings
- Removed PostgreSQL migration error handling (no longer needed)
- Settings page now works correctly with SQLite-only MarkBase
2026-10-27 02:06:57 +08:00
59bcd9a9b5 docs: add MarkBase API requirements for Studio integration
- Created MARKBASE_API_REQUIREMENTS.md with detailed API specs
- Requests GET/POST /api/v2/settings endpoints from MarkBase team
- Documents current issues with /api/v2/config returning 500
- Defines required fields, error handling, and priority levels
2026-10-27 01:45:44 +08:00
cb2b6a0292 fix: show clear error message when MarkBase needs restart (PostgreSQL→SQLite migration)
- Detects 'missing field postgresql' error from MarkBase config endpoint
- Shows user-friendly message: 'MarkBase needs restart (PostgreSQL→SQLite migration)'
- Helps users understand the error is due to outdated MarkBase instance
2026-10-27 01:41:07 +08:00
052178b084 fix: improve Settings page error message for MarkBase config failures
- loadSettings now shows detailed error from MarkBase response body
- MarkBase /api/v2/config returns 500 when config file is incomplete
- Error message now includes actual error details instead of just HTTP status
2026-10-27 01:27:34 +08:00
388c548e4a feat: multi-language support for agent search and admin pipeline config
- search_agents now accepts output_language parameter (en/zh-TW/ja)
- Admin Settings: added Pipeline Configuration section (enabled, max_concurrent_stages, default_timeout_secs)
- Admin Settings: search config now includes vlm_output_language dropdown
- Added translations for pipeline config in en/zh-TW/ja locales
- Agent search uses searchConfig.vlm_output_language for output language
2026-10-27 01:18:19 +08:00
716d3954e7 fix: proxy forwards mbe health to Core API instead of direct llama-server access
- Previously proxy accessed llama-server /health endpoint directly
- Now forwards /api/v1/mbe/health to Core API (3002) which has full health check
- Returns complete health info: status, model, uptime
- Fixes frontend not showing 'online' status in Admin Settings
2026-10-24 12:25:01 +08:00
b1978fabc5 fix: add /health proxy rule to Vite config
- Vite now forwards /health to Rust proxy (port 8888)
- Required for Admin Panel proxy health check to work in dev mode
- External Caddy reverse proxy may also need /health forwarding rule
2026-10-23 21:36:57 +08:00
fa7a9e1084 fix: Admin Panel health checks work via reverse proxy
- loadServiceUrls: use window.location.origin for remote access, localhost for local dev
- testCoreApi: use /api/v1/health for remote, /health for localhost
- testProxy: health check path works for both
- testMbe: already uses getApiBase() which handles both cases

This fixes the issue where Admin Panel showed offline when accessed via
https://nextorage.momentry.ddns.net because localhost health checks
point to user's machine, not the server.
2026-10-23 21:35:29 +08:00
88867e80e5 fix: handle 404 for scenes endpoint gracefully
- Scenes endpoint may not be implemented in Core API yet
- useVLMScenes returns empty array instead of error on 404
2026-10-23 20:22:48 +08:00
e2612dde72 feat: add VLM composables for Vue 3 integration
- useVLMScenes(fileUuid): load scenes for a specific file with thumbnails
- useVLMSearch(): search VLM scenes and traces with bilingual support
- useSceneThumbnail(fileUuid, sceneIndex): load scene thumbnail URLs
- TypeScript interfaces: VLMTag, VLMScene, VLMTrace, FileScene
- Uses direct HTTP calls via getApiBase() (no Tauri IPC needed)
- Follows Vue 3 composable best practices (ref, loading, error states)
2026-10-23 20:21:00 +08:00
6db184c7d0 feat: export marked results with VLM data and tags
- toggleMark now captures vlm_description, vlm_description_localized, vlm_tags, vlm_objects, thumbnail_url
- exportMarked generates structured JSON with vlm section containing en/localized descriptions and tags
- Export filename changed to vlm-marked-export-{timestamp}.json
- Includes source_type, scene_index, trace_id for complete result metadata
2026-10-23 18:15:38 +08:00
fa8e4a9191 fix: simplify bilingual VLM search - use single API call
- Core API now returns both vlm_description (EN) and vlm_description_localized (JA)
- Removed duplicate API calls (was fetching EN + JA separately)
- Single API call with output_language param, uses both fields from response
- Load More also updated to use results array and correct field names
- Format: 【JA】localized text...【English】english text...
2026-10-23 04:59:55 +08:00
76d9afd43b fix: use vlm_description_localized field name from Core API
- Changed vlm_description_lang to vlm_description_localized
- Core API outputs vlm_description (EN) + vlm_description_localized (JA)
- Frontend shows localized first: 【JA】...【English】...
2026-10-23 04:56:56 +08:00
1ffceaba26 fix: search visual cards show localized language first (JA before EN)
- Bilingual format: 【JA】... then 【English】...
- Summary uses localized language (vlm_description_lang) as primary
- Load More function now also supports bilingual format
- Fallback: only vlm_description shows single language without labels
2026-10-23 04:41:15 +08:00
342d4e33b8 fix: Admin panel always uses localhost URLs for service health checks
- Removed isLocalhost checks from loadServiceUrls()
- All services now default to http://localhost:XXXX
- Health check URLs always use direct paths (/health)
- Fixes Core API and Proxy showing offline from external URL
2026-10-23 02:22:28 +08:00
6e0e306082 fix: optimize MBE start flow - skip redundant frontend polling
- Backend already polls 60s for MBE port readiness
- Frontend no longer polls 30s after backend returns
- Total wait time: ~60s instead of ~90s
- Start timeout set to 60s for MBE
2026-10-23 01:31:50 +08:00
c21c186e0c fix: increase start_service timeout for MBE to 60s
- MBE needs up to 60s to load model
- Default timeout (30s) was too short causing timeout errors
2026-10-23 01:22:44 +08:00
50bd33106f fix: MBE health check proxy and admin page
- Added /api/v1/mbe/health proxy endpoint
- Frontend uses proxy for MBE health check (works on localhost and external)
- Accepts 'healthy' status from MBE response
- Shows model info (MBE e4b) in Admin UI
2026-10-23 00:33:31 +08:00
951a2964f3 feat: add MBE health check proxy endpoint
- Added /api/v1/mbe/health proxy in Studio proxy (port 8888)
- Frontend now uses proxy endpoint instead of direct mbeUrl
- Works for both localhost and external access (once proxy is deployed)
- MBE health response: {status: 'healthy', model: 'e4b', layers: 42}
2026-10-22 23:52:23 +08:00
a429aca344 fix: accept MBE 'healthy' status and show model info
- Updated testMbe() to accept status='healthy' from MarkBaseServer
- Added model and layers info to mbeInfo display
- MBE now shows 'MBE (e4b)' instead of generic 'MarkBaseEngine'
2026-10-22 21:55:52 +08:00
2cff332d55 feat: fix MBE health check and add model selection dropdown
- Fixed testMbe() to always use /health instead of /v1/health
- Added model selection dropdown for MarkBaseEngine
- Modified startService('mbe') to pass model and port parameters
- Added loadMbeModels() to fetch available models on mount
- Added getApiBase import
2026-10-22 21:40:47 +08:00
38260a4c61 fix: full file playback resets all state to play to end of file
- Clear all marks (not just face marks)
- Reset playMode to 'continuous' to disable trace/segment limits
- Reset currentTraceIdx and currentSegmentIdx to 0
- Reset seekFrame to 0
- This ensures full file plays from start to end without restrictions
2026-10-21 01:47:20 +08:00
3b2c7c65ae feat: clickable file name in video player for full file playback
- File name in header is now clickable
- Click reloads video with full file range (startFrame=0, endFrame=999999)
- Added play icon and hover effect for visual feedback
2026-10-21 01:32:23 +08:00
fc32fb0f86 fix: full file playback and file name display
- Use endFrame=999999 for full file playback (backend clips correctly)
- Add z-index:10 to card-file-info to prevent being obscured
- Full file now plays complete duration
2026-10-20 22:26:38 +08:00
971cfe50f5 feat: add clickable file name bar with full-file playback
- Add card-file-info bar at top of search result cards
- Click file name to play full file (startFrame: 0, endFrame: 0)
- Show video/document icon based on file extension
- Display file UUID badge
- Remove duplicate card-file section from bottom of card
2026-10-20 22:01:53 +08:00
c425c29d01 feat: persist search session across page navigation
- Save messages to localStorage when leaving search page
- Restore messages when returning to search page
- Clear session on newChat()
- Session includes: messages, conversationId, fileUuidCache, mode
2026-10-20 18:06:52 +08:00
55c39e7732 feat: keep only last 2 hours of search history
- Filter history to show only items from last 2 hours
- Pinned items are always kept regardless of age
- Auto-cleanup old unpinned items from database
- Increased fetch limit to 50 to ensure enough items for filtering
2026-10-20 17:57:27 +08:00
a75250ed17 fix: recover corrupted search_history SQLite database
- Database was corrupted (WAL file had uncommitted data)
- Recovered 101 search history records from WAL
- Cleaned up test data with empty ID
- Proxy now returns 30 records correctly
2026-10-20 17:49:55 +08:00
ca569f3e5c fix: re-scan now shows status update immediately
Root cause: finally block called loadFiles() which cleared the cache
and reloaded from server, overwriting the manual 'scanning' status.
Server videos.status may not be synced yet by PostgreSQL trigger.

Fix: Remove loadFiles() from finally block. Keep manual status update.
Polling mechanism will sync status from server automatically.
2026-10-18 23:43:45 +08:00
7f6db1a387 debug: add console.log to re-scan flow
- Added logging to ctxReprocess, doReprocess
- Log API call and response for debugging
- Check if reprocessing flag is blocking the action
2026-10-18 23:21:28 +08:00
5e0eac6700 fix: allow re-scan for paused files
- Added Rescan button for paused files in context menu
- Re-scan now removes file from paused set
- Paused files can be re-scanned directly without resuming first
2026-10-18 23:13:44 +08:00