Commit Graph

161 Commits

Author SHA1 Message Date
cogwheel0
dcca839e35 feat(chat): Improve text color and segment spacing in UI components 2025-12-07 23:47:40 +05:30
cogwheel0
03c2b030e1 feat(chat): Simplify tool call tile with minimal design 2025-12-07 23:33:26 +05:30
cogwheel0
e9de32fbec refactor(chat): Replace StatusHistoryTimeline with StreamingStatusWidget 2025-12-07 23:19:22 +05:30
cogwheel0
12c10ab0b7 feat(sources): Simplify source display text logic for URLs 2025-12-07 22:38:00 +05:30
cogwheel0
6e4ee2acd3 feat(widget): Add citation badge for source references 2025-12-07 22:35:16 +05:30
cogwheel0
898f1773c7 feat(chat): Add prompt variables 2025-12-07 10:48:25 +05:30
cogwheel0
b387b64e4e refactor: Remove deprecated code and unused comments 2025-12-06 06:45:57 +05:30
cogwheel0
c9b888df79 fix(navigation): Ensure context is mounted before navigation and improve error handling 2025-12-05 22:24:36 +05:30
cogwheel
a5c7bbe2f2 Merge pull request #224 from cogwheel0/add-model-filters-support
feat(models): Add filters support and auto-validation for model-specific filters
2025-12-05 22:20:47 +05:30
cogwheel0
c630ce8c27 feat(models): Add filters support and auto-validation for model-specific filters 2025-12-05 22:19:31 +05:30
cogwheel0
e3b47ecf87 feat(chat): Improve keyboard shortcuts and accessibility in chat input 2025-12-05 18:23:00 +05:30
cogwheel0
6b1ecff302 feat(reasoning): Add html_unescape and enhance reasoning parser 2025-12-04 15:05:20 +05:30
cogwheel0
0daf840a03 feat(chat): Improve chat input semantics and keyboard interactions 2025-12-03 15:04:53 +05:30
cogwheel0
ecad71dcf6 feat(chat): Add clipboard image paste support in chat input 2025-12-02 21:11:08 +05:30
cogwheel0
c156b0f6d9 feat(chat): Enhance tag balancing for details, think, and reasoning tags 2025-12-01 10:04:57 +05:30
cogwheel0
3f34140873 feat(chat): sanitize content to handle malformed details tags 2025-11-29 13:05:49 +05:30
cogwheel0
aefd4dfa2c feat(chat): add support for custom HTTP headers in image attachments 2025-11-29 11:04:59 +05:30
cogwheel0
4c5f12919f feat(chat): Add SVG image support for attachments 2025-11-29 11:04:59 +05:30
cogwheel0
98ae65d08f feat(ui): Improve text overflow and spacing in chat drawer 2025-11-28 14:59:38 +05:30
cogwheel0
de18f1463c feat(chat): Add keys to composer widgets for improved testing 2025-11-27 20:14:30 +05:30
cogwheel0
75ba0dc01d feat(chat): Add context attachment and knowledge base support 2025-11-26 22:19:19 +05:30
cogwheel0
a05837b985 refactor(streaming): Optimize image collection and debounce mechanism 2025-11-02 22:14:45 +05:30
cogwheel0
86339715b1 feat(sts): add server side speech-to-text 2025-11-02 19:03:36 +05:30
cogwheel0
8321e3c721 feat(l10n): Update English localization with voice call states and model capabilities 2025-11-02 17:44:23 +05:30
cogwheel0
71d63ac157 refactor(network): Replace read with watch for providers in image handling 2025-11-01 15:42:08 +05:30
cogwheel0
ada6d40e5e feat(chat): Add worker manager to streaming helper for image processing 2025-11-01 00:57:40 +05:30
cogwheel0
5d33e5fe65 fix: server side tts on ios 2025-10-31 23:20:04 +05:30
cogwheel0
cf87d255d3 feat(settings): Allow unlimited quick pill selections 2025-10-30 22:44:08 +05:30
cogwheel0
15299ecd82 feat(chat): dismiss after send to recover screen space 2025-10-24 00:39:43 +05:30
cogwheel0
9c2cf347a7 feat(chat): inline action panel with context menu edit flow 2025-10-24 00:31:29 +05:30
cogwheel0
5d898aaca0 refactor: improve composer layout and constrain height
the modern chat input composer layout to better handle vertical
space and alignment. Change the row crossAxisAlignment from
center to end so controls align to the input bottom. Wrap the animated
container with a ConstrainedBox that limits the composer max height to
25% of the screen, preventing excessive growth on tall displays.

Reorder and clean up the AnimatedContainer/decoration block, extracting
the composer radius constant and preserving styling (background color,
border color/width). Move the text field and inline mic into the same
row structure under the constrained container and retain the isActive
flag and padding. These changes prevent layout overflow, ensure a
consistent border radius, and improve visual alignment of controls.
2025-10-23 23:19:41 +05:30
cogwheel0
be62358270 feat(chat): strip reasoning when copying
Remove internal reasoning from copied message text to avoidleaking implementation details or developer-only when a
user content from the chat- In chat_pagecopyMessage, cleaning steps to:
  - <details type="ing">...</details blocks
  - <think>think> and <ing>...</reason> tags
 - trim leftover whitespace before writing to the clipboard
- In assistant_message_widget._buildSegmentedContent, remove an
  unused hasMediaAbove calculation and a conditional spacer that added
  extra top padding before reasoning tiles. This simplifies rendering
  logic and avoids relying on removed spacing behavior.
2025-10-23 22:37:06 +05:30
cogwheel0
1cb8926e21 feat(chat): regenerate variants and support
Hide archived assistant variants in the linear chat view and track
previous assistant as versions so regenerated responses do not
duplicate or lose history. When regenerating, mark the previous assistant
message with an archivedVariant flag for the UI and keep it in server
history. Add a ChatMessageVersion model and a versions field to
ChatMessage to store prior generated variants. Implement
archiveLastAssistantAsVersion in chat providers to snapshot the last
assistant message into versions and reset the message for a fresh
streamed generation. Finalize flow updates to attach an adjacent archived
assistant as a version when needed so the UI can present a switcher
between current and past variants. These changes prevent duplicate
messages, preserve previous responses, and enable variant switching.
2025-10-23 22:29:28 +05:30
cogwheel0
0df4b4f050 feat(ui): support authenticated image loading with cache manager
Add Riverpod-aware image header and cache manager support for network
images used in avatar and markdown widgets. Convert AvatarImage to a
ConsumerWidget and read a self-signed cache manager and HTTP headers
from Riverpod so CachedNetworkImage can send auth/custom headers and use
the provided cache manager. In Markdown image builder, obtain headers
and cache manager from a ProviderContainer (via ProviderScope.containerOf)
to enable the same authenticated loading in non-consumer contexts.

Introduce image_header_utils.dart to centralize building Authorization
and custom headers from auth/api providers, with helpers for Ref,
WidgetRef, and ProviderContainer. Add dependency adjustments in
pubspec.lock for flutter_cache_manager and http marked as direct main.

These changes ensure protected images (self-signed or auth-required)
load correctly across the app and reuse the configured cache manager.
2025-10-23 17:36:31 +05:30
cogwheel0
56246507de feat(tts): add karaoke-style TTS progress bar to assistant UI
Add rendering and support for a karaoke-style text-to-speechprogress bar in assistant messages so users can see the currently
spoken sentence and highlighted word during playback.

- Append TTS karaoke bar to AssistantMessageWidget when the message is
  the active TTS target and playback is speaking/paused/loading.
- Implement _buildKaraokeBar to render the active sentence with a
  highlighted word span, using ConduitCard and theme styles.
- Import conduit_components for shared UI primitives.
- Extend TextToSpeechState with sentence data:
  sentences, sentenceOffsets, activeSentenceIndex, and per-word
  progress (wordStartInSentence, wordEndInSentence).
- Add provider callbacks wiring: onSentenceIndex and
  onDeviceWordProgress handlers (hooked into TTS backend).
- Prepare sentence splitting and word-progress plumbing in the TTS
  provider (prepares data used to drive the karaoke display).

This change improves UX by visually indicating the spoken sentence
and current word during TTS playback, aiding comprehension and
accessibility.
2025-10-23 17:05:35 +05:30
cogwheel0
d00cbe36cf refactor: Replace hardcoded monospace font with AppTypography constant
- Updated multiple instances of the 'monospace' font family to use AppTypography.monospaceFontFamily for consistency across the application.
- This change enhances maintainability and ensures a unified typography approach throughout the app.
2025-10-21 00:09:12 +05:30
cogwheel0
e05a560966 refactor: Enhance markdown processing for text-to-speech conversion
- Introduced new regex patterns to remove thinking and reasoning blocks from markdown input.
- Added functionality to strip emojis from the text, improving clarity for TTS.
- Implemented HTML entity decoding to ensure proper text representation.
- Replaced the existing sanitization method with a more comprehensive markdown-to-text conversion approach, enhancing performance and maintainability.
2025-10-20 23:53:07 +05:30
cogwheel0
810b44975d refactor: Enhance chat input interaction with state-based overlay colors
- Implemented state-based overlay color changes for the chat input's InkWell widget to improve user feedback during interactions.
- Adjusted the color of the chat input icon to align with the primary button text color, enhancing visual consistency and usability.
2025-10-19 23:07:36 +05:30
cogwheel0
553c213a47 refactor: Update placeholder color in chat input for improved visibility
- Changed the placeholder color in the modern chat input to use the input text color with adjusted alpha for better contrast and visibility in both light and dark themes.
- This enhancement aims to improve user experience by ensuring the placeholder text is more legible across different brightness settings.
2025-10-19 15:08:15 +05:30
cogwheel0
52753b92f7 refactor: Enhance image attachment handling in chat
- Introduced asynchronous decoding for base64 image data to improve performance and responsiveness.
- Added caching for decoded image bytes to optimize loading times and reduce redundant processing.
- Updated error handling to provide clearer feedback when image loading fails, enhancing user experience.
- Refactored loading logic to streamline the process of checking cached images and managing loading states.
- Improved the handling of data URLs and relative URLs for better image attachment management.
2025-10-19 14:18:26 +05:30
cogwheel0
2f8fd97022 refactor: Enhance file attachment handling and UI components
- Updated the file attachment service to utilize a new LocalAttachment class, improving the management of file metadata such as display names.
- Refactored methods for picking and uploading files to accommodate the new LocalAttachment structure, ensuring consistent handling of file attributes.
- Improved the chat page to validate and manage file attachments more effectively, enhancing user experience during file uploads.
- Added functionality for image previews in the file attachment widget, allowing users to see selected images before sending.
- Introduced a remove button for attachments, improving usability by enabling users to easily discard unwanted files.
2025-10-19 13:50:54 +05:30
cogwheel0
bb57f91aeb refactor: Improve chat input UI with enhanced microphone icon handling
- Updated the background color logic in the chat input to use a more consistent alpha value based on brightness.
- Simplified the layout of the chat input by removing unnecessary alignment and shadow properties.
- Introduced a new inline microphone icon that activates voice input, improving user interaction.
- Enhanced the overall structure of the chat input widget for better readability and maintainability.
2025-10-18 15:35:07 +05:30
cogwheel0
f36ebfd630 feat: Enhance chat functionality with follow-up message handling
- Added logic to determine the visibility of follow-up messages based on the presence of user and assistant bubbles below the current message.
- Updated the AssistantMessageWidget to accept a new parameter `showFollowUps`, allowing for conditional rendering of follow-up messages.
- Improved the user experience by ensuring follow-up messages are displayed appropriately based on the chat context.
2025-10-18 15:03:06 +05:30
cogwheel0
f81237e374 refactor: Enhance UI components with updated border styles and theme adjustments
- Removed unnecessary border from UserMessageBubble for a cleaner appearance.
- Adjusted Divider and OutlineInputBorder styles in ChatsDrawer to improve visual consistency with updated alpha values.
- Updated color tokens in AppColorTokens and TweakcnThemes to streamline theme management and ensure better contrast handling.
- Introduced new Tweakcn theme variant 'Claude' for a warm, tactile palette, enhancing overall UI aesthetics.
2025-10-18 14:25:26 +05:30
cogwheel0
570fa26011 feat: enhance markdown image handling with customizable builder
- Introduced an `imageBuilderOverride` parameter in the `ConduitMarkdown` class to allow customization of how markdown images are rendered.
- Updated the `StreamingMarkdownWidget` to accept the new `imageBuilderOverride` parameter, enabling enhanced image handling in streaming contexts.
- Implemented an `imageBuilderOverride` in the `_AssistantMessageWidgetState` to utilize `EnhancedImageAttachment`, providing caching, authentication headers, and fullscreen viewing for markdown images.
- Refactored the `_ImageBuilder` class to support the new image building logic, improving flexibility and maintainability of image rendering in markdown content.
2025-10-10 16:12:31 +05:30
cogwheel0
e73c5ee93a feat: add composer autofocus management for improved chat input experience
- Introduced ComposerAutofocusEnabled provider to manage the auto-focus state of the chat composer, allowing for better control over user interactions.
- Updated ModernChatInput to respect the autofocus setting, ensuring the keyboard behavior aligns with user intent and context.
- Enhanced ChatPage to suppress auto-focus when opening the slide drawer, improving user experience during navigation.
- Refactored SlideDrawer to include an onOpenStart callback for dismissing the keyboard, ensuring a smoother transition when the drawer is opened.
2025-10-10 15:22:54 +05:30
cogwheel0
259fe3f9f0 feat: implement self-signed certificate support in API and UI
- Added support for self-signed TLS certificates in the ApiService, allowing configuration based on server settings.
- Introduced a toggle in the ServerConnectionPage to enable or disable trusting self-signed certificates.
- Updated localization files to include new strings for self-signed certificate settings in multiple languages.
- Enhanced the OptimizedStorageService to manage trusted servers based on user preferences for self-signed certificates.
- Improved error handling and logging throughout the affected services to ensure clarity and maintainability.
2025-10-09 01:49:56 +05:30
cogwheel0
ea79a193be feat: enhance voice call functionality and response handling
- Introduced a new boolean flag `_isSpeaking` in VoiceCallService to manage speaking state during voice interactions.
- Improved response handling by extracting incremental content from socket events and updating the accumulated response accordingly.
- Updated the chat page to include a voice call button, allowing users to initiate voice calls directly from the chat interface.
- Enhanced the modern chat input widget to support voice call functionality, providing a seamless user experience for initiating calls.
2025-10-08 19:09:57 +05:30
cogwheel0
a2e5f46d62 refactor: optimize regex patterns for image and markdown processing
- Introduced pre-compiled regex patterns across various components, including streaming_helper, markdown_stream_formatter, and assistant_message_widget, to enhance performance during image extraction and markdown formatting.
- Updated the AssistantMessageWidget to utilize these optimized patterns for TTS sanitization and image processing, reducing unnecessary regex evaluations.
- Improved overall efficiency in handling markdown content by leveraging pre-compiled patterns for common markdown syntax detection.
2025-10-06 00:09:52 +05:30
cogwheel0
3af46b379b refactor: optimize regex handling in markdown and tool calls parsing
- Improved performance by pre-compiling regex patterns in the ConduitMarkdownPreprocessor for better efficiency during streaming.
- Enhanced the ToolCallsParser to conditionally run cleanup regex only when necessary, ensuring cleaner and more efficient text processing.
- Updated the AssistantMessageWidget to perform quick checks before cleaning raw tags, reducing unnecessary operations and improving overall performance.
2025-10-05 23:51:48 +05:30