mirror of
				https://github.com/ggml-org/llama.cpp.git
				synced 2025-10-30 08:42:00 +00:00 
			
		
		
		
	common : move arg parser code to arg.cpp (#9388)
				
					
				
			* common : move arg parser to arg.cpp * better categorize args * add cmake * missing climits * missing cstdarg * common : more explicit includes * fix build * refactor gpt_params_parse * update server readme * fix test --------- Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
This commit is contained in:
		| @@ -1,11 +1,13 @@ | ||||
| #include "arg.h" | ||||
| #include "common.h" | ||||
| #include "sampling.h" | ||||
| #include "llama.h" | ||||
|  | ||||
| #include <cmath> | ||||
| #include <cstdio> | ||||
| #include <string> | ||||
| #include <vector> | ||||
| #include <set> | ||||
| #include <random> | ||||
|  | ||||
| #define SPEC_VOCAB_MAX_SIZE_DIFFERENCE  100 | ||||
| #define SPEC_VOCAB_CHECK_START_TOKEN_ID 5 | ||||
| @@ -27,8 +29,7 @@ struct seq_draft { | ||||
| int main(int argc, char ** argv) { | ||||
|     gpt_params params; | ||||
|  | ||||
|     auto options = gpt_params_parser_init(params, LLAMA_EXAMPLE_SPECULATIVE); | ||||
|     if (!gpt_params_parse(argc, argv, params, options)) { | ||||
|     if (!gpt_params_parse(argc, argv, params, LLAMA_EXAMPLE_SPECULATIVE)) { | ||||
|         return 1; | ||||
|     } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Xuan Son Nguyen
					Xuan Son Nguyen