117 Commits

Author SHA1 Message Date
Pawan Osman cc0b9687d8 Update CHANGELOG for version 0.0.5 with new features, fixes, and changes
- Added live timeout countdown badges, redesigned shell tool cards, and implemented hard budgets for subagents to prevent hangs.
- Fixed issues with tools getting stuck, improved error handling for invalid paths, and addressed UI freezes from high-frequency events.
- Changed default timeouts for Todo operations and tightened read timeouts to enhance performance consistency.
0.0.5 0.0.3
2026-07-15 18:38:34 +03:00
Pawan Osman e9d0b96931 Update tool timeout settings for Todo operations to improve performance consistency
- Increased the timeout values for `TodoWrite` and `TodoRead` from 5 seconds to 15 seconds in both the agent and UI components, ensuring better handling of longer operations and reducing potential timeouts.
2026-07-15 18:32:20 +03:00
Pawan Osman 4286a28ce3 Refactor file reading options to streamline abort signal handling
- Updated the `readFileTool` to use a unified `readOpts` object for managing abort signals, improving code clarity and consistency.
- Removed redundant signal parameters in file system operations, ensuring cleaner function calls while maintaining existing timeout management.
- Enhanced error handling during file reads to provide clearer feedback on issues encountered with file paths.
2026-07-15 18:25:02 +03:00
Pawan Osman affe3e1c21 Enhance file reading functionality with improved error handling and timeout management
- Refactored the `readFileTool` to incorporate a timeout mechanism, preventing hangs on network or missing paths.
- Introduced a new `withAbortTimeout` function to manage promise timeouts and abort signals effectively.
- Enhanced error messages for various file read scenarios, providing clearer feedback on issues like missing paths and permission errors.
- Updated the `safePath` function to utilize a new `normalizePathInput` utility for better path normalization.
- Adjusted tool timeout settings in both the agent and UI to ensure consistent timeout behavior across components.
2026-07-15 18:24:11 +03:00
Pawan Osman 01a0da3bc9 Refactor subStatus handling in SidebarProvider for improved clarity
- Updated the logic for determining the `subStatus` in the `SidebarProvider` to streamline the assignment process.
- Enhanced readability by consolidating the conditional checks for `subStatus`, ensuring consistent status updates for tasks and cancellations.
- Maintained existing functionality while improving code maintainability and clarity.
2026-07-15 18:17:48 +03:00
Pawan Osman b63ac10f8f Enhance tool timeout management and UI integration
- Updated the `runAgent` function to improve timeout handling for MCP tools, ensuring shared budget management and better execution limits.
- Introduced a countdown mechanism for tool calls, allowing for real-time UI feedback on execution status and tool cancellations.
- Enhanced the UI components to display timeout badges and countdowns for running tools, improving user awareness and responsiveness.
- Implemented a silent countdown feature for collapsed tool groups, ensuring timely cancellations without UI clutter.
- Refactored the `Tool` component to integrate timeout badges, providing clearer visual indicators of tool status.
2026-07-15 18:04:43 +03:00
Pawan Osman 6b8301a28e Enhance tool timeout management and UI feedback for subagents
- Updated the `runAgent` function to include timeout management for tool calls, allowing for better handling of execution limits and user feedback.
- Introduced `timeoutMs` and `startedAt` properties in the `tool-call-started` event to facilitate countdown displays in the UI.
- Enhanced the UI to show countdown timers for running tools, improving user awareness of execution status.
- Implemented immediate UI updates on tool cancellation or timeout, ensuring a responsive experience even during long-running operations.
- Refactored the `SidebarProvider` to handle subagent cancellations more effectively, providing clearer status updates in the UI.
2026-07-15 17:56:30 +03:00
Pawan Osman 5dab80f764 Implement coalescing for high-frequency UI events and enhance subagent budget management
- Introduced a coalescing mechanism for UI events in the sidebar and agent loop to prevent performance issues caused by high-frequency updates.
- Added budget management for foreground and background subagents, ensuring timely execution and preventing timeouts.
- Enhanced the `runAgent` function to handle budget hits and provide appropriate feedback on subagent execution status.
- Updated the UI to batch process events, improving responsiveness and reducing the likelihood of UI freezes during agent operations.
2026-07-15 16:45:46 +03:00
Pawan Osman f01e337cb6 Enhance error handling for file path validation in tools
- Improved error handling in `readFileTool`, `listDirTool`, `globTool`, and other tools to catch invalid path errors and return user-friendly messages.
- Refactored path handling to ensure consistent validation across multiple tools, enhancing robustness and user feedback.
- Updated `safePath` function to normalize input paths and prevent potential security issues by checking workspace boundaries.
- Added utility functions for quoting paths in shell commands to handle spaces and special characters correctly.
2026-07-15 16:43:54 +03:00
Pawan Osman 7f000c254c Refactor tool timeout handling and error management
- Updated timeout settings for various tools to improve responsiveness and prevent blocking the agent loop.
- Enhanced error handling in tools to provide clearer feedback on invalid paths and execution failures.
- Implemented abort signal support in multiple tools, allowing for graceful cancellation of long-running operations.
- Adjusted the `walk` function to respect abort signals and limit the number of files processed, preventing hangs during directory traversals.
- Improved the `grepTool`, `globTool`, and `fileSearchTool` to handle timeouts and abort signals effectively, enhancing overall tool performance.
2026-07-15 16:35:26 +03:00
Pawan Osman 76993e645b Update CHANGELOG for version 0.0.4 with new features and improvements
- Added per-tool hard timeouts and abort-signal support for long-running tools to enhance responsiveness.
- Introduced configurable timeout settings in the agent's configuration.
- Implemented GPU-accelerated local embeddings with fallback options, along with detailed indexing page information.
- Expanded ignored directories for tools and indexing to improve performance and efficiency.
2026-07-15 15:41:03 +03:00
Pawan Osman d47e978be7 Enhance semantic indexing and UI status display
- Updated the `semanticIndex` module to support GPU acceleration with ONNX Runtime, improving performance on compatible devices.
- Introduced new functions to determine preferred embedding devices and handle device status, enhancing the flexibility of the embedding process.
- Expanded the `IndexStatus` interface to include backend type, device information, and runtime details for better tracking of indexing status.
- Enhanced the UI in the settings panel to display runtime and device information, providing users with clearer insights into the indexing process and model usage.
2026-07-15 15:37:43 +03:00
Pawan Osman a3d917d1b5 Enhance file indexing and exclusion logic for improved performance
- Updated the `indexWatch` module to refine the criteria for skipping non-source directories and files, including a comprehensive list of ignored paths.
- Enhanced the `semanticIndex` module with additional file extensions and directory segments to ensure only relevant source files are indexed.
- Introduced new utility functions to determine indexable paths, improving the accuracy of the indexing process and reducing unnecessary overhead.
- Expanded the `IGNORE` set in the `shared` module to include more build and cache directories, streamlining the file walking process.
2026-07-15 15:28:56 +03:00
Pawan Osman 205c6cd1b7 Implement per-tool timeout configuration in settings
- Added support for per-tool timeout overrides in seconds, allowing users to customize tool execution limits.
- Introduced `setToolTimeoutOverrides` function to apply user-defined timeout settings.
- Updated the `FeatureConfig` interface and default settings to include `toolTimeoutsSec`.
- Enhanced the settings UI to display and manage tool timeout values, ensuring a better user experience for configuring tool behavior.
2026-07-15 15:25:24 +03:00
Pawan Osman 3b246ec787 Implement per-tool timeout and abort signal handling for agent tools
- Introduced a timeout mechanism for various tools (e.g., Grep, Glob, Shell) to prevent blocking the agent loop due to hung processes.
- Enhanced the `walk` function to accept an optional AbortSignal, allowing for graceful cancellation of directory traversals.
- Updated the `runAgent` function to utilize the new timeout and abort handling, ensuring tools can be aborted without affecting the overall agent execution.
- Refactored the `grepTool`, `globTool`, and `fileSearchTool` to incorporate abort signal handling, improving responsiveness during long-running operations.
- Added utility functions for managing tool timeouts and signal handling across the agent's tools.
2026-07-15 15:19:38 +03:00
Pawan Osman 1bfe813edd Update CHANGELOG for version 0.0.3 with new features, changes, and fixes
- Added indexing toggle in settings, persistent semantic index, incremental re-indexing, real-time auto-indexing, and context size dropdown for models.
- Changed smart conversation summarization triggers, subagent history management, multitask handling, and stop/cancel behavior.
- Fixed issues with stuck subagent spinners, orphaned shell processes, and context ring defaults.
- Updated version in package.json to 0.0.3.
2026-07-15 14:30:40 +03:00
Pawan Osman 506a8e14c8 Refactor sidebar context picker and enhance styling
- Updated the `ContextPicker` component to improve button styling and dropdown functionality, replacing the `ctx-chip` class with `ctx-pill` for better visual consistency.
- Enhanced dropdown item layout with new classes for improved accessibility and user experience.
- Adjusted positioning logic for the dropdown menu to ensure it remains within viewport bounds.
2026-07-15 14:28:23 +03:00
Pawan Osman 75955a8033 Enhance context management and UI components in agent and sidebar
- Updated the `runAgent` function to improve context handling for subagents, ensuring isolated execution and clearer event emission.
- Refactored context budget logic to optimize summarization at 80% usage, enhancing performance during agent runs.
- Introduced a new `ContextPicker` component in the sidebar for selecting context sizes, improving user interaction with model options.
- Added styling for context chips and dropdowns to enhance the UI experience in the sidebar.
2026-07-15 14:24:16 +03:00
Pawan Osman 268b0e28de Enhance agent context handling and feature store options
- Updated the `runAgent` function to include additional parameters for context management, ensuring isolated execution for subagents.
- Introduced a new `parseContextLabel` function to convert context size labels into token counts, improving flexibility for model configurations.
- Enhanced the `optionsFor` method in `FeatureStore` to ensure every model has a context window option, providing a fallback for models without preset context values.
- Refactored sidebar provider logic to utilize the new context parsing function, streamlining context size handling across the application.
2026-07-15 14:21:53 +03:00
Pawan Osman 1baa6f8c58 Refactor agent run logic and enhance cancellation handling
- Improved the `runAgent` function to handle parent and child abort signals more robustly, ensuring proper cleanup and cancellation of subagents.
- Introduced a new `raceAbort` function to manage timeouts and abort conditions for running promises, preventing hangs during execution.
- Enhanced the `forceSettleOpenWork` function to mark open tools and subagents as cancelled or closed, improving the user experience during interruptions.
- Updated the UI components to reflect the new cancellation logic, ensuring that the status of ongoing operations is accurately communicated to users.
- Refactored various sections of the codebase to streamline the handling of agent runs and their associated states.
2026-07-15 14:14:50 +03:00
Pawan Osman 3da6b8675b Enhance background subagent handling in runAgent function
- Introduced a new function `awaitPendingBg` to manage background subagents more effectively, ensuring that the main agent waits for all unreported subagents to settle before proceeding.
- Updated the logic to handle in-flight background tasks, preventing premature model calls while background work is still ongoing.
- Improved status notifications to inform users about the waiting state for background subagents.
- Refactored existing code to streamline the handling of background tasks and their results.
2026-07-15 14:05:32 +03:00
Pawan Osman 2f04612e8d Implement incremental indexing and file watching for semantic updates
- Introduced a new `indexWatch` module to handle debounced file watching for incremental updates to the semantic index.
- Updated `activate` function to initialize the index watcher and replace the previous build index call with a warm disk and incremental sync.
- Enhanced the `semanticIndex` module to support enabling/disabling indexing and improved index path normalization.
- Modified the settings panel and UI components to include an option for enabling/disabling indexing, reflecting changes in the feature store.
- Ensured that indexing operations respect the new `indexingEnabled` flag across various functionalities, including search and document indexing.
2026-07-15 13:56:26 +03:00
Pawan Osman 72cbd0b120 Add VS Code configuration files for extension development
- Created .vscode/extensions.json to recommend essential extensions.
- Added .vscode/launch.json for launch configurations to run the extension.
- Introduced .vscode/settings.json to customize workspace settings, including file exclusion.
- Implemented .vscode/tasks.json to define build and watch tasks for TypeScript and esbuild.
2026-07-15 13:48:55 +03:00
Pawan Osman f8ea587099 Update CHANGELOG for version 0.0.2 and implement workspace-specific conversation storage
- Added per-workspace conversations with automatic migration from global conversations.
- Implemented auto-loading of GGUF models with a loading card in chat.
- Enhanced llama.cpp server to use random free ports with retry on bind failure.
- Improved composer dropdown positioning and shared model selection across composers.
- Fixed production error related to missing '@huggingface/hub' package.
- Removed MCP tool marketplace.
- Updated version in package.json to 0.0.2.
0.0.2
2026-07-05 23:30:49 +03:00
Pawan Osman 7bb5801a8c Rewrite project as OpenCursor, a VS Code AI coding agent extension
Replace the ChatGPT reverse proxy (Docker/proxy server) entirely with
OpenCursor: a Cursor-like agentic coding extension for VS Code.

- Remove proxy server, Dockerfiles, docker-compose setups, and CI workflows
- Add agent loop with tools (files, shell, search, web, MCP), multi-provider
  LLM support (OpenAI-compatible, Ollama, llama.cpp) with OAuth
- Add semantic indexing, workspace context, and @-mentions
- Add sidebar chat + settings webview UI (React), inline review, personas,
  hooks, and approval policies
- Switch to pnpm, esbuild bundling, and VS Code extension packaging
0.0.1
2026-07-05 22:07:25 +03:00
Pawan Osman e02bc493a1 Update README.md 2024-08-23 18:25:51 +03:00
Pawan Osman b6148f5b5e Update README.md 2024-08-23 18:25:34 +03:00
Pawan Osman 46043c6851 Update error response and logs 2024-04-22 14:01:24 +03:00
Pawan Osman d9a36a890d Merge pull request #106 from m00nfly/main
Add access authentication by api_key
2024-04-22 13:56:32 +03:00
m00nfly 4729671c01 Merge branch 'main' of https://github.com/m00nfly/ChatGPT into main 2024-04-21 16:53:20 +08:00
Pawan Osman 4d10b10d9e Add: verification client api_key access function
set API_KEY in .env file to enable this function
Unsetting or setting API_KEY to null will keep the default of allowing anonymous access.

Changes to be committed:
	modified:   .env.example
	modified:   src/app.ts
2024-04-21 16:26:11 +08:00
Pawan Osman 21dc6ef01f Fix: return when failed to getNewSession, add 5 times retry to getNewSession 2024-04-20 23:33:22 +03:00
Pawan Osman deacb3b418 Comment error logs 2024-04-20 22:44:07 +03:00
Pawan Osman e8a7f795dd Fix: adding proof-token header to bypass the new OpenAI request validation 2024-04-20 22:39:21 +03:00
Pawan Osman da84287823 Add: more error handling 2024-04-20 02:58:18 +03:00
Pawan Osman b77b7ff02f Merge pull request #96 from MahdeenSky/fixed_notfounderror
Fix: The "file" argument must be of type string. (Cloudflared)
2024-04-19 11:00:44 +03:00
MahdeenSky 6a536cf10b fixed file error now works locally 2024-04-18 18:38:15 -04:00
Pawan Osman a44d20b27a Update Dockerfile 2024-04-15 09:41:39 +03:00
Pawan Osman 9235d190c6 Add: cloudflared tunnel 2024-04-14 21:05:48 +03:00
Pawan Osman 11908a2dda Update start.sh 2024-04-14 18:34:19 +03:00
Pawan Osman d1a817c94d Update Dockerfile 2024-04-14 18:29:59 +03:00
Pawan Osman d8f0f2cea0 Update Dockerfile 2024-04-14 14:22:21 +03:00
Pawan Osman 0ae934f89d Update Dockerfile 2024-04-14 14:20:17 +03:00
Pawan Osman 9fc6df667a Merge pull request #91 from Crescent617/fix_created
Fix response timestamp
2024-04-14 14:12:42 +03:00
Crescent617 05ce427362 fix: created should be in seconds, https://github.com/openai/openai-openapi/blob/master/openapi.yaml\#L6972 2024-04-14 17:39:34 +08:00
Pawan Osman 7d87f1f579 Merge pull request #85 from k8scat/main
optimize: copy source code in Dockerfile
2024-04-11 15:47:03 +03:00
Pawan Osman b74c115311 Add: HTTP Proxy option, which can be configured using the .env file. 2024-04-11 15:43:08 +03:00
K8sCat b0bed1ed53 optimize: copy source code in Dockerfile
Signed-off-by: K8sCat <k8scat@gmail.com>
2024-04-11 10:17:09 +08:00
Pawan Osman d6f5a0918a Update README.md 2024-04-10 11:15:43 +03:00
Pawan Osman b2e81e6e9b Update app.ts 2024-04-10 09:53:51 +03:00