-
Notifications
You must be signed in to change notification settings - Fork 25.3k
[ML] Integrate with DeepSeek API #122218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ML] Integrate with DeepSeek API #122218
Conversation
Integrating for Chat Completion and Completion task types, both calling the chat completion API for DeepSeek.
Hi @prwhelan, I've created a changelog YAML for you. |
Pinging @elastic/ml-core (Team:ML) |
...ticsearch/xpack/inference/external/request/deepseek/DeepSeekChatCompletionRequestEntity.java
Outdated
Show resolved
Hide resolved
...g/elasticsearch/xpack/inference/external/request/deepseek/DeepSeekChatCompletionRequest.java
Outdated
Show resolved
Hide resolved
...ticsearch/xpack/inference/external/request/deepseek/DeepSeekChatCompletionRequestEntity.java
Outdated
Show resolved
Hide resolved
var validationException = new ValidationException(); | ||
|
||
var model = extractRequiredString(serviceSettingsMap, MODEL_ID, ModelConfigurations.SERVICE_SETTINGS, validationException); | ||
var uri = createOptionalUri( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to allow users to set the URL in the create inference endpoint request? If this is only for testing, then I think we can allow the child classes to override a method to return it, or pass it in via the constructor. Then in the tests we can set it via a constructor or a setter or something.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really only left it exposed but optional because anyone can in theory run the model locally behind an OpenAI compatible endpoint and then call it that way.
I can remove it though if that's not something we want to support, I'm neutral towards it
...in/java/org/elasticsearch/xpack/inference/services/deepseek/DeepSeekChatCompletionModel.java
Show resolved
Hide resolved
...in/java/org/elasticsearch/xpack/inference/services/deepseek/DeepSeekChatCompletionModel.java
Show resolved
Hide resolved
Integrating for Chat Completion and Completion task types, both calling the chat completion API for DeepSeek.
Integrating for Chat Completion and Completion task types, both calling the chat completion API for DeepSeek.
Integrating for Chat Completion and Completion task types, both calling the chat completion API for DeepSeek.
Integrating for Chat Completion and Completion task types, both calling the chat completion API for DeepSeek.
Verified:
max_completion_tokens
does not work, we need to map tomax_tokens
n
is benigntemperature
workstool_choice
worksstrict
tools is benigntop_p
worksstream
works