ZIm/crates/language_model/src/provider
Bennet Bo Fenner 2ada2964c5
assistant: Make it easier to define custom models (#15442)
This PR makes it easier to specify custom models for the Google, OpenAI,
and Anthropic provider:

Before (google):

```json
{
  "language_models": {
    "google": {
      "available_models": [
        {
          "custom": {
            "name": "my-custom-google-model",
            "max_tokens": 12345
          }
        }
      ]
    }
  }
}
```

After (google):

```json
{
  "language_models": {
    "google": {
      "available_models": [
        {
          "name": "my-custom-google-model",
          "max_tokens": 12345
        }
      ]
    }
  }
}
```

Before (anthropic):

```json
{
  "language_models": {
    "anthropic": {
      "available_models": [
        {
          "custom": {
            "name": "my-custom-anthropic-model",
            "max_tokens": 12345
          }
        }
      ]
    }
  }
}
```

After (anthropic):

```json
{
  "language_models": {
    "anthropic": {
      "version": "1",
      "available_models": [
        {
          "name": "my-custom-anthropic-model",
          "max_tokens": 12345
        }
      ]
    }
  }
}

```

The settings will be auto-upgraded so the old versions will continue to
work (except for Google since that one has not been released).

/cc @as-cii 

Release Notes:

- N/A

---------

Co-authored-by: Thorsten <thorsten@zed.dev>
2024-07-30 15:46:39 +02:00
..
anthropic.rs assistant: Make it easier to define custom models (#15442) 2024-07-30 15:46:39 +02:00
cloud.rs Use tool calling instead of XML parsing to generate edit operations (#15385) 2024-07-29 16:42:08 +02:00
copilot_chat.rs language model: Fix missing use_tool method in CopilotChatLanguageModel (#15466) 2024-07-30 09:54:42 +02:00
fake.rs Use tool calling instead of XML parsing to generate edit operations (#15385) 2024-07-29 16:42:08 +02:00
google.rs assistant: Make it easier to define custom models (#15442) 2024-07-30 15:46:39 +02:00
ollama.rs Use tool calling instead of XML parsing to generate edit operations (#15385) 2024-07-29 16:42:08 +02:00
open_ai.rs assistant: Make it easier to define custom models (#15442) 2024-07-30 15:46:39 +02:00