Add support for interacting with Claude in the assistant panel (#11798)

Release Notes:

- Added support for interacting with Claude in the assistant panel. You
can enable it by adding the following to your `settings.json`:

    ```json
    "assistant": {
        "version": "1",
        "provider": {
            "name": "anthropic"
        }
    }
    ```
This commit is contained in:
Antonio Scandurra 2024-05-14 15:57:52 +02:00 committed by GitHub
parent 019d98898e
commit 5944caaa90
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 446 additions and 21 deletions

View file

@ -4489,8 +4489,8 @@ async fn complete_with_anthropic(
.collect();
let mut stream = anthropic::stream_completion(
session.http_client.clone(),
"https://api.anthropic.com",
session.http_client.as_ref(),
anthropic::ANTHROPIC_API_URL,
&api_key,
anthropic::Request {
model,
@ -4499,6 +4499,7 @@ async fn complete_with_anthropic(
system: system_message,
max_tokens: 4092,
},
None,
)
.await?;