]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
bench: server add stop word for PHI-2 (#6916)
authorPierrick Hymbert <redacted>
Fri, 26 Apr 2024 07:26:16 +0000 (09:26 +0200)
committerGitHub <redacted>
Fri, 26 Apr 2024 07:26:16 +0000 (09:26 +0200)
examples/server/bench/script.js

index c4c486cdf93d93a4fb7c488ad82d79b51d1f4dfd..bdf4f5abc87f79f9d7a9f7b252884ceb1117df05 100644 (file)
@@ -90,7 +90,8 @@ export default function () {
         "model": model,
         "stream": true,
         "seed": 42,
-        "max_tokens": max_tokens
+        "max_tokens": max_tokens,
+        "stop": ["<|im_end|>"] // This is temporary for phi-2 base (i.e. not instructed) since the server expects that the model always to emit BOS
     }
 
     const params = {method: 'POST', body: JSON.stringify(payload)};