Merged back lost commits in common and arg
This commit is contained in:
parent
09bc6d507c
commit
c19fb26042
2 changed files with 19 additions and 2 deletions
|
@ -1859,9 +1859,23 @@ gpt_params_context gpt_params_parser_init(gpt_params & params, llama_example ex,
|
||||||
params.endpoint_metrics = true;
|
params.endpoint_metrics = true;
|
||||||
}
|
}
|
||||||
).set_examples({LLAMA_EXAMPLE_SERVER}).set_env("LLAMA_ARG_ENDPOINT_METRICS"));
|
).set_examples({LLAMA_EXAMPLE_SERVER}).set_env("LLAMA_ARG_ENDPOINT_METRICS"));
|
||||||
|
add_opt(llama_arg(
|
||||||
|
{"--slots"},
|
||||||
|
format("enable slots monitoring endpoint (default: %s)", params.endpoint_slots ? "enabled" : "disabled"),
|
||||||
|
[](gpt_params & params) {
|
||||||
|
params.endpoint_slots = true;
|
||||||
|
}
|
||||||
|
).set_examples({LLAMA_EXAMPLE_SERVER}).set_env("LLAMA_ARG_ENDPOINT_SLOTS"));
|
||||||
|
add_opt(llama_arg(
|
||||||
|
{"--props"},
|
||||||
|
format("enable changing global properties via POST /props (default: %s)", params.endpoint_props ? "enabled" : "disabled"),
|
||||||
|
[](gpt_params & params) {
|
||||||
|
params.endpoint_props = true;
|
||||||
|
}
|
||||||
|
).set_examples({LLAMA_EXAMPLE_SERVER}).set_env("LLAMA_ARG_ENDPOINT_PROPS"));
|
||||||
add_opt(llama_arg(
|
add_opt(llama_arg(
|
||||||
{"--no-slots"},
|
{"--no-slots"},
|
||||||
format("disables slots monitoring endpoint (default: %s)", params.endpoint_slots ? "enabled" : "disabled"),
|
"disables slots monitoring endpoint",
|
||||||
[](gpt_params & params) {
|
[](gpt_params & params) {
|
||||||
params.endpoint_slots = false;
|
params.endpoint_slots = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -294,7 +294,10 @@ struct gpt_params {
|
||||||
std::string ssl_file_key = ""; // NOLINT
|
std::string ssl_file_key = ""; // NOLINT
|
||||||
std::string ssl_file_cert = ""; // NOLINT
|
std::string ssl_file_cert = ""; // NOLINT
|
||||||
|
|
||||||
bool endpoint_slots = true;
|
// "advanced" endpoints are disabled by default for better security
|
||||||
|
bool webui = true;
|
||||||
|
bool endpoint_slots = false;
|
||||||
|
bool endpoint_props = false; // only control POST requests, not GET
|
||||||
bool endpoint_metrics = false;
|
bool endpoint_metrics = false;
|
||||||
|
|
||||||
bool log_json = false;
|
bool log_json = false;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue