Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
103 commits
Select commit Hold shift + click to select a range
514e049
feat(openai): add WebSocket mode for Responses API
taigrr Feb 24, 2026
e6ec3d0
feat(ws): send only incremental input when chaining with previous_res…
taigrr Feb 24, 2026
0f2292d
fix(ws): handle response.failed events, fix goroutine leak, use mapRe…
taigrr Feb 24, 2026
0fa62dd
fix(openai): close response body from websocket dial and check conn.C…
taigrr Feb 24, 2026
146da14
fix(openai): check error returns for resp.Body.Close and SetReadDeadline
taigrr Feb 24, 2026
e6144a7
Merge pull request #1 from taigrr/cd/websocket-mode
taigrr Feb 24, 2026
7a27ae7
add reset options
taigrr Feb 25, 2026
7d07908
feat: detect context-too-large errors (#125)
mhpenta Feb 24, 2026
e65f95b
feat(google): add ThinkingLevel support for Gemini 3+ models
xcapaldi Feb 13, 2026
e9fd45c
test: unify gemini 2 and gemini 3 thinking tests
andreynering Feb 24, 2026
db52756
lint: fix missing doc comment
andreynering Feb 24, 2026
957ab62
v0.10.0
andreynering Feb 24, 2026
45f0851
feat: add support for anthropic thinking effort (#147)
kylecarbs Feb 26, 2026
9325620
chore(deps): bump the all group with 4 updates (#150)
dependabot[bot] Feb 26, 2026
fc1a6bc
v0.11.0
andreynering Feb 26, 2026
da00ad1
chore(deps): bump github.com/ardanlabs/kronk in the all group (#153)
dependabot[bot] Feb 27, 2026
5189616
chore(deps): bump the all group with 3 updates (#155)
dependabot[bot] Mar 2, 2026
89b6447
chore: add support for gpt 5.4 (#158)
andreynering Mar 5, 2026
6e69781
v0.11.1
andreynering Mar 5, 2026
d90177e
chore(deps): go mod tidy examples (#159)
meowgorithm Mar 6, 2026
5e78629
feat: configurable user-agent (#152)
meowgorithm Mar 10, 2026
e5dbe60
v0.12.0
andreynering Mar 10, 2026
918be9e
ci: fix govulncheck by updating go version (#161)
andreynering Mar 10, 2026
fba2de6
ci(dependabot): update kronk in a separate group
andreynering Mar 10, 2026
bda9495
chore(deps): bump the all group across 1 directory with 4 updates (#162)
dependabot[bot] Mar 10, 2026
31bc70a
fix(errors): improve check for when to retry requests (#164)
andreynering Mar 11, 2026
fe88fc8
chore(examples): go mod tidy
andreynering Mar 11, 2026
d3ed84b
v0.12.1
andreynering Mar 11, 2026
0b07afb
fix(openrouter): don't set User-Agent
meowgorithm Mar 12, 2026
8ef696b
fix(openai): don't mutate shared languageModelOptions
meowgorithm Mar 12, 2026
8e3b3b7
docs(openai): correct grammar in comment
meowgorithm Mar 12, 2026
5210915
fix(openrouter): avoid brittle User-Agent assertion
meowgorithm Mar 12, 2026
975cd2f
fix(openai): propagate noDefaultUserAgent to responsesLanguageModel
meowgorithm Mar 12, 2026
387d621
fix(openai): use noDefaultUserAgent in all responses API calls
meowgorithm Mar 12, 2026
c9b2a2f
fix: improve default user-agent string
andreynering Mar 12, 2026
cdb6b9e
fix: guard against nil EncryptedContent dereference in reasoning details
andreynering Mar 12, 2026
170cacd
fix(openrouter): preserve anthropic reasoning signature in streaming
andreynering Mar 12, 2026
5a7ccce
test: re-record all openrouter fixtures
andreynering Mar 12, 2026
a8626b1
v0.12.2
andreynering Mar 12, 2026
9330a85
test: re-record almost all fixtures (#167)
andreynering Mar 12, 2026
86a7eb3
chore: update openai sdk to v3 (#168)
andreynering Mar 13, 2026
e03fd77
v0.12.3
andreynering Mar 13, 2026
0d312fd
chore(deps): bump the all group with 4 updates (#171)
dependabot[bot] Mar 16, 2026
0292804
feat: add Anthropic web search tool support (server_tool_use + web_se…
kylecarbs Mar 10, 2026
330fdfc
fix(agent): make per-step tool selection apply to all tool types
meowgorithm Mar 15, 2026
c1fc151
chore(anthroipic): harden web_search coercion for json round-trips
meowgorithm Mar 15, 2026
6debb44
fix(lint): guard against overflow
meowgorithm Mar 16, 2026
65c229f
docs(agents): minor AGENTS.md updates
meowgorithm Mar 15, 2026
763eaf5
feat(openai): add web search tool support for Responses API (#173)
kylecarbs Mar 17, 2026
b63b5f9
chore: delete duplicated example
andreynering Mar 17, 2026
5af4a5d
docs(readme): remove experimental note + provider tools is now supported
andreynering Mar 17, 2026
c7f2820
v0.13.0
andreynering Mar 17, 2026
192bcaa
chore(deps): bump github.com/ardanlabs/kronk in the kronk group
dependabot[bot] Mar 16, 2026
cb2a602
fix: address kronk api change
andreynering Mar 17, 2026
d6e3c61
chore: add support for gpt 5.4 mini and nano (#174)
andreynering Mar 17, 2026
7bdf4f9
v0.13.1
andreynering Mar 17, 2026
af27be4
feat(openai): add responses api `store`, `previous_response_id`, and …
ibetitsmike Mar 18, 2026
cd874c6
fix(openai): subtract cached tokens from input tokens to avoid double…
andreynering Mar 18, 2026
e900e76
v0.14.0
andreynering Mar 18, 2026
697f597
fix(anthropic): anthropic with vertex works with service account json…
Cali0707 Mar 18, 2026
5349ae5
fix(anthropic): ToolChoiceNone should send tool_choice:{type:"none"} …
andreynering Mar 18, 2026
a16efe9
feat: support `text/*` files (#100)
caarlos0 Mar 18, 2026
527e7e7
feat(agent): allow empty prompt when messages exist (#179)
andreynering Mar 18, 2026
137e6f2
v0.15.0
andreynering Mar 18, 2026
15d31ed
fix: migrate the openai sdk to our internal fork
andreynering Mar 19, 2026
fa158fa
test: add integration tests for avian
andreynering Mar 19, 2026
2b83e6b
fix(openai): skip reasoning items in Responses API replay (#181)
kylecarbs Mar 19, 2026
8864f5d
chore: revert change to skip user-agent for openrouter
andreynering Mar 13, 2026
7096027
chore: remove unused test function
andreynering Mar 19, 2026
ed15ae0
test(openrouter): simplify list of providers and models to test
andreynering Mar 19, 2026
a3d5297
test: re-record openrouter fixtures
andreynering Mar 19, 2026
518db5e
v0.15.1
andreynering Mar 19, 2026
ed1706c
fix(providers/openai): skip ephemeral replay items
ibetitsmike Mar 20, 2026
442947f
fix(providertests/testdata): update summary thinking fixtures
ibetitsmike Mar 20, 2026
3b61c38
feat(bedrock): add WithBaseURL option
aleksclark Mar 12, 2026
098d489
fix(bedrock): apply base URL override after bedrock.WithConfig
aleksclark Mar 12, 2026
03018fa
fix(bedrock): don't default baseURL to anthropic API when using bedrock
aleksclark Mar 13, 2026
673e52e
fix: address tool calls with empty arguments in copilot (#156)
mavaa Mar 20, 2026
cf6de3b
fix(openai): relax tool call validation for ollama compatibility (#113)
Gustave-241021 Mar 20, 2026
3a557bb
v0.16.0
andreynering Mar 20, 2026
027ee6d
chore(deps): bump the all group with 2 updates (#183)
dependabot[bot] Mar 23, 2026
c57f854
chore(deps): bump github.com/ardanlabs/kronk in the kronk group (#184)
dependabot[bot] Mar 23, 2026
9257bd7
feat: anthropic computer use (#185)
hugodutka Mar 24, 2026
cdc63d4
chore(examples): go mod tidy
andreynering Mar 24, 2026
b9a2379
v0.17.0
andreynering Mar 24, 2026
f1f033f
fix(providers/openai): emit source parts for Responses API streaming …
kylecarbs Mar 25, 2026
1a6362c
chore: run modernize (#188)
andreynering Mar 25, 2026
bc19673
chore(openai): add missing constants and checks for some thinking eff…
ibetitsmike Mar 25, 2026
21dca66
v0.17.1
andreynering Mar 25, 2026
de6d0da
chore(deps): bump the all group with 5 updates (#190)
dependabot[bot] Mar 30, 2026
5b4ee6c
chore(deps): bump the all group with 3 updates (#193)
dependabot[bot] Apr 6, 2026
238bbb2
chore(deps): bump github.com/ardanlabs/kronk in the kronk group (#194)
dependabot[bot] Apr 6, 2026
9c89dc8
chore: add `CODEOWNERS` to ask review from me
andreynering Apr 10, 2026
cb8aab2
chore(deps): bump the all group with 2 updates (#199)
dependabot[bot] Apr 13, 2026
329432d
chore(deps): bump github.com/ardanlabs/kronk in the kronk group (#200)
dependabot[bot] Apr 13, 2026
11210b4
ci: fix govulncheck by updating to go 1.26.2 (#201)
andreynering Apr 13, 2026
7b257a3
fix(agent): buffer tool calls
meowgorithm Apr 13, 2026
e14a63d
chore(agent): move tool execution after stream loop + add test
meowgorithm Apr 13, 2026
6ad48c4
v0.17.2
meowgorithm Apr 13, 2026
b9e9bf2
feat(openai): add WebSocket mode for Responses API
taigrr Feb 24, 2026
77346d4
add reset options
taigrr Feb 25, 2026
3c988d0
fixup some of the tool call response errors
taigrr Apr 25, 2026
047cd5d
remove var
taigrr Apr 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @andreynering
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ updates:
all:
patterns:
- "*"
exclude-patterns:
- github.com/ardanlabs/kronk
kronk:
patterns:
- github.com/ardanlabs/kronk


- package-ecosystem: "gomod"
directory: "/examples"
Expand Down
29 changes: 29 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Fantasy Development Guide

## Commands

- **Build**: `go build ./...`
- **Test all**: `task test` or `go test ./... -count=1 -timeout=30m`
- **Test single**: `go test -run TestName ./package -v`
- **Lint**: `task lint` or `golangci-lint run`
- **Lint fix**: `task lint:fix`
- **Format**: `task fmt` (uses `gofumpt`, not `gofmt`)

## Style Notes

- Prefer `cmp.Or` for defaults
- Struct tags `json`, `description`, `enum` drive schema generation
- `charm.land/x/vcr` for HTTP test recording (not go-vcr)

## Project Layout

- `/` — Core package `fantasy`: Provider, LanguageModel, Agent, Content, Tool, errors, retry
- `/providers/{openai,anthropic,google,bedrock,azure,openrouter,openaicompat,vercel,kronk}`
- `/object` — Typed structured outputs: `object.Generate[T]`, `object.Stream[T]`
- `/schema`, `/jsonrepair` — JSON schema generation and repair utilities
- `/providertests` — Integration tests with VCR cassettes in `testdata/`

## Testing

- Env vars: `FANTASY_<PROVIDER>_API_KEY`, loaded from `.env` via godotenv
- VCR recorder injected as `http.Client` transport
29 changes: 0 additions & 29 deletions CRUSH.md

This file was deleted.

3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ Build AI agents with Go. Multi-provider, multi-model, one API.
2. Add some tools
3. Compile to native machine code and let it rip

> [!NOTE]
> Fantasy is currently a preview. Expect API changes.

```go
import "charm.land/fantasy"
Expand Down Expand Up @@ -73,7 +71,6 @@ We built Fantasy to power [Crush](https://github.com/charmbracelet/crush), a hot
- Image models
- Audio models
- PDF uploads
- Provider tools (e.g. web_search)

For things you’d like to see supported, PRs are welcome.

Expand Down
6 changes: 4 additions & 2 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ tasks:
test:
desc: Run tests for all packages
cmds:
- go test ./... -count=1 {{.CLI_ARGS}}
- go test ./... -count=1 -timeout=30m {{.CLI_ARGS}}
release:
desc: Create and push a new tag following semver
vars:
Expand All @@ -37,7 +37,9 @@ tasks:
- sh: "[ $(git status --porcelain=2 | wc -l) = 0 ]"
msg: "Git is dirty"
cmds:
- git commit --allow-empty -m "{{.NEXT}}"
- echo {{trimPrefix "v" .NEXT}} > version.txt
- git add version.txt
- git commit -m "{{.NEXT}}"
- git tag --annotate --sign -m "{{.NEXT}}" {{.NEXT}} {{.CLI_ARGS}}
- echo "Pushing {{.NEXT}}..."
- git push origin main --follow-tags
Loading