Commit Graph

116 Commits

Author SHA1 Message Date
Matt Rubens
b8e0aa0cde Custom modes 2025-01-21 09:39:54 -05:00
Matt Rubens
332245c33a Merge pull request #445 from punkpeye/feature-metadata-2
fix: correct X-Glama-Metadata placement
2025-01-20 21:58:04 -05:00
Frank
d995a6a3a2 fix: correct X-Glama-Metadata placement 2025-01-20 20:48:18 -06:00
Matt Rubens
a13da25dd1 Deepseek fixes 2025-01-20 11:41:38 -05:00
Frank
a66fb7b7fe feat: identify consumer using tags 2025-01-18 22:38:30 -06:00
Matt Rubens
60a0a824b9 Prettier backfill 2025-01-17 14:11:28 -05:00
Saoud Rizwan
077fa84374 Add Mistral API provider 2025-01-17 01:11:16 -05:00
Matt Rubens
1b60d1e293 Fix VSCode LM 2025-01-16 01:00:07 -05:00
Matt Rubens
50cae9b174 Merge pull request #367 from RooVetGit/vscode-lm-provider
Add VSCode-LM as a provider
2025-01-15 16:53:04 -05:00
Matt Rubens
6e90bcf4a3 Update openai package and use developer role message for o1 2025-01-15 15:59:37 -05:00
Matt Rubens
c673edd526 Merge remote-tracking branch 'origin/main' into vscode-lm-provider 2025-01-15 01:37:37 -05:00
Matt Rubens
4027e1c10c Add non-streaming completePrompt to all providers 2025-01-13 17:20:06 -05:00
Matt Rubens
f7759c1be5 Merge pull request #295 from RooVetGit/add_coverage
Add test coverage
2025-01-09 12:34:05 -05:00
Matt Rubens
d1c39c17e9 Add tests 2025-01-08 17:59:22 -05:00
Matt Rubens
7137f8c528 Spacing adjustments 2025-01-08 17:28:32 -05:00
RaySinner
d5fd2bbb82 merge: resolve conflicts after upstream merge 2025-01-08 23:47:26 +03:00
Matt Rubens
5fbfe9b775 Add test coverage 2025-01-07 16:20:11 -05:00
Matt Rubens
0aa5f1fb85 Add the o1 model 2025-01-07 13:33:47 -05:00
RaySinner
98b9007c36 merge(upstream): merge upstream changes keeping VSCode LM provider and adding Glama support 2025-01-07 01:54:46 +03:00
RaySinner
9d62a7bb77 feat(vscode-lm): implement VS Code Language Models provider 2025-01-07 01:23:22 +03:00
Matt Rubens
7383a0514a Merge pull request #282 from RooVetGit/open_ai_streaming_toggle
Streaming checkbox for OpenAI-compatible providers
2025-01-05 22:46:50 -05:00
Matt Rubens
5e8d804d2b Add test 2025-01-05 20:52:06 -05:00
Matt Rubens
2cdfff02c0 Streaming checkbox for OpenAI-compatible providers 2025-01-05 20:34:54 -05:00
Frank
ac776cc8bf fix: adjust log wording 2025-01-05 19:25:52 -05:00
Frank
f813d65b5a fix: parse text to float 2025-01-05 19:25:44 -05:00
Frank
e632998026 feat: add cache information 2025-01-05 19:25:29 -05:00
Frank
8284efc64b fix: use x-completion-request-id header 2025-01-05 16:42:34 -05:00
Frank
6b048923c6 fix: remove unnecessary delay 2025-01-05 16:42:20 -05:00
Frank
e5e700ffcb feat: add Glama gateway 2025-01-04 22:50:12 -05:00
Matt Rubens
6290f90fa5 Refactor 2024-12-29 12:20:35 -08:00
Matt Rubens
25987dd40b Remove truncation logic for now 2024-12-29 12:03:28 -08:00
Matt Rubens
eb8c4cc50f Add DeepSeek to the list of providers 2024-12-29 11:27:31 -08:00
Matt Rubens
fb70552b57 Interface cleanup 2024-12-28 21:50:27 -08:00
Matt Rubens
111abdbb2c Enhance prompt button for openrouter 2024-12-28 15:44:14 -08:00
Premshay
8460a796e9 Merge branch 'main' into main 2024-12-15 11:15:43 +02:00
Matt Rubens
2cfd76c305 Add 'Include stream options' checkbox for OpenAI-compatible providers 2024-12-12 09:20:58 -05:00
Matt Rubens
156cab8cbc Fix: Add checkbox for stream_options in OpenAI-compatible providers 2024-12-12 08:58:38 -05:00
Cline
1069fda643 Add comprehensive test cases for AwsBedrockHandler 2024-12-11 22:49:02 +02:00
Cline
ca41c54cb5 test(bedrock): add comprehensive test coverage for Bedrock integration
- Add tests for AWS Bedrock handler (stream handling, config, errors)
- Add tests for message format conversion (text, images, tools)
- Add tests for stream event parsing and transformation
- Add tests for cross-region inference and prompt cache
- Add tests for metadata and message lifecycle events
2024-12-11 22:48:49 +02:00
Cline
51a57d5bbf fix(bedrock): improve stream handling and type safety
- Fix TypeScript error in ConverseStreamCommand payload
- Add proper JSON parsing for test stream events
- Improve error handling with proper Error objects
- Add test-specific model info with required fields
- Fix cross-region inference and prompt cache config
2024-12-11 22:47:59 +02:00
Cline
140318cecd feat(api): unify Bedrock provider using Runtime API
Problem:
The current Bedrock implementation uses the Bedrock SDK, which requires separate handling for different model types and doesn't provide a unified streaming interface.

Solution:
Integrate the Bedrock Runtime API to provide a single, unified interface for all Bedrock models (Claude and Nova) using the ConverseStream API. This eliminates the need for separate handlers while maintaining all existing functionality.

Key Changes:
- Refactored AwsBedrockHandler to use @aws-sdk/client-bedrock-runtime
- Enhanced bedrock-converse-format.ts to handle all content types and properly transform between Anthropic and Bedrock formats
- Maintained cross-region inference support with proper region prefixing
- Added support for prompt caching configuration
- Improved AWS credentials handling to better support default providers
- Added proper error handling and token tracking for all response types

Dependencies:
- Added @aws-sdk/client-bedrock-runtime for unified API access
- Removed @anthropic-ai/bedrock-sdk dependency

Testing:
- Verified message format conversion for all content types
- Tested cross-region inference functionality
- Validated streaming responses for both Claude and Nova models

This change simplifies the codebase by providing a single, consistent interface for all Bedrock models while maintaining full compatibility with existing features.
2024-12-11 22:47:56 +02:00
lloydchang
9abe3f6916 fix(openai.ts): default to an empty string if undefined
Change:

const urlHost = new URL(this.options.openAiBaseUrl).host;

To:

const urlHost = new URL(this.options.openAiBaseUrl ?? "").host;

because the nullish coalescing operator (??) to default to an empty string if this.options.openAiBaseUrl is undefined.

It ensures that the URL constructor always receives a valid string.
2024-12-11 02:37:26 -08:00
lloydchang
7c870733a1 Fix code scanning alert no. 1: Incomplete URL substring sanitization
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2024-12-11 02:18:04 -08:00
Matt Rubens
da31a23499 Create a structure for different diff strategies, starting with unified (#55) 2024-12-09 11:04:40 -05:00
John Stearns
423e2af520 Continuing work on support for OpenRouter compression (#43) 2024-12-07 09:38:13 -08:00
Mark Percival
93e70c62f1 Chore: Prettier for consistant formatting (#794)
* Chore: Pretier for consistant formatting

- TODO: This PR needs to be updated by Saoud after he runs `npm install` & `npm format:fix` and commits the results of the prettier changes.

* Revert prettier config

* Run npm install

* Fix prettier config and ignore package lock

* Run format

---------

Co-authored-by: Saoud Rizwan <7799382+saoudrizwan@users.noreply.github.com>
2024-11-21 13:13:54 -08:00
Saoud Rizwan
39bc35eec1 Add LM Studio provider 2024-11-12 22:02:42 -05:00
Saoud Rizwan
bac0b1a0cb Add prompt caching for new model ids on openrouter 2024-11-12 18:35:51 -05:00
Saoud Rizwan
ad29ff2a03 Add AWS cross-region inference toggle 2024-11-07 13:51:13 -05:00
Saoud Rizwan
48cdfa9874 Add Haiku 3.5 to Anthropic, Bedrock, Vertex 2024-11-04 14:08:25 -05:00