Commit Graph

765 Commits

Author SHA1 Message Date
Piotr Wilkin 3a859a27a2 Create basic content parser if no parser definition found 2026-02-16 22:39:12 +01:00
Piotr Wilkin 3d27add7b1 Refactor into class-based approach 2026-02-16 22:39:12 +01:00
Piotr Wilkin 81cb4b7507 Add TODO 2026-02-16 22:39:12 +01:00
Piotr Wilkin 9c8cf1bc43 Clean algorithm for calculate_diff_split; fix buggy expectations 2026-02-16 22:39:12 +01:00
Piotr Wilkin 13a350fa1a Whitespace 2026-02-16 22:39:12 +01:00
Piotr Wilkin b0ed986aec -> Refactor autoparser analyzer structure
-> Fix content truncation
-> Fix errors in capability detection due to non-empty assistant message
-> Add missing debug prints for Jinja
2026-02-16 22:39:12 +01:00
Piotr Wilkin 2da282018e Whoops 2026-02-16 22:39:12 +01:00
Piotr Wilkin 58d822ca0c One more crazy spacing out 2026-02-16 22:39:12 +01:00
Piotr Wilkin f8b0b75a00 Get rid of some crazy formatting 2026-02-16 22:39:12 +01:00
Piotr Wilkin 18054b4e44 Document helpers 2026-02-16 22:39:12 +01:00
Piotr Wilkin 5e38bac7a3 Post-merge adapt 2026-02-16 22:39:12 +01:00
Piotr Wilkin 5164f2f3c8 Fix case with object inside object, refactor long methods. 2026-02-16 22:39:12 +01:00
Piotr Wilkin 8397fdddc6 Fix number partial parsing issue 2026-02-16 22:39:12 +01:00
Piotr Wilkin 5df5390c72 More edge cases 2026-02-16 22:39:12 +01:00
Piotr Wilkin 971b216ce1 Fix pesky issue on optional trailing arguments in function calls for TAGGED format 2026-02-16 22:39:11 +01:00
Piotr Wilkin fcc61e6759 Remove [[noreturn]] as it causes compilation problems on Mac. 2026-02-16 22:39:11 +01:00
Piotr Wilkin 4249e9889f Fix minor regressions, add [[noreturn]] attrib 2026-02-16 22:39:11 +01:00
Piotr Wilkin 0abe32a3d8 Fix incorrect coercion of strings to non-string types during parsing 2026-02-16 22:39:11 +01:00
Piotr Wilkin f1937febff Feeding the hungry editor checker god. 2026-02-16 22:39:11 +01:00
Piotr Wilkin c35b31abe5 Fix error in argument processing 2026-02-16 22:39:11 +01:00
Piotr Wilkin 5cabb3c737 Reverd bad change fix some templates and most tests 2026-02-16 22:39:11 +01:00
Piotr Wilkin bb6337fb90 More robust reasoning detection 2026-02-16 22:39:11 +01:00
Piotr Wilkin 169a0fa0f6 Fix reasoning detection 2026-02-16 22:39:11 +01:00
Piotr Wilkin 2eedbb24e0 Quick vibe-coded fix for proper object printing 2026-02-16 22:39:11 +01:00
Piotr Wilkin 1e3d93cb6b ANOTHER GIANT POST-FIXUP SQUISH 2026-02-16 22:39:11 +01:00
Piotr Wilkin 52d31fa024 THE GIANT AUTOPARSER SQUISH 2026-02-16 22:39:11 +01:00
Piotr Wilkin 052ad2ab8a Make call IDs nine-character 2026-02-16 22:39:11 +01:00
Piotr Wilkin 47a7ebc0c1 Fix sanitizer warnings 2026-02-16 22:39:11 +01:00
Piotr Wilkin b403c9aaa2 Fix bad typo 2026-02-16 22:39:11 +01:00
Piotr Wilkin f2a4ae6ba8 Add workaround for templates requiring non-null content 2026-02-16 22:39:11 +01:00
Ivan Chikish cceb1b4e33
common : inline functions (#18639) 2026-02-16 17:52:24 +02:00
Adrien Gallouët 9e118b97c4
build : remove LLAMA_HTTPLIB option (#19623)
This option was introduced as a workaround because cpp-httplib could not
build on visionOS. Since it has been fixed and now compiles on all platforms,
we can remove it and simplify many things.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
2026-02-15 15:38:50 +01:00
iMil badba89320
NetBSD build support (#19589) 2026-02-14 09:47:01 +01:00
agent-enemy-2 2d8015e8a4
llama : update LoRA API. + fix excessive graph reserves (#19280)
* Refactoring to use new llama_put_adapter_loras

* cont : alternative lora API

---------

Co-authored-by: Jake Chavis <jakechavis6@gmail.com>
Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
2026-02-14 10:06:27 +02:00
Adrien Gallouët b48e80f677
common : update download code (#19573)
* common : remove legacy .json to .etag migration code

Signed-off-by: Adrien Gallouët <angt@huggingface.co>

* common : simplify common_download_file_single_online

This commit also force a redownload if the file exists
but has no .etag file.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>

---------

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
2026-02-13 15:10:46 +01:00
Georgi Gerganov 338085c69e
args : add -kvu to llama-parallel (#19577) 2026-02-12 21:52:41 +02:00
Adrien Gallouët 4ae1b7517a
common : replace deprecated codecvt using parse_utf8_codepoint (#19517)
Signed-off-by: Adrien Gallouët <adrien@gallouet.fr>
2026-02-12 07:27:52 +01:00
Daniel Bevenius 3136a849db
common : remove unused token util functions (#19506)
This commit removes two unused functions `common_lcp` and `common_lcs`.
The last usage of these functions was removed in
Commit 33eff40240 ("server : vision support
via libmtmd") and are no longer used anywhere in the codebase.
2026-02-11 17:41:35 +01:00
Adrien Gallouët 0c1f39a9ae
common : improve download error reporting (#19491)
Signed-off-by: Adrien Gallouët <angt@huggingface.co>
2026-02-11 09:27:55 +01:00
thecaptain789 8ee538ce73
llama : correct typos 'occured' and 'occurences' (#19414)
Co-authored-by: thecaptain789 <thecaptain789@users.noreply.github.com>
2026-02-11 07:05:31 +01:00
Xuan-Son Nguyen 98e57ca422
chat: fix case where template accepts type content only (#19419)
* chat: fix case where template accepts type content only

* rm stray log

* reuse render_message_to_json
2026-02-09 22:14:12 +01:00
Sascha Rogmann 292f6908cd
spec : remove check rate (#19377)
* spec: remove parameter spec-ngram-check-rate

* spec : renamed statistics vars

* spec : add n_call_begin, n_call_accept

* spec : don't enable key-map-stats
2026-02-09 15:30:50 +02:00
Georgi Gerganov dfde5993ea
common : add common_speculative_is_compat() (#19270)
* llama : add llama_memory_can_rm_suffix()

* Revert "llama : add llama_memory_can_rm_suffix()"

This reverts commit d30e59b62a.

* spec : check if the target context is compatible for spec decoding
2026-02-06 16:47:22 +02:00
Xuan-Son Nguyen e0c93af2a0
debug: make common_debug_print_tensor readable (#19331)
* debug: make common_debug_print_tensor readable

* editorconfig
2026-02-04 17:55:31 +01:00
Georgi Gerganov d838c22bb3
spec : fix the check-rate logic of ngram-simple (#19261)
* spec : fix the check-rate logic of ngram-simple

* cont : refactor + fix checks
2026-02-04 10:39:53 +02:00
Georgi Gerganov aeb827a3cc
spec : simplify time measurement using common_time_meas (#19262) 2026-02-03 08:20:15 +02:00
Sid Mohan 0dfcd3b607
jinja : add missing 'in' test to template engine (#19004) (#19239)
* jinja : add missing 'in' test to template engine (#19004)

The jinja template parser was missing the 'in' test from
global_builtins(), causing templates using reject("in", ...),
select("in", ...), or 'x is in(y)' to fail with
"selectattr: unknown test 'in'".

This broke tool-calling for Qwen3-Coder and any other model
whose chat template uses the 'in' test.

Added test_is_in supporting array, string, and object containment
checks, mirroring the existing 'in' operator logic in runtime.cpp.

Includes test cases for all three containment types plus
reject/select filter usage.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* reuse test_is_in in binary op

---------

Co-authored-by: Sid Mohan <sidmohan0@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Xuan Son Nguyen <son@huggingface.co>
2026-02-02 21:00:55 +01:00
Sascha Rogmann b4d05a3d2f
spec : various improvements ton ngram-map + docs (#19253)
* spec: ngram-map and reasoning chats

* spec: add t_begin and t_accept

* ngram-map : add internal hash map

* docs : update ngram-map, add ngram-mod

* docs : fix ngram-map-k

* docs : differences between implementations
2026-02-02 08:26:58 +02:00
Georgi Gerganov 4927795810
ngram-mod : fix build [no ci] (#19216) 2026-01-30 21:27:27 +02:00
Georgi Gerganov dabaa2e77a
spec : add ngram-mod (#19164)
* spec : add ngram-mod

* cont : simplify + keep track of occupancy

* cont : cleanup

* cont : move initialization to common/speculative

* cont : cleanup

* cont : cleanup

* cont : fix
2026-01-30 18:21:48 +02:00