Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions apps/desktop/src-tauri/src/inference/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ struct ModelInfo {
id: String,
}

#[post("/model")]
#[post("/v1/models")]
async fn post_model() -> impl Responder {
HttpResponse::Ok().json(ModelInfo {
id: String::from("local.ai"),
})
}

#[post("/completions")]
#[post("/v1/completions")]
async fn post_completions(payload: Json<CompletionRequest>) -> impl Responder {
println!("Received completion request: {:?}", payload.0);

Expand Down
2 changes: 1 addition & 1 deletion apps/desktop/src/providers/thread.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ const useThreadProvider = ({ thread }: { thread: FileInfo }) => {
})

const fetchStream = await globalThis.fetch(
`http://localhost:${serverConfig.data.port}/completions`,
`http://localhost:${serverConfig.data.port}/v1/completions`,
{
method: "POST",
keepalive: true,
Expand Down