block / block/buzz

Agent request fails with context_length_exceeded instead of compacting the conversation

Open
#3,367 1 comment 0 reactions 0 assignees View on GitHub
bug
Dominant language
Rust
Stars
32.7k
Forks
4.3k
Avg merge
1d 13h
Merged PRs (30d)
253

Description

**Describe the bug**

When I send a message in a long-running agent conversation, the request fails because the accumulated input exceeds the model's context window. Buzz shows the raw Responses API error and does not automatically compact or truncate the conversation, retry the request, or provide an obvious recovery action.

**Steps to reproduce**

1. Open an agent conversation in Buzz.
2. Continue the conversation until its accumulated context approaches or exceeds the selected model's context window.
3. Send another message to the agent.
4. See the `context_length_exceeded` error.

**Expected behavior**

Buzz should detect that the conversation is approaching the model's context limit and compact or otherwise reduce the input before submitting the request. If the provider still rejects the request, Buzz should recover gracefully—for example, compact the context and retry—or offer a clear action that lets the user continue without starting a new conversation manually.

**Version and platform**

- Buzz version: 0.5.0
- OS: macOS 26.5.2

**Logs / additional context**

```
Ran into this error: Request failed: Responses API error: Object {"type": String("invalid_request_error"), "code": String("context_length_exceeded"), "message": String("Your input exceeds the context window of this model. Please adjust your input and try again."), "param": String("input")}.
Please retry if you think this is a transient or recoverable error.
```

Image

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.