Commit graph

507 commits

Author SHA1 Message Date
yangdx
fca3ea5d20 Fix linting 2025-09-22 03:29:17 +08:00
yangdx
8af097a8e4 fix(webui): resolve theme switching crashes and optimize graph rendering
- Implement theme switching isolation to prevent component access during transitions by hidding GraphSearch
- Fix NotFoundGraphError during theme switching by adding defensive programming
- Replace problematic NodeById component with custom safe implementation
- Add comprehensive error handling and node/edge existence checks
- Optimize sigma settings with memoization to prevent unnecessary re-renders
- Remove redundant theme update logic and simplify event listener management
2025-09-22 03:03:53 +08:00
yangdx
d2029fd804 Replace Input with auto-resizing Textarea in RetrievalTesting
• Add new Textarea component
• Auto-resize between 40px-120px height
• Support Enter to submit, Shift+Enter for newline
• Add form autocomplete attributes
• Reset height after message submission
2025-09-22 02:01:39 +08:00
yangdx
17dd56e41c Improve code highlighting with context-aware styling and inline detection
• Add messageRole prop to CodeHighlight
• Remove unused Element type import
• Replace node-based inline detection
• Add theme-aware inline code styles
• Update dependency arrays in useMemo
2025-09-22 01:41:58 +08:00
yangdx
9288ae1703 Refactor COT parsing to handle multiple think blocks robustly 2025-09-22 01:01:39 +08:00
yangdx
62aa0726a5 Fix conversation history handling when history_turns is 0
• Check history_turns > 0 before filtering
• Prevent sending all history converstion to backend when history_turns is 0
2025-09-21 23:51:19 +08:00
yangdx
1d65fed692 Update graph search and label tooltips for clarity across all locales 2025-09-21 01:18:37 +08:00
yangdx
afb2df93f4 Update graph labels terminology from "labels" to "nodes" across locales 2025-09-21 00:31:17 +08:00
yangdx
68883c0e7a Fix legend translation keys by removing spaces from node types 2025-09-20 23:27:34 +08:00
yangdx
446767ba50 feat: enhance graph refresh with dynamic tooltips and loading states
• Add refresh loading state with spinner
• Dynamic tooltips based on current label
• Improved refresh logic for labels
• Force dropdown re-render on refresh
• Update i18n for new tooltip messages
2025-09-20 22:46:09 +08:00
yangdx
55b4716bac fix(webui): resolve cmdk filtering issue preventing search history display
- Fix AsyncSelect component where cmdk's internal filtering was hiding search history items
- Change CommandItem value logic: use empty string when searchTerm is empty to match cmdk's filtering behavior
- Ensure search history displays correctly on initial load regardless of current queryLabel value
- Maintain proper selected state indication and all existing functionality
- Preserve normal search behavior when user types in search input

Fixes issue where dropdown only showed "*" and current queryLabel instead of full search history from localStorage.
2025-09-20 14:35:41 +08:00
yangdx
da30529585 Change AsyncSelect to load search history on initial mount
- Use empty query for initial load
- Remove value dependency from effect
- Always show search history first
- Simplify initialization logic
2025-09-20 14:17:08 +08:00
yangdx
9db8f2fce5 feat: Add popular labels and search APIs with history management
- Add popular/search label endpoints
- Implement SearchHistoryManager utility
- Replace client-side with server search
- Add graph data version tracking
- Update UI for better label discovery
2025-09-20 02:03:47 +08:00
Saravana Kumar S
f9b69ac54a
Update QuerySettings.tsx 2025-09-17 13:07:55 +05:30
yangdx
13681a185f Fix tooltip text wrapping to preserve word boundaries
• Change break-all to break-word
• Add overflow-wrap: break-word
• Apply to tooltip and pre elements
2025-09-17 02:04:43 +08:00
yangdx
983fe31af5 Bump API version and improve tooltip text wrapping in DocumentManager
- Update API version to 0224
- Add word-break: break-all to tooltip
- Improve pre tag text wrapping
- Enhance tooltip readability
2025-09-17 01:47:40 +08:00
yangdx
659f2d5944 Merge branch 'fix-webui-error-handle' into fix/dark-mode-graph-text-colors 2025-09-16 17:32:22 +08:00
yangdx
139ec869e8 Extract light theme label color to constant for consistency 2025-09-16 17:31:56 +08:00
yangdx
ecdd8f17eb feat: add robust error handling and resilience to DocumentManager
• Circuit breaker pattern for failures
• Exponential backoff retry logic
• Request timeout wrapper
• Enhanced error classification
2025-09-16 17:14:10 +08:00
Roman Marchuk
20402f515f fix: resolve dark mode text visibility issue in knowledge graph view
- Replace hardcoded black text colors (#000) with dynamic theme-based colors
- Add createSigmaSettings function to generate settings based on theme
- Use labelColorDarkTheme (#B2EBF2) for dark mode and black (#000) for light mode
- Update GraphViewer component to react to theme changes
- Fixes issue where node and edge labels were invisible in dark mode

Fixes: Dark mode text visibility in knowledge graph visualization
2025-09-15 23:24:26 -04:00
yangdx
5311083f43 Rename "Process" entity type to "Method" across all components 2025-09-14 02:30:05 +08:00
yangdx
7060cf17f0 Add Process and Data entity types to LLM extraction system
• Add Process and Data to default types
• Update env.example configuration
• Add translations for new entities
• Support 5 languages (en/zh/fr/ar/tw)
2025-09-14 01:14:47 +08:00
yangdx
f1d6d949f1 Fix assistant message display content fallback logic
- Handle undefined vs empty string cases
- Prevent COT content keep rendering before </think> tag recieved
2025-09-09 11:39:59 +08:00
yangdx
3912b7d281 Fix assistant message display with content fallback
• Add content fallback for compatibility
• Update comment for clarity
• Prevent empty assistant messages
2025-09-08 23:35:31 +08:00
yangdx
8ad7109313 Fix linting 2025-09-08 20:11:21 +08:00
yangdx
4346846e5a Fix thinking content extraction to prevent duplication and overwriting
- Add thinkingProcessed ref to track state
- Extract thinking content only once
- Preserve real-time thinking updates
- Reset processed flag on new queries
- Always update display content stream
2025-09-08 19:34:05 +08:00
yangdx
eeff0d5c67 Fix thinking state management and UI improvements for chat messages
- Reset expansion state on new thinking
- Prevent content leakage during thinking
- Update thinkingTime type to allow null
- Add memory leak prevention cleanup
- Add missing i18n translations
2025-09-08 18:47:41 +08:00
yangdx
2ba10dbb5b Add AI thinking process display with expandable UI and timing
- Add thinking fields to Message type
- Create expandable thinking section
- Track thinking time during streaming
2025-09-08 18:09:04 +08:00
yangdx
e4dd83ee3d Change tooltips font to a smaller one 2025-09-05 22:14:28 +08:00
yangdx
1be7c53fcc Enhance document status display with metadata tooltips and better icons
- Add metadata formatting with timestamps
- Replace warning emoji with proper icons
- Show tooltips for errors and metadata
- Import AlertTriangle and Info icons
- Improve status cell layout and styling
2025-09-05 22:02:26 +08:00
yangdx
5a5d5e4a34 Add document translation key to all locale files 2025-09-03 12:50:27 +08:00
yangdx
4db43c43f3 Add product and other entity type translations
- Add "product" translations
- Add "other" translations
- Update 5 locale files
- Extend entity type coverage
2025-09-02 03:01:59 +08:00
yangdx
25b5d176cd Fix label selection with leading/trailing whitespace
• Fix AsyncSelect value trimming issue
• Preserve whitespace in label display
• Use safe keys for command items
• Add GraphControl dependency fix
• Add debug logging for graph labels
2025-08-31 02:54:39 +08:00
yangdx
7db788aa66 fix(webui): resolve document status grouping issue in DocumentManager
- Fix documents being grouped by status after pagination and sorting
- Use backend-sorted data directly from currentPageDocs instead of re-grouping
- Preserve backend sort order to prevent status-based grouping
- Maintain backward compatibility with legacy docs structure
- Ensure all sorting fields (file name, dates, ID) work correctly without status grouping

The issue occurred because the frontend was re-grouping already-sorted data
from the backend by status, breaking the intended sort order. Now documents
are displayed in the exact order returned by the backend API.

Fixes: Document list sorting by file name was grouping by status instead of
maintaining proper sort order across all documents.
2025-08-26 23:03:41 +08:00
yangdx
de2daf6565 refac: Rename summary_max_tokens to summary_context_size, comprehensive parameter validation for summary configuration
- Update algorithm logic in operate.py for better token management
- Fix health endpoint to use correct parameter names
2025-08-26 01:35:50 +08:00
yangdx
47485b130d refac(ui): Show rerank binding info on status card
- Remove separate ENABLE_RERANK flag in favor of rerank_binding="null"
- Change default rerank binding from "cohere" to "null" (disabled)
- Update UI to display both rerank binding and model information
2025-08-23 02:04:14 +08:00
yangdx
ec1bf43667 fix(webui): preserve current page when pipeline status changes
- Add intelligent refresh function to handle boundary cases
- Replace manual refresh with smart page preservation logic
- Auto-redirect to last page when current page becomes invalid
- Maintain user's browsing position during pipeline start/stop
- Fix issue where document list would reset to first page after pipeline operations
2025-08-21 22:53:24 +08:00
yangdx
1f86543772 Update i18n translation and webui assets 2025-08-19 16:23:05 +08:00
yangdx
c6b30f1a03 Fix file type mappings for proper MIME type handling 2025-08-19 15:26:21 +08:00
yangdx
e38df464ea Ensure front-end file type uploads are synchronized with back-end 2025-08-19 15:10:13 +08:00
yangdx
d5e8f1e860 Update default query parameters for better performance
- Increase chunk_top_k from 10 to 20
- Reduce max_entity_tokens to 6000
- Reduce max_relation_tokens to 8000
- Update web UI default values
- Fix max_total_tokens to 30000
2025-08-18 19:32:11 +08:00
yangdx
1af0803c62 fix(ui): fix selection state management in paginated views
- Replace DeselectDocumentsDialog with smart selection button
- Auto-reset selection on page/filter changes
- Remove deletion restrictions and update i18n
2025-08-17 10:38:12 +08:00
yangdx
bd8ed905e8 Translate Chinese comments to English in ClearDocumentsDialog 2025-08-17 01:53:37 +08:00
yangdx
e566267a20 Implement smart polling recovery after document scan completion
• Add 15-second recovery timer
• Restore intelligent intervals
2025-08-17 01:51:11 +08:00
yangdx
e064534941 feat(ui): enhance ClearDocumentsDialog with loading spinner and timeout protection
- Add loading spinner animation during document clearing operation
- Implement 30-second timeout protection to prevent hanging operations
- Disable all interactive controls during clearing to prevent duplicate requests
- Add comprehensive error handling with automatic state reset
2025-08-17 01:33:39 +08:00
yangdx
6969038fd5 Update mermaid version to 11.9.0 2025-08-14 05:02:53 +08:00
yangdx
c22315ea6d refactor: remove selective LLM cache clearing functionality
- Remove optional 'modes' parameter from aclear_cache() and clear_cache() methods
- Replace deprecated drop_cache_by_modes() with drop() method for complete cache clearing
- Update API endpoint to ignore mode-specific parameters and clear all cache
- Simplify frontend clearCache() function to send empty request body

This change ensures all LLM cache is cleared together.
2025-08-05 23:51:51 +08:00
yangdx
317d233486 Improve select dropdown styling in query settings 2025-07-31 23:52:44 +08:00
yangdx
a59f8e7ceb Add reset buttons to query settings controls
- Add reset functionality for all settings
- Include default values for each setting
2025-07-31 12:29:26 +08:00
yangdx
755a08edec Remove History Turns config option and force value to 0
- Remove History Turns UI component from QuerySettings
- Update settings store version to 17 with migration
- Force history_turns parameter to always be 0 in queries
- Prevent future modifications to history_turns setting
2025-07-31 11:22:48 +08:00