Repository navigation
server: (tools) add x-tool-cwd header - #26420
Merged
Merged
Conversation
Contributor
|
The Windows CI failures look like strcasecmp in get_header, it's not available there, I'll test on Windows and confirm when I get a chance: |
ServeurpersoCom
approved these changes
Aug 3, 2026
ServeurpersoCom
left a comment
Contributor
There was a problem hiding this comment.
LGTM: Replacing strcasecmp with the std::transform + std::tolower lowering makes the header lookup fully portable, and I confirmed it builds fine on my physical Windows 11 box.
Small nit, non blocking: server-models.cpp already has its own static to_lower_copy() doing the same thing, so this is a second file-local copy rather than an actual reuse ? Might be worth hoisting a single helper into server-common at some point.
allozaur
approved these changes
Aug 3, 2026
satindergrewal
pushed a commit
to satindergrewal/llama.cpp
that referenced
this pull request
Aug 12, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
brittlewis12
pushed a commit
to brittlewis12/llama.cpp
that referenced
this pull request
Aug 17, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
thecodacus
pushed a commit
to thecodacus/llama.cpp
that referenced
this pull request
Sep 7, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
zbrad
pushed a commit
to zbrad/llama.cpp
that referenced
this pull request
Sep 10, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
pl752
pushed a commit
to pl752/llama.cpp
that referenced
this pull request
Sep 15, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
frostyautumnleaf
pushed a commit
to frostyautumnleaf/llama.cpp
that referenced
this pull request
Oct 5, 2026
* server: (tools) add x-tool-cwd header * reuse str_to_lower from server-models
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Add support for
x-tool-cwdheader to specify the current working dir of the call.Note that it's not a tool param, but is a header. It's meant to be set and managed by the harness (llama-ui). This should match the behavior of pi and claude code.
CC @allozaur
Requirements