]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
tokenize : fix trailing whitespace
authorGeorgi Gerganov <redacted>
Fri, 17 Nov 2023 16:01:38 +0000 (18:01 +0200)
committerGeorgi Gerganov <redacted>
Fri, 17 Nov 2023 16:01:38 +0000 (18:01 +0200)
examples/tokenize/tokenize.cpp

index 72b60f9a458080f0c7d08a3fa7bf43f630d3c741..17166836ac127e2bb508c824a6d49b6c9736470f 100644 (file)
@@ -12,8 +12,8 @@ int main(int argc, char ** argv) {
         return 1;
     }
 
-    auto model_path = argv[1];
-    auto prompt = argv[2];
+    const char * model_path = argv[1];
+    const char * prompt     = argv[2];
 
     const bool printing_ids = argc > 3 && std::string(argv[3]) == "--ids";
 
@@ -36,7 +36,7 @@ int main(int argc, char ** argv) {
         if (printing_ids) {
             printf("%d\n", tokens[i]);
         } else {
-            printf("%6d -> '%s'\n", tokens[i], llama_token_to_piece(ctx, tokens[i]).c_str());    
+            printf("%6d -> '%s'\n", tokens[i], llama_token_to_piece(ctx, tokens[i]).c_str());
         }
     }