mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-06-07 20:55:34 +00:00
Change the /chat route to /chat/completions to be OpenAI-compatible
This commit is contained in:
parent
39320a6fce
commit
1a84f00fbf
@ -42,7 +42,7 @@ use crate::search_queue::SearchQueue;
|
|||||||
const EMBEDDER_NAME: &str = "openai";
|
const EMBEDDER_NAME: &str = "openai";
|
||||||
|
|
||||||
pub fn configure(cfg: &mut web::ServiceConfig) {
|
pub fn configure(cfg: &mut web::ServiceConfig) {
|
||||||
cfg.service(web::resource("").route(web::post().to(chat)));
|
cfg.service(web::resource("/completions").route(web::post().to(chat)));
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Get a chat completion
|
/// Get a chat completion
|
||||||
|
Loading…
x
Reference in New Issue
Block a user