Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 1 addition & 11 deletions providers/openai/responses_language_model.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package openai
import (
"context"
"encoding/base64"
"encoding/json"
"errors"
"fmt"
"io"
Expand Down Expand Up @@ -551,16 +550,7 @@ func toResponsesPrompt(prompt fantasy.Prompt, systemMessageMode string, store bo
continue
}

inputJSON, err := json.Marshal(toolCallPart.Input)
if err != nil {
warnings = append(warnings, fantasy.CallWarning{
Type: fantasy.CallWarningTypeOther,
Message: fmt.Sprintf("failed to marshal tool call input: %v", err),
})
continue
}

input = append(input, responses.ResponseInputItemParamOfFunctionCall(string(inputJSON), toolCallPart.ToolCallID, toolCallPart.ToolName))
input = append(input, responses.ResponseInputItemParamOfFunctionCall(toolCallPart.Input, toolCallPart.ToolCallID, toolCallPart.ToolName))
case fantasy.ContentTypeSource:
// Source citations from web search are not a
// recognised Responses API input type; skip.
Expand Down
14 changes: 0 additions & 14 deletions providertests/azure_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ func TestAzureCommon(t *testing.T) {
testCommon(t, []builderPair{
{"azure-o4-mini", builderAzureO4Mini, nil, nil},
{"azure-gpt-5-mini", builderAzureGpt5Mini, nil, nil},
{"azure-grok-3-mini", builderAzureGrok3Mini, nil, nil},
})
}

Expand All @@ -31,7 +30,6 @@ func TestAzureThinking(t *testing.T) {
}
testThinking(t, []builderPair{
{"azure-gpt-5-mini", builderAzureGpt5Mini, opts, nil},
{"azure-grok-3-mini", builderAzureGrok3Mini, opts, nil},
}, testAzureThinking)
}

Expand Down Expand Up @@ -62,15 +60,3 @@ func builderAzureGpt5Mini(t *testing.T, r *vcr.Recorder) (fantasy.LanguageModel,
}
return provider.LanguageModel(t.Context(), "gpt-5-mini")
}

func builderAzureGrok3Mini(t *testing.T, r *vcr.Recorder) (fantasy.LanguageModel, error) {
provider, err := azure.New(
azure.WithBaseURL(cmp.Or(os.Getenv("FANTASY_AZURE_BASE_URL"), defaultBaseURL)),
azure.WithAPIKey(cmp.Or(os.Getenv("FANTASY_AZURE_API_KEY"), "(missing)")),
azure.WithHTTPClient(&http.Client{Transport: r}),
)
if err != nil {
return nil, err
}
return provider.LanguageModel(t.Context(), "grok-3-mini")
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading