Repository navigation
chore: sync fantasy with upstream v0.45.5 - #31288
Merged
Merged
Conversation
Pin coder/fantasy coder_2_33 at 85ffbbe (coder/fantasy#72), which merges charmbracelet/fantasy v0.45.5. go mod tidy raises the modules fantasy now requires. Claude 5 thinking now defaults to display summarized when the chat config sets none, so the drop_block retry body carries it.
Fantasy now forwards Anthropic message_start, message_delta and unknown events as content-free keepalive parts. The first one arrives before any model output, so counting it closed the TTFT window early.
Contributor
Docs previewCheck off each page once it's been reviewed. If a page changes in a later push, its checkbox clears automatically so it gets a fresh look. Pages not yet wired into the docs navigation aren't listed here. |
ethanndickson
approved these changes
Oct 27, 2026
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Moves the fantasy pin to the tip of
coder_2_33(85ffbbe). That commit is coder/fantasy#72, which merges 87 upstream charmbracelet/fantasy commits, v0.40.0 to v0.45.5. Between the two pins 117 files change. Upstream's own v0.40.0 to v0.45.5 change, without tests, testdata, examples,go.sumand the kronk provider, is 43 files, +2271/−928.What reaches chatd
chatd builds only the
anthropic,openaiandopenaicompatfantasy clients (chatprovider.ModelFromConfig); other vendors reach it through the AI Gateway on one of those. So the upstream changes to the Google, Vercel, OpenRouter, Bedrock, Azure and kronk providers, and to thefantasy.Agentloop and its retries, do not run in chatd. These do:finish_reason: lengthwhen tool calls are truncated, and stop sending empty reasoning fields. openaicompat drops assistant turns that hold only reasoning.ContextTooLargeErr, which compaction acts on.display: "summarized"when the chat config sets none; a configured display still wins.TestThinkingDropBlockModel_RetriesWithEffortnow expects the field in the retry body.message_start,message_deltaand unknown events as content-freekeepaliveparts. The first one arrives before any model output, so this PR makesttft_secondsand thetime_to_first_tokenstage skip them, as they skip warnings. They still reset the stream silence guard.processStepStreamignores them, and the debug recorder counts them in its part count but records no content.ToolRunBuffer, which replaces fix(providers): keep tool batches ahead of media messages fantasy#64 and does the same thing.#72 keeps coder's anthropic-sdk-go and openai-go forks, Go 1.26 and kronk v1.31.5, so upstream's SDK and Go moves do not come along.
go mod tidyraises the modules fantasy v0.45.5 requires, among them otel exporters v1.47, the AWS SDK,google.golang.org/apiv0.307 and go-openapi v1. All are upgrades.The
go.modcomment now names #72 as the upstream sync.#29861 stacks on this PR to pin coder/fantasy#62.
Verification
go build ./....go testpasses on every package that imports fantasy (coderd/x/chatd/...), andgo test ./coderd -run 'TestChat|TestExpChat|TestMCP|TestAIBridge'passes.TestGuardedStreamTTFTStage/WarningsAndKeepalivesThenContentObservesOncefails without the TTFT change (TTFT observed 0s instead of 1s) and passes with it.make pre-commitpasses. The generated Prometheus docs pick up the metric help change.Not verified against live backends in this PR: the stream fixes, the token usage change and the context-overflow patterns have no coder test against a real provider. coder/fantasy#72 reports a local chatd run against the AI Gateway on Anthropic, Responses, OpenAI Chat and openaicompat.