-
Notifications
You must be signed in to change notification settings - Fork 273
feat(sdk/cs): add Responses API client for OpenAI/OpenResponses compat #505
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -67,4 +67,13 @@ Task DownloadAsync(Action<float>? downloadProgress = null, | |
| /// <param name="ct">Optional cancellation token.</param> | ||
| /// <returns>OpenAI.AudioClient</returns> | ||
| Task<OpenAIAudioClient> GetAudioClientAsync(CancellationToken? ct = null); | ||
|
|
||
| /// <summary> | ||
| /// Get an OpenAI Responses API client. | ||
| /// Unlike Chat/Audio clients (which use FFI), the Responses API is HTTP-based, | ||
| /// so the web service must be started first via <see cref="FoundryLocalManager.StartWebServiceAsync"/>. | ||
| /// </summary> | ||
| /// <param name="ct">Optional cancellation token.</param> | ||
| /// <returns>OpenAI.ResponsesClient</returns> | ||
| Task<OpenAIResponsesClient> GetResponsesClientAsync(CancellationToken? ct = null); | ||
|
Comment on lines
+71
to
+78
|
||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR adds a new public client + factory (
GetResponsesClient) but there are existing client-focused tests for chat/audio undersdk_v2/cs/test. Consider adding at least basic coverage for the new factory (e.g., throws whenUrlsis null/empty, succeeds afterStartWebServiceAsync) and one smoke test for create/stream parsing so regressions are caught.