Use TypeScript discriminated union types to prevent using both `create` and `import`
options simultaneously in ProviderExtensionConfig at compile time. This replaces runtime
validation with type-level enforcement.
Changes:
- Split ProviderExtensionConfig into a union of ProviderExtensionConfigWithCreate and ProviderExtensionConfigWithImport
- Extract shared properties into ProviderExtensionConfigBase
- Remove runtime validation checks that are now handled by the type system
- Clean up unused import in HubProvider.test.ts
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Remove unused `export type * from './branded'` line since branded.ts was already deleted
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Remove packages/aiCore/src/core/types/branded.ts (ModelId, ProviderId, RequestId types were not used anywhere)
- Update packages/aiCore/src/index.ts to remove branded type exports
All tests passing (164/165 test files, 2933/2934 tests)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Add missing jsonSchema export to ai mock in HubProvider and RegistryManagement tests
- Add missing generateImage and jsonSchema exports to ai mock in generateImage test
- Fix totalTokens calculation in convertClaudeCodeUsage (inputTokens + outputTokens)
- Update usage assertions in transform tests to use toMatchObject instead of toEqual
All tests now passing (165 test files, 2934 tests passed)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* fix(ovms): make ovms manager windows-only and lazy load it
Add platform check in OvmsManager constructor to throw error on non-Windows platforms
Lazy load ovmsManager instance and handle IPC registration only on Windows
Update will-quit handler to conditionally cleanup ovms resources
* feat(preload): add windows-only OVMS API and improve type safety
Extract OVMS API methods into a separate windowsOnlyApi object for better organization
Add explicit return type for getDeviceType method
* feat(system): add system utils and refine ovms support check
- Add new system utility functions for device type, hostname and CPU name
- Refactor OVMS support check to require both Windows and Intel CPU
- Update IPC handlers to use new system utils and provide proper OVMS fallbacks
* Revert "feat(preload): add windows-only OVMS API and improve type safety"
This reverts commit d7c5c2b9a4.
* feat(ovms): add support check for ovms provider
Add new IPC channel and handler to check if OVMS is supported on the current system. This replaces the previous device type and CPU name checks with a more maintainable solution.
* fix(OvmsManager): improve intel cpu check for ovms manager
Move isOvmsSupported check before class definition and update error message to reflect intel cpu requirement
* fix: use isOvmsSupported flag for ovms cleanup check
Replace platform check with feature flag to properly determine if ovms cleanup should run
* fix: improve warning message for undefined ovmsManager
* fix(system): handle edge cases in getCpuName function
Add error handling and null checks to prevent crashes when CPU information is unavailable
* feat(runtime): add ovms support check during app init
Add isOvmsSupported state to runtime store and check support status during app initialization. Move ovms support check from ProviderList component to useAppInit hook for centralized management.
* feat: add fuzzy search for file list with relevance scoring
- Add fuzzy option to DirectoryListOptions (default: true)
- Implement isFuzzyMatch for subsequence matching
- Add getFuzzyMatchScore for relevance-based sorting
- Remove searchByContent method (content-based search)
- Increase maxDepth to 10 and maxEntries to 20
* perf: optimize fuzzy search with ripgrep glob pre-filtering
- Add queryToGlobPattern to convert query to glob pattern
- Use ripgrep --iglob for initial filtering instead of loading all files
- Reduces memory footprint and improves performance for large directories
* feat: add greedy substring match fallback for fuzzy search
- Add isGreedySubstringMatch for flexible matching
- Fallback to greedy match when glob pre-filter returns empty
- Allows 'updatercontroller' to match 'updateController.ts'
* fix: improve greedy substring match algorithm
- Search from longest to shortest substring for better matching
- Fix issue where 'updatercontroller' couldn't match 'updateController'
* docs: add fuzzy search documentation (en/zh)
* refactor: extract MAX_ENTRIES_PER_SEARCH constant
* refactor: use logarithmic scaling for path length penalty
- Replace linear penalty (0.8 * length) with logarithmic scaling
- Prevents long paths from dominating the score
- Add PATH_LENGTH_PENALTY_FACTOR constant with explanation
* refactor: extract scoring constants with documentation
- Add named constants for scoring factors (SCORE_SEGMENT_MATCH, etc.)
- Update en/zh documentation with scoring strategy explanation
* refactor: move PATH_LENGTH_PENALTY_FACTOR to class level constant
* refactor: extract buildRipgrepBaseArgs helper method
- Reduce code duplication for ripgrep argument building
- Consolidate directory exclusion patterns and depth handling
* refactor: rename MAX_ENTRIES_PER_SEARCH to MAX_SEARCH_RESULTS
* fix: escape ! character in glob pattern for negation support
* fix: avoid duplicate scoring for filename starts and contains
* docs: clarify fuzzy search filtering and scoring strategies
* fix: limit word boundary bonus to single match
* fix: add dedicated scoring for greedy substring match
- Add getGreedyMatchScore function that rewards fewer fragments and tighter matches
- Add isFuzzyMatch validation before scoring in fuzzy glob path
- Use greedy scoring for fallback path to properly rank longest matches first
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
---------
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* feat(tokenflux): add Anthropic host support using OpenRouter package
- Add anthropicApiHost to TokenFlux provider config
- Map TokenFlux to OpenRouter in STATIC_PROVIDER_MAPPING for full compatibility
* feat(tokenflux): update API URLs and add migration
- Update apiHost to https://api.tokenflux.ai/openai/v1
- Update anthropicApiHost to https://api.tokenflux.ai/anthropic
- Add migration 191 to update existing TokenFlux users
* fix(tokenflux): add to Anthropic compatible providers list
Enable Anthropic API host configuration in TokenFlux provider settings UI
- Implement tests for plugin registration, management, and lifecycle
- Validate plugin execution order and context management
- Test model resolution, parameter transformation, and result transformation
- Ensure error handling and recursive call support
- Cover streaming execution and image model handling
- Verify type safety for plugin parameters
- Deleted README.md for AiSdkMiddlewareBuilder as it was outdated.
- Removed toolChoiceMiddleware.ts as it is no longer needed.
- Introduced new plugins:
- noThinkPlugin: Appends '/no_think' to user messages to prevent unnecessary thinking.
- openrouterGenerateImagePlugin: Configures OpenRouter for image and text modalities.
- openrouterReasoningPlugin: Redacts reasoning blocks in OpenRouter responses.
- qwenThinkingPlugin: Controls thinking mode for Qwen models based on provider support.
- reasoningExtractionPlugin: Extracts reasoning tags from OpenAI/Azure responses.
- simulateStreamingPlugin: Converts non-streaming responses to streaming format.
- skipGeminiThoughtSignaturePlugin: Skips Gemini3 thought signatures for multi-model requests.
- Updated parameterBuilder.ts to correct type definitions.
- Added middlewareConfig.ts for better middleware configuration management.
- Enhanced reasoning utility functions for better tag name retrieval.
- Updated ApiService.ts and aiCoreTypes.ts for consistency with new changes.