zed-industries/zed · error · LanguageModelCompletionError
does not support explicit compaction
Error message
{provider} does not support explicit compaction What it means
Default trait-method guard in LanguageModel::compact: the base implementation always fails because a provider that hasn't overridden supports_explicit_compaction/compact does not implement provider-side explicit compaction. Calling compact on such a model (via {provider}) is a programming/configuration error — the caller should have checked supports_explicit_compaction first. Sentinel: fires whenever compact is invoked on a model whose provider uses the default trait implementation.
Solutions
- Check `supports_explicit_compaction()` before calling compact and skip or use client-side compaction instead
- Implement compact on the provider if it should support explicit compaction
- Choose a model that supports explicit compaction for workflows that require it
Defensive patterns
Strategy: fallback
When it happens
Trigger: Thrown at crates/language_model/src/language_model.rs:160 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of zed-industries/zed@916fc2b8cb (2026-08-20).
Data as JSON: /api/errors/fa15490e51a3ffaa.
Report an issue: GitHub.
Appendix: source
Thrown at crates/language_model/src/language_model.rs:160
/// models (e.g. Claude Fable 5) always think and cannot honor an "off"
/// request. Only meaningful when `supports_thinking` returns `true`.
fn supports_disabling_thinking(&self) -> bool {
true
}
fn supports_fast_mode(&self) -> bool {
false
}
/// Returns the list of supported effort levels that can be used when thinking.
fn supported_effort_levels(&self) -> Vec<LanguageModelEffortLevel> {
Vec::new()
}
/// Returns the default effort level to use when thinking.
fn default_effort_level(&self) -> Option<LanguageModelEffortLevel> {
self.supported_effort_levels()
.into_iter()
.find(|effort_level| effort_level.is_default)
}
/// Whether this model supports provider-side automatic context
/// compaction (requested via `LanguageModelRequest::compact_at_tokens`).
fn supports_server_side_compaction(&self) -> bool {
false
}
fn supports_explicit_compaction(&self) -> bool {
false
}
/// Whether native compaction honors `LanguageModelRequest::max_output_tokens`.
fn supports_explicit_compaction_output_limit(&self) -> bool {
false
}
View on GitHub (pinned to 916fc2b8cb)