]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/log
pkg/ggml/sources/llama.cpp
7 weeks agoserver: fix duplicate HTTP headers in multiple models mode (#17698)
Pascal [Wed, 3 Dec 2025 09:28:43 +0000 (10:28 +0100)]
server: fix duplicate HTTP headers in multiple models mode (#17698)

* llama-server: fix duplicate HTTP headers in multiple models mode (#17693)

* llama-server: address review feedback from ngxson

- restrict scope of header after std::move
- simplify header check (remove unordered_set)

7 weeks agoggml webgpu: add support for emscripten builds (#17184)
Reese Levine [Wed, 3 Dec 2025 09:25:34 +0000 (01:25 -0800)]
ggml webgpu: add support for emscripten builds (#17184)

* Faster tensors (#8)

Add fast matrix and matrix/vector multiplication.

* Use map for shader replacements instead of pair of strings

* Wasm (#9)

* webgpu : fix build on emscripten

* more debugging stuff

* test-backend-ops: force single thread on wasm

* fix single-thread case for init_tensor_uniform

* use jspi

* add pthread

* test: remember to set n_thread for cpu backend

* Add buffer label and enable dawn-specific toggles to turn off some checks

* Intermediate state

* Fast working f16/f32 vec4

* Working float fast mul mat

* Clean up naming of mul_mat to match logical model, start work on q mul_mat

* Setup for subgroup matrix mat mul

* Basic working subgroup matrix

* Working subgroup matrix tiling

* Handle weirder sg matrix sizes (but still % sg matrix size)

* Working start to gemv

* working f16 accumulation with shared memory staging

* Print out available subgroup matrix configurations

* Vectorize dst stores for sg matrix shader

* Gemv working scalar

* Minor set_rows optimization (#4)

* updated optimization, fixed errors

* non vectorized version now dispatches one thread per element

* Simplify

* Change logic for set_rows pipelines

---------

Co-authored-by: Neha Abbas <redacted>
Co-authored-by: Neha Abbas <redacted>
Co-authored-by: Reese Levine <redacted>
* Comment on dawn toggles

* Working subgroup matrix code for (semi)generic sizes

* Remove some comments

* Cleanup code

* Update dawn version and move to portable subgroup size

* Try to fix new dawn release

* Update subgroup size comment

* Only check for subgroup matrix configs if they are supported

* Add toggles for subgroup matrix/f16 support on nvidia+vulkan

* Make row/col naming consistent

* Refactor shared memory loading

* Move sg matrix stores to correct file

* Working q4_0

* Formatting

* Work with emscripten builds

* Fix test-backend-ops emscripten for f16/quantized types

* Use emscripten memory64 to support get_memory

* Add build flags and try ci

---------

Co-authored-by: Xuan Son Nguyen <redacted>
* Remove extra whitespace

* Move wasm single-thread logic out of test-backend-ops for cpu backend

* Disable multiple threads for emscripten single-thread builds in ggml_graph_plan

* Fix .gitignore

* Add memory64 option and remove unneeded macros for setting threads to 1

---------

Co-authored-by: Xuan Son Nguyen <redacted>
7 weeks agoci : move release details to the top visible by default (#17719)
Sigbjørn Skjæret [Wed, 3 Dec 2025 08:22:46 +0000 (09:22 +0100)]
ci : move release details to the top visible by default (#17719)

7 weeks agoggml, llama : use defaulted constructors/destructors (#17649)
Herman Semenoff [Wed, 3 Dec 2025 06:12:18 +0000 (09:12 +0300)]
ggml, llama : use defaulted constructors/destructors (#17649)

7 weeks agobuild: document how to compile with Vulkan using Debian/Ubuntu packages (#17688)
Marcos Del Sol Vives [Wed, 3 Dec 2025 00:25:11 +0000 (01:25 +0100)]
build: document how to compile with Vulkan using Debian/Ubuntu packages (#17688)

7 weeks agoserver: add --media-path for local media files (#17697)
Xuan-Son Nguyen [Tue, 2 Dec 2025 21:49:20 +0000 (22:49 +0100)]
server: add --media-path for local media files (#17697)

* server: add --media-path for local media files

* remove unused fn

7 weeks agomtmd: fix --no-warmup (#17695)
Xuan-Son Nguyen [Tue, 2 Dec 2025 21:48:08 +0000 (22:48 +0100)]
mtmd: fix --no-warmup (#17695)

7 weeks agoci : RVV1.0 builds with tests (#16682)
Ali Tariq [Tue, 2 Dec 2025 20:46:10 +0000 (01:46 +0500)]
ci : RVV1.0 builds with tests (#16682)

* Added RISC-V supported tests

* Added default value for LLAMA_FATAL_WARNINGS and option to specify by user

* Added RISC-V supported tests

* Added default value for LLAMA_FATAL_WARNINGS and option to specify by user

* Removed apt prompt

* Added RISC-V specific tests with corrections

Corrections included:
1. Changed the test names from debian to ubuntu as it is more stable than Debian Trixie
2. Added explicit compiler in cmake command as GCC compiler below version 14 have been recorded
to throw errors with rvv1.0 and some other extensions
3. Added dependencies which are not installed by default in the RISC-V Ubuntu 24.04
4. Separate ccache directory for all jobs as all the ccache results are not the same and may cause ccache to not work

* Resolved the merge conflict and cleaned up run.sh

* Update ci/run.sh

Co-authored-by: Sigbjørn Skjæret <redacted>
* Removed previously added build ci for RISC-V

* Removed trailing whitespaces

* corrected build name

Co-authored-by: Sigbjørn Skjæret <redacted>
* cleanup

* Enabled build tests (1)

Co-authored-by: Sigbjørn Skjæret <redacted>
* Enabled build tests (2)

Co-authored-by: Sigbjørn Skjæret <redacted>
* enable openssl

---------

Co-authored-by: Sigbjørn Skjæret <redacted>
7 weeks agovulkan: Reduce temporary memory usage for TOP_K (#17623)
Jeff Bolz [Tue, 2 Dec 2025 18:22:04 +0000 (12:22 -0600)]
vulkan: Reduce temporary memory usage for TOP_K (#17623)

- Compute row size for the temp buffer based on the output of the first pass.
- Update shader addressing math to use the output row size
- Pass the output row size as "ncols_output", what used to be "ncols_output" is now "k"

For the common case of K=40 and src0=(200000,1,1,1), this reduces the temporary buffer
from about 3.2MB to 500KB.

7 weeks agocmake : add utf8 compilation options for msvc (#17682)
xiaobing318 [Tue, 2 Dec 2025 17:50:57 +0000 (01:50 +0800)]
cmake : add utf8 compilation options for msvc (#17682)

7 weeks agoServer: Change Invalid Schema from Server Error (500) to User Error (400) (#17572)
Chad Voegele [Tue, 2 Dec 2025 16:33:50 +0000 (10:33 -0600)]
Server: Change Invalid Schema from Server Error (500) to User Error (400) (#17572)

* Make invalid schema a user error (400)

* Move invalid_argument exception handler to ex_wrapper

* Fix test

* Simplify test back to original pattern

7 weeks agoggml : use svcntb() for SVE vector length detection (#17474)
Adrien Gallouët [Tue, 2 Dec 2025 16:21:11 +0000 (17:21 +0100)]
ggml : use svcntb() for SVE vector length detection (#17474)

Signed-off-by: Adrien Gallouët <redacted>
7 weeks agoCANN: Disable Ger operator of OUT_PROD on 310p device (#17563)
TianHao324 [Tue, 2 Dec 2025 12:35:23 +0000 (20:35 +0800)]
CANN: Disable Ger operator of OUT_PROD on 310p device (#17563)

7 weeks agoggml : remove redundant n_copies check when setting input/output (#17612)
Daniel Bevenius [Tue, 2 Dec 2025 11:52:45 +0000 (12:52 +0100)]
ggml : remove redundant n_copies check when setting input/output (#17612)

This commit removes a redundant check for sched->n_copies > 1 when
setting input and output flags on tensor copies in
ggml_backend_sched_split_graph.

The motivation for this change is to clarify the code as the outer if
statement already performs this check.

7 weeks agocodeowners : remove ericcurtin (#17658)
Eric Curtin [Tue, 2 Dec 2025 11:18:15 +0000 (11:18 +0000)]
codeowners : remove ericcurtin (#17658)

Taking a break from llama.cpp . I wasn't around at the start of llama.cpp
but I want to thank @ggerganov and @slaren for creating a neat community
here.

Signed-off-by: Eric Curtin <redacted>
7 weeks agollama : fix signed comparison warning on FreeBSD (#17497)
Adrien Gallouët [Tue, 2 Dec 2025 11:05:38 +0000 (12:05 +0100)]
llama : fix signed comparison warning on FreeBSD (#17497)

This ensures correct RLIM_INFINITY handling and compatibility on all platforms (32/64-bit).

    warning: comparison of integers of different signs: 'rlim_t' (aka 'long') and 'size_t' (aka 'unsigned long') [-Wsign-compare]
      488 |         if (suggest && (lock_limit.rlim_max > lock_limit.rlim_cur + size)) {
          |                         ~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Adrien Gallouët <redacted>
7 weeks agoconvert: add error message for mistral3 quantized weight (#17686)
Xuan-Son Nguyen [Tue, 2 Dec 2025 10:48:31 +0000 (11:48 +0100)]
convert: add error message for mistral3 quantized weight (#17686)

7 weeks agoserver: remove default "gpt-3.5-turbo" model name (#17668)
Xuan-Son Nguyen [Tue, 2 Dec 2025 10:38:57 +0000 (11:38 +0100)]
server: remove default "gpt-3.5-turbo" model name (#17668)

* server: remove default "gpt-3.5-turbo" model name

* do not reflect back model name from request

* fix test

7 weeks agoserver: fixing naming conflict res_error in server-models.cpp (#17679)
senhtry [Tue, 2 Dec 2025 10:18:39 +0000 (18:18 +0800)]
server: fixing naming conflict res_error in server-models.cpp (#17679)

7 weeks agoserver: explicitly set exec path when create new instance (#17669)
Xuan-Son Nguyen [Tue, 2 Dec 2025 09:25:11 +0000 (10:25 +0100)]
server: explicitly set exec path when create new instance (#17669)

* Revert "rm unused fn"

This reverts commit f2dbe9c087ac8776cd41f747a8b0ddf448c8399a.

* server: explicitly set exec path when create new instance

* put back TODO

* only call get_server_exec_path() once

* add fallback logic

7 weeks agoci : skip winget update when not in ggml-org (#17465)
Adrien Gallouët [Tue, 2 Dec 2025 09:15:01 +0000 (10:15 +0100)]
ci : skip winget update when not in ggml-org (#17465)

Prevent forks from generating daily failure notifications.

Signed-off-by: Adrien Gallouët <redacted>
7 weeks agoggml : add fallback definition for HWCAP2_SVE2 (#17683)
Adrien Gallouët [Tue, 2 Dec 2025 08:41:26 +0000 (09:41 +0100)]
ggml : add fallback definition for HWCAP2_SVE2 (#17683)

This align with other HWCAP2 feature flags

See #17528

Signed-off-by: Adrien Gallouët <redacted>
7 weeks agoAdd context info to server error (#17663)
Aleksander Grygier [Tue, 2 Dec 2025 08:20:57 +0000 (09:20 +0100)]
Add context info to server error (#17663)

* fix: Add context info to server error

* chore: update webui build output

7 weeks agoggml-cuda: reorder only relevant nodes (#17639)
Aman Gupta [Tue, 2 Dec 2025 04:36:31 +0000 (12:36 +0800)]
ggml-cuda: reorder only relevant nodes (#17639)

7 weeks agorelease: fix duplicate libs, store symbolic links (#17299)
Aaron Teo [Tue, 2 Dec 2025 03:52:05 +0000 (11:52 +0800)]
release: fix duplicate libs, store symbolic links (#17299)

7 weeks agoenhance argsort for UT (#17573)
Neo Zhang Jianyu [Tue, 2 Dec 2025 00:56:46 +0000 (08:56 +0800)]
enhance argsort for UT (#17573)

Co-authored-by: Neo Zhang <redacted>
7 weeks agoOverride SSM_A op for Qwen3 Next to reduce splits (#17587)
Piotr Wilkin (ilintar) [Mon, 1 Dec 2025 23:43:13 +0000 (00:43 +0100)]
Override SSM_A op for Qwen3 Next to reduce splits (#17587)

* Override SSM_A op for Qwen3 Next to reduce splits

* New tensor mapping SSM_A_NOSCAN for SSM_A used outside of OP_SSM_SCAN context.

* Update src/llama-model.cpp

Co-authored-by: Sigbjørn Skjæret <redacted>
* Update src/llama-model.cpp

Co-authored-by: Sigbjørn Skjæret <redacted>
---------

Co-authored-by: Sigbjørn Skjæret <redacted>
7 weeks agoops.md: update vulkan support (#17661)
Jeff Bolz [Mon, 1 Dec 2025 21:26:21 +0000 (15:26 -0600)]
ops.md: update vulkan support (#17661)

7 weeks agomtmd: add mtmd_context_params::warmup option (#17652)
Xuan-Son Nguyen [Mon, 1 Dec 2025 20:32:25 +0000 (21:32 +0100)]
mtmd: add mtmd_context_params::warmup option (#17652)

* mtmd: add mtmd_context_params::warmup option

* reuse the common_params::warmup

7 weeks agofix: llama arch implementation (#17665)
Gilad S. [Mon, 1 Dec 2025 20:21:13 +0000 (22:21 +0200)]
fix: llama arch implementation (#17665)

7 weeks agoserver: introduce API for serving / loading / unloading multiple models (#17470)
Xuan-Son Nguyen [Mon, 1 Dec 2025 18:41:04 +0000 (19:41 +0100)]
server: introduce API for serving / loading / unloading multiple models (#17470)

* server: add model management and proxy

* fix compile error

* does this fix windows?

* fix windows build

* use subprocess.h, better logging

* add test

* fix windows

* feat: Model/Router server architecture WIP

* more stable

* fix unsafe pointer

* also allow terminate loading model

* add is_active()

* refactor: Architecture improvements

* tmp apply upstream fix

* address most problems

* address thread safety issue

* address review comment

* add docs (first version)

* address review comment

* feat: Improved UX for model information, modality interactions etc

* chore: update webui build output

* refactor: Use only the message data `model` property for displaying model used info

* chore: update webui build output

* add --models-dir param

* feat: New Model Selection UX WIP

* chore: update webui build output

* feat: Add auto-mic setting

* feat: Attachments UX improvements

* implement LRU

* remove default model path

* better --models-dir

* add env for args

* address review comments

* fix compile

* refactor: Chat Form Submit component

* ad endpoint docs

* Merge remote-tracking branch 'webui/allozaur/server_model_management_v1_2' into xsn/server_model_maagement_v1_2

Co-authored-by: Aleksander <redacted>
* feat: Add copy to clipboard to model name in model info dialog

* feat: Model unavailable UI state for model selector

* feat: Chat Form Actions UI logic improvements

* feat: Auto-select model from last assistant response

* chore: update webui build output

* expose args and exit_code in API

* add note

* support extra_args on loading model

* allow reusing args if auto_load

* typo docs

* oai-compat /models endpoint

* cleaner

* address review comments

* feat: Use `model` property for displaying the `repo/model-name` naming format

* refactor: Attachments data

* chore: update webui build output

* refactor: Enum imports

* feat: Improve Model Selector responsiveness

* chore: update webui build output

* refactor: Cleanup

* refactor: Cleanup

* refactor: Formatters

* chore: update webui build output

* refactor: Copy To Clipboard Icon component

* chore: update webui build output

* refactor: Cleanup

* chore: update webui build output

* refactor: UI badges

* chore: update webui build output

* refactor: Cleanup

* refactor: Cleanup

* chore: update webui build output

* add --models-allow-extra-args for security

* nits

* add stdin_file

* fix merge

* fix: Retrieve lost setting after resolving merge conflict

* refactor: DatabaseStore -> DatabaseService

* refactor: Database, Conversations & Chat services + stores architecture improvements (WIP)

* refactor: Remove redundant settings

* refactor: Multi-model business logic WIP

* chore: update webui build output

* feat: Switching models logic for ChatForm or when regenerating messges + modality detection logic

* chore: update webui build output

* fix: Add `untrack` inside chat processing info data logic to prevent infinite effect

* fix: Regenerate

* feat: Remove redundant settigns + rearrange

* fix: Audio attachments

* refactor: Icons

* chore: update webui build output

* feat: Model management and selection features WIP

* chore: update webui build output

* refactor: Improve server properties management

* refactor: Icons

* chore: update webui build output

* feat: Improve model loading/unloading status updates

* chore: update webui build output

* refactor: Improve API header management via utility functions

* remove support for extra args

* set hf_repo/docker_repo as model alias when posible

* refactor: Remove ConversationsService

* refactor: Chat requests abort handling

* refactor: Server store

* tmp webui build

* refactor: Model modality handling

* chore: update webui build output

* refactor: Processing state reactivity

* fix: UI

* refactor: Services/Stores syntax + logic improvements

Refactors components to access stores directly instead of using exported getter functions.

This change centralizes store access and logic, simplifying component code and improving maintainability by reducing the number of exported functions and promoting direct store interaction.

Removes exported getter functions from `chat.svelte.ts`, `conversations.svelte.ts`, `models.svelte.ts` and `settings.svelte.ts`.

* refactor: Architecture cleanup

* feat: Improve statistic badges

* feat: Condition available models based on modality + better model loading strategy & UX

* docs: Architecture documentation

* feat: Update logic for PDF as Image

* add TODO for http client

* refactor: Enhance model info and attachment handling

* chore: update webui build output

* refactor: Components naming

* chore: update webui build output

* refactor: Cleanup

* refactor: DRY `getAttachmentDisplayItems` function + fix UI

* chore: update webui build output

* fix: Modality detection improvement for text-based PDF attachments

* refactor: Cleanup

* docs: Add info comment

* refactor: Cleanup

* re

* refactor: Cleanup

* refactor: Cleanup

* feat: Attachment logic & UI improvements

* refactor: Constants

* feat: Improve UI sidebar background color

* chore: update webui build output

* refactor: Utils imports + move types to `app.d.ts`

* test: Fix Storybook mocks

* chore: update webui build output

* test: Update Chat Form UI tests

* refactor: Tooltip Provider from core layout

* refactor: Tests to separate location

* decouple server_models from server_routes

* test: Move demo test  to tests/server

* refactor: Remove redundant method

* chore: update webui build output

* also route anthropic endpoints

* fix duplicated arg

* fix invalid ptr to shutdown_handler

* server : minor

* rm unused fn

* add ?autoload=true|false query param

* refactor: Remove redundant code

* docs: Update README documentations + architecture & data flow diagrams

* fix: Disable autoload on calling server props for the model

* chore: update webui build output

* fix ubuntu build

* fix: Model status reactivity

* fix: Modality detection for MODEL mode

* chore: update webui build output

---------

Co-authored-by: Aleksander Grygier <redacted>
Co-authored-by: Georgi Gerganov <redacted>
7 weeks agocommon: improve verbosity level definitions (#17630)
Xuan-Son Nguyen [Mon, 1 Dec 2025 13:38:13 +0000 (14:38 +0100)]
common: improve verbosity level definitions (#17630)

* common: improve verbosity level definitions

* string_format

* update autogen docs

7 weeks agomodel: support Ministral3 (#17644)
Xuan-Son Nguyen [Mon, 1 Dec 2025 11:26:52 +0000 (12:26 +0100)]
model: support Ministral3 (#17644)

* conversion script

* support ministral 3

* maybe this is better?

* add TODO for rope_yarn_log_mul

* better ppl (tested on 14B-Instruct)

* Add Ministral3 support to Mistral format

* improve arch handling

* add sizes

* Apply suggestions from code review

Co-authored-by: Sigbjørn Skjæret <redacted>
* nits

---------

Co-authored-by: Julien Denize <redacted>
Co-authored-by: Sigbjørn Skjæret <redacted>
7 weeks agometal : add FA head size 48 (#17619)
Georgi Gerganov [Mon, 1 Dec 2025 10:49:53 +0000 (12:49 +0200)]
metal : add FA head size 48 (#17619)

7 weeks agoggml : extend the GGML_SCHED_NO_REALLOC debug logic of the scheduler (#17617)
Georgi Gerganov [Mon, 1 Dec 2025 10:49:33 +0000 (12:49 +0200)]
ggml : extend the GGML_SCHED_NO_REALLOC debug logic of the scheduler (#17617)

7 weeks agollama-graph: avoid expand_forward for fusion (#17633)
Aman Gupta [Mon, 1 Dec 2025 09:12:48 +0000 (17:12 +0800)]
llama-graph: avoid expand_forward for fusion (#17633)

8 weeks agocontributing: update guidelines for AI-generated code (#17625)
Xuan-Son Nguyen [Sun, 30 Nov 2025 21:51:34 +0000 (22:51 +0100)]
contributing: update guidelines for AI-generated code (#17625)

* contributing: update guidelines for AI-generated code

* revise

8 weeks agocmake : add option to build and link LibreSSL (#17552)
Adrien Gallouët [Sun, 30 Nov 2025 21:14:32 +0000 (22:14 +0100)]
cmake : add option to build and link LibreSSL (#17552)

Signed-off-by: Adrien Gallouët <redacted>
8 weeks agomodel: LFM2-VL fixes (#17577)
Tarek Dakhran [Sun, 30 Nov 2025 20:57:31 +0000 (21:57 +0100)]
model: LFM2-VL fixes (#17577)

* Adjust to pytorch

* Add antialiasing upscale

* Increase number of patches to 1024

* Handle default marker insertion for LFM2

* Switch to flag

* Reformat

* Cuda implementation of antialias kernel

* Change placement in ops.cpp

* consistent float literals

* Pad only for LFM2

* Address PR feedback

* Rollback default marker placement changes

* Fallback to CPU implementation for antialias implementation of upscale

8 weeks agoclip: fix nb calculation for qwen3-vl (#17594)
Xuan-Son Nguyen [Sun, 30 Nov 2025 14:33:55 +0000 (15:33 +0100)]
clip: fix nb calculation for qwen3-vl (#17594)

8 weeks agocli: add migration warning (#17620)
Xuan-Son Nguyen [Sun, 30 Nov 2025 14:32:43 +0000 (15:32 +0100)]
cli: add migration warning (#17620)

8 weeks agocommon : throttle download progress output to reduce IO flush (#17427)
Adrien Gallouët [Sun, 30 Nov 2025 12:22:44 +0000 (13:22 +0100)]
common : throttle download progress output to reduce IO flush (#17427)

This change limits progress updates to approximately every 0.1% of the
file size to minimize stdio overhead.

Also fixes compiler warnings regarding __func__ in lambdas.

Signed-off-by: Adrien Gallouët <redacted>
8 weeks agocommon: add LLAMA_LOG_FILE env var (#17609)
Aaron Teo [Sun, 30 Nov 2025 11:12:32 +0000 (19:12 +0800)]
common: add LLAMA_LOG_FILE env var (#17609)

Signed-off-by: Aaron Teo <redacted>
8 weeks agoggml: fix: macOS build with `-DGGML_BACKEND_DL=ON` (#17581)
Gilad S. [Sun, 30 Nov 2025 02:00:59 +0000 (04:00 +0200)]
ggml: fix: macOS build with `-DGGML_BACKEND_DL=ON` (#17581)

8 weeks agocommon: update env var name (#17588)
ddh0 [Sun, 30 Nov 2025 01:59:25 +0000 (19:59 -0600)]
common: update env var name (#17588)

8 weeks agoCUDA: add stream-based concurrency (#16991)
Aman Gupta [Sun, 30 Nov 2025 00:17:55 +0000 (08:17 +0800)]
CUDA: add stream-based concurrency (#16991)

* CUDA: add stream-based concurrency

* HIP: fix hipStreamWaitEvent define and nodiscard warnings

* ggml-cuda: fix fusion inside stream

* ggml-cuda: fix bug w.r.t first stream launch

* ggml-cuda: format

* ggml-cuda: improve assert message

* ggml-cuda: use lambda instead of duplicating code

* ggml-cuda: add some more comments

* ggml-cuda: add more detailed comments about concurrency

* ggml-cuda: rename + remove unused var

* ggml-cuda: fix condition for stream launch

* ggml-cuda: address review comments, add destructor

* common.cuh: add is_valid for concurrent events

* common.cuh: make comment better

* update comment

Co-authored-by: Johannes Gäßler <redacted>
* update comment

Co-authored-by: Johannes Gäßler <redacted>
* common.cuh: fix lower_bound condition + remove join_node data from write_ranges

* ggml-cuda: fix overlap condition + shadowing parameter

---------

Co-authored-by: Carl Philipp Klemm <redacted>
Co-authored-by: Johannes Gäßler <redacted>
8 weeks ago cuda : add error checking for cudaMemcpyAsync in argsort (#17599)
Mahekk Shaikh [Sun, 30 Nov 2025 00:16:28 +0000 (19:16 -0500)]
   cuda : add error checking for cudaMemcpyAsync in argsort (#17599)

* cuda : add error checking for cudaMemcpyAsync in argsort (#12836)

* fix indentation

8 weeks agovulkan : fix FA mask load with bounds check (coopmat2) (#17606)
Acly [Sun, 30 Nov 2025 00:03:21 +0000 (01:03 +0100)]
vulkan : fix FA mask load with bounds check (coopmat2) (#17606)

8 weeks agoserver: move server-context to its own cpp|h (#17595)
Xuan-Son Nguyen [Sat, 29 Nov 2025 21:04:44 +0000 (22:04 +0100)]
server: move server-context to its own cpp|h (#17595)

* git mv

* add server-context.h

* add server-context.h

* clean up headers

* cont : cleanup

* also expose server_response_reader (to be used by CLI)

* fix windows build

* decouple server_routes and server_http

---------

Co-authored-by: Georgi Gerganov <redacted>
8 weeks agoserver: explicitly set the function name in lambda (#17538)
Haiyue Wang [Sat, 29 Nov 2025 17:43:29 +0000 (01:43 +0800)]
server: explicitly set the function name in lambda (#17538)

As [1] explained, the real debug message will be like:
"res    operator(): operator() : queue result stop"

Set the name explicitly, the message is easy for debugging:
"res    operator(): recv : queue result stop"

The left "operator()" is generated by 'RES_DBG() ... __func__'

[1]: https://clang.llvm.org/extra/clang-tidy/checks/bugprone/lambda-function-name.html

Signed-off-by: Haiyue Wang <redacted>
8 weeks agocommon : fix json schema with '\' in literals (#17307)
Igor Smirnov [Sat, 29 Nov 2025 16:06:32 +0000 (21:06 +0500)]
common : fix json schema with '\' in literals (#17307)

* Fix json schema with '\' in literals

* Add "literal string with escapes" test

8 weeks agosycl : support to malloc memory on device more than 4GB, update the doc and script...
Neo Zhang [Sat, 29 Nov 2025 12:59:44 +0000 (20:59 +0800)]
sycl : support to malloc memory on device more than 4GB, update the doc and script (#17566)

Co-authored-by: Neo Zhang Jianyu <redacted>
8 weeks agoggml: replace hwcap with riscv_hwprobe for RVV detection (#17567)
ixgbe [Sat, 29 Nov 2025 12:56:31 +0000 (20:56 +0800)]
ggml: replace hwcap with riscv_hwprobe for RVV detection (#17567)

Signed-off-by: Wang Yang <redacted>
8 weeks agoVulkan: MMVQ Integer Dot K-Quant and MUL_MAT_ID support (#16900)
Ruben Ortlam [Sat, 29 Nov 2025 08:37:22 +0000 (09:37 +0100)]
Vulkan: MMVQ Integer Dot K-Quant and MUL_MAT_ID support (#16900)

* vulkan: split mul_mmq_funcs for mul_mat_vecq use

* add mxfp4 mmvq

* add q2_k mmvq

* add q3_k mmvq

* add q4_k and q5_k mmvq

* add q6_k mmvq

* handle 4x4 quants per mmvq thread

* enable MUL_MAT_ID mmvq support

* enable subgroup optimizations for mul_mat_vec_id shaders

* device tuning

* request prealloc_y sync after quantization

* fix indentation

* fix llvmpipe test failures

* fix mul_mat_id mmvq condition

* fix unused variable warning

8 weeks agovulkan: improve topk perf for large k, fix overflow in unit tests (#17582)
Jeff Bolz [Sat, 29 Nov 2025 07:39:57 +0000 (01:39 -0600)]
vulkan: improve topk perf for large k, fix overflow in unit tests (#17582)

8 weeks agogguf-py : fix passing non-native endian tensors (editor-gui and new-metadata) (#17553)
Aleksei Nikiforov [Fri, 28 Nov 2025 19:53:01 +0000 (20:53 +0100)]
gguf-py : fix passing non-native endian tensors (editor-gui and new-metadata) (#17553)

gguf_new_metadata.py reads data from reader.
Reader doesn't byteswap tensors to native endianness.
But writer does expect tensors in native endianness to convert them
into requested endianness.

There are two ways to fix this: update reader and do conversion to native endianness and back,
or skip converting endianness in writer in this particular USE-case.

gguf_editor_gui.py doesn't allow editing or viewing tensor data.
Let's go with skipping excessive byteswapping.

If eventually capability to view or edit tensor data is added,
tensor data should be instead byteswapped when reading it.

8 weeks agocommon : move all common_chat_parse_* to chat-parser.cpp. (#17481)
DAN™ [Fri, 28 Nov 2025 18:29:36 +0000 (13:29 -0500)]
common : move all common_chat_parse_* to chat-parser.cpp. (#17481)

8 weeks agoserver: fix: /metrics endpoint returning JSON-escaped Prometheus format (#17386)
o7si [Fri, 28 Nov 2025 18:14:00 +0000 (02:14 +0800)]
server: fix: /metrics endpoint returning JSON-escaped Prometheus format (#17386)

* fix: /metrics endpoint returning JSON-escaped Prometheus format

* mod: remove string overload from ok() method

8 weeks agoggml : add GGML_SCHED_NO_REALLOC option to disable reallocations in ggml_backend_sche...
Diego Devesa [Fri, 28 Nov 2025 15:33:23 +0000 (07:33 -0800)]
ggml : add GGML_SCHED_NO_REALLOC option to disable reallocations in ggml_backend_sched (#17276)

* ggml : add GGML_SCHED_NO_REALLOC option to disable reallocations in ggml_backend_sched
Enabled in ggml-ci for testing.

* llama : update worst-case graph for unified cache

* ci : disable op offload in some tests

* fix spelling

---------

Co-authored-by: Georgi Gerganov <redacted>
8 weeks ago[MUSA] enable fp16/fast_fp16/bf16_mma on PH1 (#17551)
R0CKSTAR [Fri, 28 Nov 2025 13:08:29 +0000 (21:08 +0800)]
[MUSA] enable fp16/fast_fp16/bf16_mma on PH1 (#17551)

* [MUSA] enable fp16/fast_fp16/bf16_mma on PH1

Signed-off-by: Xiaodong Ye <redacted>
* Update ggml/src/ggml-cuda/fattn-vec.cuh

Co-authored-by: Johannes Gäßler <redacted>
* Update ggml/src/ggml-cuda/fattn-vec.cuh

Co-authored-by: Johannes Gäßler <redacted>
* Update ggml/src/ggml-cuda/fattn-tile.cuh

Co-authored-by: Johannes Gäßler <redacted>
* Address review comments

Signed-off-by: Xiaodong Ye <redacted>
---------

Signed-off-by: Xiaodong Ye <redacted>
Co-authored-by: Johannes Gäßler <redacted>
8 weeks agoggml-cuda: add stricter checking for fusion (#17568)
Aman Gupta [Fri, 28 Nov 2025 12:34:51 +0000 (20:34 +0800)]
ggml-cuda: add stricter checking for fusion (#17568)

* ggml-cuda: make conditions for fusion more explicit

* ggml-cuda: remove size check as std::equal already does it

8 weeks agoserver : add Anthropic Messages API support (#17570)
Fredrik Hultin [Fri, 28 Nov 2025 11:57:04 +0000 (12:57 +0100)]
server : add Anthropic Messages API support (#17570)

* server : add Anthropic Messages API support

* remove -@pytest.mark.slow from tool calling/jinja tests

* server : remove unused code and slow/skip on test_anthropic_vision_base64_with_multimodal_model in test_anthropic_api.py

* server : removed redundant n field logic in anthropic_params_from_json

* server : use single error object instead of error_array in streaming response handler for /v1/chat/completions and use unordered_set instead of set in to_json_anthropic_stream()

* server : refactor Anthropic API to use OAI conversion

* make sure basic test always go first

* clean up

* clean up api key check, add test

---------

Co-authored-by: Xuan Son Nguyen <redacted>
8 weeks agomodel : Qwen3 Next (#16095)
Piotr Wilkin (ilintar) [Fri, 28 Nov 2025 11:02:56 +0000 (12:02 +0100)]
model : Qwen3 Next (#16095)

* Qwen3 Next - cleaned up version

* Whitespaces and stuff

* Correct minor errors

* Update src/llama-model.cpp

Co-authored-by: Sigbjørn Skjæret <redacted>
* Misc. fixes.

* Clean up code, add missing hybrid qualifier

* Did someone transpose the SOLVE_TRI result matrix? Perhaps...

* Whitespace

* Proper tensors for cb calls

* Use llama-graph.h vertical alignment

* BROKEN: chunking

* Set new tensors as inputs.

* Proper chunk logic

* It's the circle of life...

* More shenanigans for n_seq > 1

* Nail in the coffin?

* Fix Windows build

* Eh, one fails on Windows, the other fails on Mac... just use general capture.

* quant : cleanup

* model : cleanup

* qwen3 : cleanup

* cont : cleanup

* cont : cleanup

* ggml : revert change

* qwen3 : cleanup

* cont : cleanup

* Readd cmath

* qwen3 : fix typo

* Update convert_hf_to_gguf.py

Co-authored-by: Sigbjørn Skjæret <redacted>
* Usual suspects

* fix my bad suggestion

---------

Co-authored-by: Sigbjørn Skjæret <redacted>
Co-authored-by: Georgi Gerganov <redacted>
8 weeks agoCUDA: no FP16 arithmetic for vector FA kernel (#17558)
Johannes Gäßler [Fri, 28 Nov 2025 09:29:09 +0000 (10:29 +0100)]
CUDA: no FP16 arithmetic for vector FA kernel (#17558)

8 weeks agovulkan: Implement GGML_OP_TRI (#17503)
Jeff Bolz [Fri, 28 Nov 2025 09:07:29 +0000 (03:07 -0600)]
vulkan: Implement GGML_OP_TRI (#17503)

* vulkan: Implement GGML_OP_TRI

* check types match

8 weeks agorpc : cache and reuse compute graphs (#15405)
Radoslav Gerganov [Fri, 28 Nov 2025 08:33:51 +0000 (10:33 +0200)]
rpc : cache and reuse compute graphs (#15405)

Store the last computed graph and reuse it when possible.
Also do not return response from GRAPH_COMPUTE and assume it always
completes successfully. If this this is not the case, the server closes
the connection. This saves us a network round trip to the server.

8 weeks agoHIP: enable mul_mat_f for RDNA4 (#17437)
yulo [Fri, 28 Nov 2025 07:24:30 +0000 (15:24 +0800)]
HIP: enable mul_mat_f for RDNA4 (#17437)

* enable mmf for rdna4

* move some mmvf to mmf

* revert lds128 for wmma loading

* Revert "revert lds128 for wmma loading"

This reverts commit db9ae8b6b4738a5def5b393caa1611d52133e9b5.

* Revert "enable mmf for rdna4"

This reverts commit 698c9f24187b990e35c3b73a8067e5387e6ddbd4.

* Revert "move some mmvf to mmf"

This reverts commit 99b92bd6653cc8593607f641e44606391691792f.

* enable mul_mat for rdna4

---------

Co-authored-by: zhang hui <redacted>
8 weeks agoSOLVE_TRI CUDA kernel for small matrices (#17457)
Piotr Wilkin (ilintar) [Fri, 28 Nov 2025 04:15:32 +0000 (05:15 +0100)]
SOLVE_TRI CUDA kernel for small matrices (#17457)

8 weeks agorefactor pad_reflect_1d to make the UT case pass (#17204)
Neo Zhang Jianyu [Fri, 28 Nov 2025 00:50:56 +0000 (08:50 +0800)]
refactor pad_reflect_1d to make the UT case pass (#17204)

Co-authored-by: Zhang Jianyu <redacted>
8 weeks agovulkan: Implement SOLVE_TRI (#17486)
Jeff Bolz [Thu, 27 Nov 2025 14:48:00 +0000 (08:48 -0600)]
vulkan: Implement SOLVE_TRI (#17486)

* vulkan: Implement SOLVE_TRI

* load B matrix through shared memory

* use FLOAT_TYPE

8 weeks agoarch : add description about LLM_TENSOR_INFOS (#17550)
Georgi Gerganov [Thu, 27 Nov 2025 14:34:13 +0000 (16:34 +0200)]
arch : add description about LLM_TENSOR_INFOS (#17550)

8 weeks agomodels : fix LFM2 tensors (#17548)
Georgi Gerganov [Thu, 27 Nov 2025 14:04:29 +0000 (16:04 +0200)]
models : fix LFM2 tensors (#17548)

8 weeks agocuda : fix UMA detection on discrete GPUs. (#17537)
matt23654 [Thu, 27 Nov 2025 11:35:35 +0000 (11:35 +0000)]
cuda : fix UMA detection on discrete GPUs. (#17537)

8 weeks agoggml-cpu: aarm64: q4_K repack gemm and gemv implementations (dotprod only) (#17494)
Alberto Cabrera Pérez [Thu, 27 Nov 2025 11:25:14 +0000 (11:25 +0000)]
ggml-cpu: aarm64: q4_K repack gemm and gemv implementations (dotprod only) (#17494)

* Enabled q4_K_4x8 path

* Fixed generic Q4_K 8x4 implementation

* wip: dotprod gemm

* Working arm q4_K dotprod gemm

Signed-off-by: Alberto Cabrera <redacted>
* Undo acc rename

Signed-off-by: Alberto Cabrera <redacted>
* Q4_K arm dotprod gemm

Signed-off-by: Alberto Cabrera <redacted>
* Fix: q4_qs reinterpret from uint to int

Signed-off-by: Alberto Cabrera <redacted>
* Removed comments

* Fixed macro guards

* Fixed unused vars in generic implementation

* Fixed unused vars in 8x4 repack

* Fixed unused vars in generic implementation, unneeded comment

* Missing arch fallback for x86

* minor : style

---------

Signed-off-by: Alberto Cabrera <redacted>
Co-authored-by: Georgi Gerganov <redacted>
8 weeks agodevops: Add build-essential to Ubuntu 26.04 image (#17531)
Eric Curtin [Thu, 27 Nov 2025 10:35:47 +0000 (10:35 +0000)]
devops: Add build-essential to Ubuntu 26.04 image (#17531)

This is no longer passing the build, needs more packages.

Signed-off-by: Eric Curtin <redacted>
8 weeks agogguf-py : skip endian-conversion of MXFP4 data (#17523)
Aleksei Nikiforov [Thu, 27 Nov 2025 10:35:38 +0000 (11:35 +0100)]
gguf-py : skip endian-conversion of MXFP4 data (#17523)

* gguf_convert_endian.py: skip MXFP4 data

* Use gguf.constants.GGML_QUANT_SIZES to determine block sizes

8 weeks agovulkan : move contiguous checks to device_supports_op (#17490)
Acly [Thu, 27 Nov 2025 05:54:19 +0000 (06:54 +0100)]
vulkan : move contiguous checks to device_supports_op (#17490)

* vulkan : remove op_supports_incontiguous and add missing constraints in device_supports_op

* im2col: remove contraints on src0 (kernel input)

8 weeks agovulkan: use a fixed 1KB buffer for the add_rms_fusion opt (#17514)
Jeff Bolz [Thu, 27 Nov 2025 05:32:30 +0000 (23:32 -0600)]
vulkan: use a fixed 1KB buffer for the add_rms_fusion opt (#17514)

8 weeks agoserver: enable jinja by default, update docs (#17524)
Xuan-Son Nguyen [Thu, 27 Nov 2025 00:02:50 +0000 (01:02 +0100)]
server: enable jinja by default, update docs (#17524)

* server: enable jinja by default, update docs

* fix tests

8 weeks agoopencl: add sqr, sqrt, mean and ssm_conv (#17476)
lhez [Wed, 26 Nov 2025 21:29:58 +0000 (13:29 -0800)]
opencl: add sqr, sqrt, mean and ssm_conv (#17476)

* opencl: add sqr

* opencl: add sqrt

* opencl: add mean

* opencl: add ssm_conv

* opencl: add missing cl_khr_fp16

* opencl: do sqrt in f32 then convert to f16 for better precision

8 weeks agoFix chunks being too small with small matrix sizes (#17526)
Alberto Cabrera Pérez [Wed, 26 Nov 2025 21:14:54 +0000 (21:14 +0000)]
Fix chunks being too small with small matrix sizes (#17526)

8 weeks agoclip: (minicpmv) fix resampler kq_scale (#17516)
Han Qingzhe [Wed, 26 Nov 2025 20:44:07 +0000 (04:44 +0800)]
clip: (minicpmv) fix resampler kq_scale (#17516)

* debug:"solve minicpmv precision problem"

* “debug minicpmv”

* Apply suggestion from @ngxson

---------

Co-authored-by: Xuan-Son Nguyen <redacted>
8 weeks agovulkan: allow graph_optimize for prompt processing workloads (#17475)
Jeff Bolz [Wed, 26 Nov 2025 15:46:33 +0000 (09:46 -0600)]
vulkan: allow graph_optimize for prompt processing workloads (#17475)

8 weeks agovulkan: Implement top-k (#17418)
Jeff Bolz [Wed, 26 Nov 2025 15:45:43 +0000 (09:45 -0600)]
vulkan: Implement top-k (#17418)

* vulkan: Implement top-k

Each pass launches workgroups that each sort 2^N elements (where N is usually 7-10)
and discards all but the top K. Repeat until only K are left. And there's a fast
path when K==1 to just find the max value rather than sorting.

* fix pipeline selection

* vulkan: Add N-ary search algorithm for topk

* microoptimizations

8 weeks agoggml-cpu : add RISC-V Zvfh impl for ggml_vec_mad_f16 (#17448)
xctan [Wed, 26 Nov 2025 13:33:05 +0000 (21:33 +0800)]
ggml-cpu : add RISC-V Zvfh impl for ggml_vec_mad_f16 (#17448)

* ggml-cpu : add RISC-V Zvfh impl for ggml_vec_mad_f16

* ggml-cpu : dedup scalar impl

* Update ggml/src/ggml-cpu/vec.h

---------

Co-authored-by: Georgi Gerganov <redacted>
8 weeks agocmake : use EXCLUDE_FROM_ALL to avoid patch-boringssl.cmake (#17520)
Adrien Gallouët [Wed, 26 Nov 2025 13:15:21 +0000 (14:15 +0100)]
cmake : use EXCLUDE_FROM_ALL to avoid patch-boringssl.cmake (#17520)

We have to separate the code path starting 3.28 because
`FetchContent_Populate` is now deprecated and will be completely removed
in a future version.

Signed-off-by: Adrien Gallouët <redacted>
8 weeks agoggml : fix ARM feature verification (#17519)
Adrien Gallouët [Wed, 26 Nov 2025 13:14:41 +0000 (14:14 +0100)]
ggml : fix ARM feature verification (#17519)

On arm64 with `cmake` version 3.31.6, the final feature verification fails:

    -- ARM detected flags: -mcpu=neoverse-v2+crc+sve2-aes+sve2-sha3+nossbs
    -- Performing Test GGML_MACHINE_SUPPORTS_dotprod
    -- Performing Test GGML_MACHINE_SUPPORTS_dotprod - Success
    -- Performing Test GGML_MACHINE_SUPPORTS_i8mm
    -- Performing Test GGML_MACHINE_SUPPORTS_i8mm - Success
    -- Performing Test GGML_MACHINE_SUPPORTS_sve
    -- Performing Test GGML_MACHINE_SUPPORTS_sve - Success
    -- Performing Test GGML_MACHINE_SUPPORTS_sme
    -- Performing Test GGML_MACHINE_SUPPORTS_sme - Failed
    -- Performing Test GGML_MACHINE_SUPPORTS_nosme
    -- Performing Test GGML_MACHINE_SUPPORTS_nosme - Success
    -- Checking for ARM features using flags:
    --   -U__ARM_FEATURE_SME
    --   -mcpu=neoverse-v2+crc+sve2-aes+sve2-sha3+nossbs+dotprod+i8mm+sve+nosme
    -- Performing Test HAVE_DOTPROD
    -- Performing Test HAVE_DOTPROD - Failed
    -- Performing Test HAVE_SVE
    -- Performing Test HAVE_SVE - Failed
    -- Performing Test HAVE_MATMUL_INT8
    -- Performing Test HAVE_MATMUL_INT8 - Failed
    -- Performing Test HAVE_FMA
    -- Performing Test HAVE_FMA - Success
    -- Performing Test HAVE_FP16_VECTOR_ARITHMETIC
    -- Performing Test HAVE_FP16_VECTOR_ARITHMETIC - Failed
    -- Performing Test HAVE_SME
    -- Performing Test HAVE_SME - Failed
    -- Adding CPU backend variant ggml-cpu: -U__ARM_FEATURE_SME;-mcpu=neoverse-v2+crc+sve2-aes+sve2-sha3+nossbs+dotprod+i8mm+sve+nosme

We need to explicitly replace `;` with spaces from the list to make
`CMAKE_REQUIRED_FLAGS` work correctly...

Signed-off-by: Adrien Gallouët <redacted>
8 weeks agoHIP: Patch failed testcase in WMMA-MMQ kernels for RDNA 4 (#17502)
Jiacheng (Jason) Chen [Wed, 26 Nov 2025 10:18:48 +0000 (05:18 -0500)]
HIP: Patch failed testcase in WMMA-MMQ kernels for RDNA 4  (#17502)

* patch failed test case MUL_MAT(type_a=q4_0,type_b=f32,m=576,n=512,k=576,bs=[1,1],nr=[1,1],per=[0,1,2,3],k_v=0,o=1) for enabling WMMA on RDNA4

* Quick clean up on mma.cuh to add ggml_cuda_memcpy_1 back in for half2 and bfloat162

8 weeks agoCANN: Add MROPE and IMROPE support (#17401)
hipudding [Wed, 26 Nov 2025 08:44:19 +0000 (16:44 +0800)]
CANN: Add MROPE and IMROPE support (#17401)

* CANN: ROPE supports both MROPE and IMROPE.

1. Optimize the caching logic of rope_cache_init.
2. Add support for mRoPE and i-mRoPE.

Note that on Ascend 910B devices, it is necessary to disable FA
in CLIP and disable NZ-format conversion. These two issues are
still under investigation.

* Resolve review comments

2 months agochore: upgrade cpp-httplib from v0.27.0 to v0.28.0 (#17513)
o7si [Wed, 26 Nov 2025 07:21:06 +0000 (15:21 +0800)]
chore: upgrade cpp-httplib from v0.27.0 to v0.28.0 (#17513)

2 months agovulkan: Implement GGML_OP_CUMSUM (#17479)
Jeff Bolz [Wed, 26 Nov 2025 06:08:10 +0000 (00:08 -0600)]
vulkan: Implement GGML_OP_CUMSUM (#17479)

2 months agoggml : add ggml_top_k (#17365)
Georgi Gerganov [Tue, 25 Nov 2025 13:31:43 +0000 (15:31 +0200)]
ggml : add ggml_top_k (#17365)

* ggml : add ggml_top_k

* cont : add ggml_argsort_top_k

* metal : add top_k support

* ggml : cleanup

* tests : add virtual err() function for test_case

* ggml : add comments

2 months agoconvert : fix big-endian conversion (#17431)
Aleksei Nikiforov [Tue, 25 Nov 2025 13:18:16 +0000 (14:18 +0100)]
convert : fix big-endian conversion (#17431)

* Fix convert_hf_to_gguf.py script on s390x

Assume converted model data is originally little-endian.
Byteswap data on s390x after reading it to put values in correct presentation
for any transformation needed, like calculating weight tensors.

Then byteswap data to little-endian before passing it to GGUFWriter while
GGUFWriter will byteswap data back to big endian if big endian output is requested.

byteswap(inplace=True) calls don't work with lazy tensor and array wrappers.
Use byteswap with copying data to workaround this behaviour.

* Make GGUFWriter accept tensors in native endianness instead of little-endian

With this change if no byteswapping is actually needed, 2 excessive byteswaps can be omitted on s390x

* Fix byteswapping in convert_hf_to_gguf.py for remote models

2 months agocodeowners : remove slaren (#17492)
Diego Devesa [Tue, 25 Nov 2025 12:00:23 +0000 (04:00 -0800)]
codeowners : remove slaren (#17492)

2 months agoCANN: supports out_prod operator for F32 and F16 (#17406)
TianHao324 [Tue, 25 Nov 2025 09:39:06 +0000 (17:39 +0800)]
CANN: supports out_prod operator for F32 and F16 (#17406)

Co-authored-by: tianhao <redacted>
2 months agowebui: add rehype plugin to restore HTML in Markdown table cells (#17477)
Pascal [Tue, 25 Nov 2025 07:01:02 +0000 (08:01 +0100)]
webui: add rehype plugin to restore HTML in Markdown table cells (#17477)

* webui: add rehype plugin to restore HTML in Markdown table cells

The remark/rehype pipeline neutralizes inline HTML as literal text
(remarkLiteralHtml) so that XML/HTML snippets in LLM responses display
as-is instead of being rendered. This causes <br> and <ul> markup in
table cells to show as plain text.

This plugin traverses the HAST post-conversion, parses whitelisted HTML
patterns (<br>, <ul><li>) from text nodes, and replaces them with actual
HAST element nodes. For lists, adjacent siblings must be combined first
as the AST fragmentation breaks pattern matching.

Strict validation rejects malformed markup, keeping it as raw text.

* chore: update webui build output

2 months agovulkan: Use fewer rows for scalar FA when HS is not a multiple of 16 (#17455)
Jeff Bolz [Tue, 25 Nov 2025 06:11:27 +0000 (00:11 -0600)]
vulkan: Use fewer rows for scalar FA when HS is not a multiple of 16 (#17455)

2 months agollama: introduce support for model-embedded sampling parameters (#17120)
Aaron Teo [Tue, 25 Nov 2025 01:56:07 +0000 (09:56 +0800)]
llama: introduce support for model-embedded sampling parameters (#17120)

2 months agovulkan: more FA details in vk_perf_logger (#17443)
Jeff Bolz [Mon, 24 Nov 2025 21:25:24 +0000 (15:25 -0600)]
vulkan: more FA details in vk_perf_logger (#17443)

2 months agollama : skip output reordering for single token batches (#17466)
Daniel Bevenius [Mon, 24 Nov 2025 20:06:17 +0000 (21:06 +0100)]
llama : skip output reordering for single token batches (#17466)

This commit adds a check to skip the output reordering logic when
n_outputs == 1. With a single output token, the data is trivially
sorted and the reordering code is currently doing unnecessary work
(resetting and rebuilding output_ids to the same values).

The motivation for this change is improved code clarity and avoiding
confusion when debugging. While the performance impact is probably
negligible, this unnecessary work happens on every decode call in
llama-server when processing batches with single-token outputs.