diff options
author | saood06 <saood05@gmail.com> | 2025-02-23 00:16:27 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-02-23 00:16:27 -0600 |
commit | 46bf73a37f1aabe6f0b40365b0c7b2ba831905f5 (patch) | |
tree | 9b684d9fdc8fc42fa44da832d998091fa33b6444 /common | |
parent | 71b7b510c2dc55ae70934d246cd4e6c3bdf4a95c (diff) |
Add new sweep-bench benchmark (#225)
* examples : add new sweep-bench benchmark
* Change documentation to reference ik_llama.cpp
* Made it compile with ik_llama
* Fix JSONL output
---------
Co-authored-by: Stanisław Szymczyk <sszymczy@gmail.com>
Diffstat (limited to 'common')
-rw-r--r-- | common/common.cpp | 9 | ||||
-rw-r--r-- | common/common.h | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/common/common.cpp b/common/common.cpp index f7a6f76f..6bf6e4f9 100644 --- a/common/common.cpp +++ b/common/common.cpp @@ -1360,6 +1360,15 @@ bool gpt_params_find_arg(int argc, char ** argv, const std::string & arg, gpt_pa params.warmup = false; return true; } + if (arg == "--output-format") { + CHECK_ARG + std::string value(argv[i]); + /**/ if (value == "jsonl") { params.sweep_bench_output_jsonl = true; } + else if (value == "md") { params.sweep_bench_output_jsonl = false; } + else { invalid_param = true; } + return true; + } + #ifndef LOG_DISABLE_LOGS // Parse args for logging parameters if (log_param_single_parse(argv[i])) { diff --git a/common/common.h b/common/common.h index fc1ae619..b5b67986 100644 --- a/common/common.h +++ b/common/common.h @@ -269,6 +269,8 @@ struct gpt_params { bool spm_infill = false; // suffix/prefix/middle pattern for infill std::string lora_outfile = "ggml-lora-merged-f16.gguf"; + + bool sweep_bench_output_jsonl = false; }; void gpt_params_handle_hf_token(gpt_params & params); |