]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
main : fix bug (penalize_nl=false doesn't work) + suppress warning on mingw (#1528)
authorDr. Tom Murphy VII Ph.D <redacted>
Sat, 26 Aug 2023 18:12:56 +0000 (14:12 -0400)
committerGitHub <redacted>
Sat, 26 Aug 2023 18:12:56 +0000 (21:12 +0300)
commit72f895c923ba98b8f2af294440206f35915c0501
tree3078543299147a4dc9d473f22236802bd4fdfd0a
parent50526f37eba0b28336700890242ff282b949cd83
main : fix bug (penalize_nl=false doesn't work) + suppress warning on mingw (#1528)

* Fix bug in main.cpp where penalize_nl=false has no effect. It modifies the underlying logits array, but at this point we are already working on the candidates copy.

* Suppress redefinition warning for NOMINMAX on mingw. In my installation, this macro is already defined by /usr/lib/gcc/x86_64-w64-mingw32/11/include/c++/x86_64-w64-mingw32/bits/os_defines.h:45.

* main : fix indentation

* main : pass ctx to llama_token_nl()

---------

Co-authored-by: Georgi Gerganov <redacted>
examples/main/main.cpp