Package com.anthropic.services.async
Interface CompletionServiceAsync
-
- All Implemented Interfaces:
public interface CompletionServiceAsync
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceCompletionServiceAsync.WithRawResponseA view of CompletionServiceAsync that provides access to raw HTTP responses for each method.
-
Method Summary
Modifier and Type Method Description abstract CompletionServiceAsync.WithRawResponsewithRawResponse()Returns a view of this service that provides access to raw HTTP responses for each method. CompletableFuture<Completion>create(CompletionCreateParams params)Legacy Create a Text Completion. abstract CompletableFuture<Completion>create(CompletionCreateParams params, RequestOptions requestOptions)AsyncStreamResponse<Completion>createStreaming(CompletionCreateParams params)Legacy Create a Text Completion. abstract AsyncStreamResponse<Completion>createStreaming(CompletionCreateParams params, RequestOptions requestOptions)-
-
Method Detail
-
withRawResponse
abstract CompletionServiceAsync.WithRawResponse withRawResponse()
Returns a view of this service that provides access to raw HTTP responses for each method.
-
create
CompletableFuture<Completion> create(CompletionCreateParams params)
Legacy Create a Text Completion.
The Text Completions API is a legacy API. We recommend using the Messages API going forward.
Future models and features will not be compatible with Text Completions. See our migration guide for guidance in migrating from Text Completions to Messages.
-
create
abstract CompletableFuture<Completion> create(CompletionCreateParams params, RequestOptions requestOptions)
-
createStreaming
AsyncStreamResponse<Completion> createStreaming(CompletionCreateParams params)
Legacy Create a Text Completion.
The Text Completions API is a legacy API. We recommend using the Messages API going forward.
Future models and features will not be compatible with Text Completions. See our migration guide for guidance in migrating from Text Completions to Messages.
-
createStreaming
abstract AsyncStreamResponse<Completion> createStreaming(CompletionCreateParams params, RequestOptions requestOptions)
-
-
-
-