Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
df335aac
Unverified
Commit
df335aac
authored
Aug 15, 2025
by
Michael Yang
Committed by
GitHub
Aug 15, 2025
Browse files
gpt-oss: disable quantized kv cache (#11929)
parent
026bc292
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
fs/ggml/ggml.go
fs/ggml/ggml.go
+5
-0
No files found.
fs/ggml/ggml.go
View file @
df335aac
...
@@ -752,6 +752,11 @@ func (llm GGML) VisionGraphSize() (weights, graphSize uint64) {
...
@@ -752,6 +752,11 @@ func (llm GGML) VisionGraphSize() (weights, graphSize uint64) {
// SupportsKVCacheType checks if the requested cache type is supported
// SupportsKVCacheType checks if the requested cache type is supported
func
(
f
GGML
)
SupportsKVCacheType
(
cacheType
string
)
bool
{
func
(
f
GGML
)
SupportsKVCacheType
(
cacheType
string
)
bool
{
if
arch
:=
f
.
KV
()
.
Architecture
();
slices
.
Contains
([]
string
{
"gptoss"
,
"gpt-oss"
},
arch
)
{
// gpt-oss uses attention with sinks which does not support quantized cache types
slog
.
Warn
(
"model only supports non-quantized cache types "
,
"mode"
,
arch
)
return
cacheType
==
"f16"
}
return
slices
.
Contains
([]
string
{
"f16"
,
"q8_0"
,
"q4_0"
},
cacheType
)
return
slices
.
Contains
([]
string
{
"f16"
,
"q8_0"
,
"q4_0"
},
cacheType
)
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment