Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.
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
2 changes: 1 addition & 1 deletion controllers/llamaCPP.cc
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ bool llamaCPP::loadModelImpl(const Json::Value &jsonBody) {
gpt_params params;

// By default will setting based on number of handlers
int drogon_thread = drogon::app().getThreadNum() - 1;
int drogon_thread = drogon::app().getThreadNum() - 5;
LOG_INFO << "Drogon thread is:" << drogon_thread;
if (jsonBody) {
if (!jsonBody["mmproj"].isNull()) {
Expand Down
2 changes: 1 addition & 1 deletion main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ int main(int argc, char *argv[]) {
LOG_INFO << "Server started, listening at: " << host << ":" << port;
LOG_INFO << "Please load your model";
drogon::app().addListener(host, port);
drogon::app().setThreadNum(thread_num + 1);
drogon::app().setThreadNum(thread_num + 5);
LOG_INFO << "Number of thread is:" << drogon::app().getThreadNum();

drogon::app().run();
Expand Down