@Generated(value="OracleSDKGenerator", comments="API Version: 20221001") public class AIServiceLanguageAsyncClient extends BaseAsyncClient implements AIServiceLanguageAsync
Async client implementation for AIServiceLanguage service.
There are two ways to use async client: 1. Use AsyncHandler: using AsyncHandler, if the response
to the call is an InputStream
, like getObject Api in object storage service,
developers need to process the stream in AsyncHandler, and not anywhere else, because the stream
will be closed right after the AsyncHandler is invoked.
2. Use Java Future: using Java Future, developers need to close the stream after they are done
with the Java Future.
Accessing the result should be done in a mutually exclusive manner, either through the Future or
the AsyncHandler, but not both. If the Future is used, the caller should pass in null as the
AsyncHandler. If the AsyncHandler is used, it is still safe to use the Future to determine
whether or not the request was completed via Future.isDone/isCancelled.
Please refer to
https://github.com/oracle/oci-java-sdk/blob/master/bmc-examples/src/main/java/ResteasyClientWithObjectStorageExample.java
Modifier and Type | Class and Description |
---|---|
static class |
AIServiceLanguageAsyncClient.Builder
Builder class for this client.
|
Modifier and Type | Field and Description |
---|---|
String |
clientCommonLibraryVersion
Compatible SDK version, provided by the codegen.
|
Optional<String> |
minimumClientCommonLibraryVersionFromClient
Minimum compatible SDK version, maybe provided by the codegen.
|
static Service |
SERVICE
Service instance for AIServiceLanguage.
|
Constructor and Description |
---|
AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
List<ClientConfigurator> additionalClientConfigurators)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
List<ClientConfigurator> additionalClientConfigurators,
String endpoint)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator,
RequestSignerFactory defaultRequestSignerFactory,
Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories,
List<ClientConfigurator> additionalClientConfigurators,
String endpoint)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration)
Deprecated.
Use the
builder instead. |
AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider,
ClientConfiguration configuration,
ClientConfigurator clientConfigurator)
Deprecated.
Use the
builder instead. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getEndpoint, refreshClient, setEndpoint, useRealmSpecificEndpointTemplate
close
public static final Service SERVICE
Service instance for AIServiceLanguage.
public final String clientCommonLibraryVersion
@Deprecated public AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)@Deprecated public AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
@Deprecated public AIServiceLanguageAsyncClient(BasicAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
clientConfigurator
- ClientBuilderBase.clientConfigurator(com.oracle.bmc.http.ClientConfigurator)
@Deprecated public AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
clientConfigurator
- ClientBuilderBase.clientConfigurator(com.oracle.bmc.http.ClientConfigurator)
defaultRequestSignerFactory
- ClientBuilderBase.requestSignerFactory
@Deprecated public AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, List<ClientConfigurator> additionalClientConfigurators)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
clientConfigurator
- ClientBuilderBase.clientConfigurator(com.oracle.bmc.http.ClientConfigurator)
defaultRequestSignerFactory
- ClientBuilderBase.requestSignerFactory
additionalClientConfigurators
- ClientBuilderBase.additionalClientConfigurators
@Deprecated public AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, List<ClientConfigurator> additionalClientConfigurators, String endpoint)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
clientConfigurator
- ClientBuilderBase.clientConfigurator(com.oracle.bmc.http.ClientConfigurator)
defaultRequestSignerFactory
- ClientBuilderBase.requestSignerFactory
additionalClientConfigurators
- ClientBuilderBase.additionalClientConfigurators
endpoint
- ClientBuilderBase.endpoint(java.lang.String)
@Deprecated public AIServiceLanguageAsyncClient(AbstractAuthenticationDetailsProvider authenticationDetailsProvider, ClientConfiguration configuration, ClientConfigurator clientConfigurator, RequestSignerFactory defaultRequestSignerFactory, Map<SigningStrategy,RequestSignerFactory> signingStrategyRequestSignerFactories, List<ClientConfigurator> additionalClientConfigurators, String endpoint)
builder
instead.Create a new client instance.
authenticationDetailsProvider
- The authentication details (see AIServiceLanguageAsyncClient.Builder.build(com.oracle.bmc.auth.AbstractAuthenticationDetailsProvider)
)configuration
- ClientBuilderBase.configuration
clientConfigurator
- ClientBuilderBase.clientConfigurator(com.oracle.bmc.http.ClientConfigurator)
defaultRequestSignerFactory
- ClientBuilderBase.requestSignerFactory
additionalClientConfigurators
- ClientBuilderBase.additionalClientConfigurators
endpoint
- ClientBuilderBase.endpoint(java.lang.String)
signingStrategyRequestSignerFactories
- ClientBuilderBase.signingStrategyRequestSignerFactories
public static AIServiceLanguageAsyncClient.Builder builder()
Create a builder for this client.
public void setRegion(Region region)
AIServiceLanguageAsync
Sets the region to call (ex, Region.US_PHOENIX_1).
Note, this will call setEndpoint
after resolving the
endpoint. If the service is not available in this region, however, an
IllegalArgumentException will be raised.
setRegion
in interface AIServiceLanguageAsync
region
- The region of the service.public void setRegion(String regionId)
AIServiceLanguageAsync
Sets the region to call (ex, ‘us-phoenix-1’).
Note, this will first try to map the region ID to a known Region and call setRegion
.
If no known Region could be determined, it will create an endpoint based on the default
endpoint format (Region.formatDefaultRegionEndpoint(Service, String)
and then call setEndpoint
.
setRegion
in interface AIServiceLanguageAsync
regionId
- The public region ID.public Future<BatchDetectDominantLanguageResponse> batchDetectDominantLanguage(BatchDetectDominantLanguageRequest request, AsyncHandler<BatchDetectDominantLanguageRequest,BatchDetectDominantLanguageResponse> handler)
AIServiceLanguageAsync
The API returns the detected language and a related confidence score (between 0 and 1). It supports passing a batch of records.
[List of supported languages.](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#lang-detect)
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectDominantLanguage
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectHealthEntityResponse> batchDetectHealthEntity(BatchDetectHealthEntityRequest request, AsyncHandler<BatchDetectHealthEntityRequest,BatchDetectHealthEntityResponse> handler)
AIServiceLanguageAsync
The API extracts health entities in text records. For each entity, its type and confidence score (between 0 and 1) is returned. It supports passing a batch of records.
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectHealthEntity
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectLanguageEntitiesResponse> batchDetectLanguageEntities(BatchDetectLanguageEntitiesRequest request, AsyncHandler<BatchDetectLanguageEntitiesRequest,BatchDetectLanguageEntitiesResponse> handler)
AIServiceLanguageAsync
The API extracts entities in text records. For each entity, its type/subtype and confidence score (between 0 and 1) is returned. It supports passing a batch of records.
[List of supported entities.](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#ner__sup-ner-entity)
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectLanguageEntities
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectLanguageKeyPhrasesResponse> batchDetectLanguageKeyPhrases(BatchDetectLanguageKeyPhrasesRequest request, AsyncHandler<BatchDetectLanguageKeyPhrasesRequest,BatchDetectLanguageKeyPhrasesResponse> handler)
AIServiceLanguageAsync
The API extracts key-phrases in text records. For each key-phrase, a score (between 0 and 1) is returned that highlights the importance of the key-phrase in the context of the text. It supports passing a batch of records.
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectLanguageKeyPhrases
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectLanguagePiiEntitiesResponse> batchDetectLanguagePiiEntities(BatchDetectLanguagePiiEntitiesRequest request, AsyncHandler<BatchDetectLanguagePiiEntitiesRequest,BatchDetectLanguagePiiEntitiesResponse> handler)
AIServiceLanguageAsync
The API extracts pii entities in text records. For each entity, its type and confidence score (between 0 and 1) is returned. It supports passing a batch of records.
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectLanguagePiiEntities
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectLanguageSentimentsResponse> batchDetectLanguageSentiments(BatchDetectLanguageSentimentsRequest request, AsyncHandler<BatchDetectLanguageSentimentsRequest,BatchDetectLanguageSentimentsResponse> handler)
AIServiceLanguageAsync
The API extracts aspect-based and sentence level sentiment in text records.
For aspect-based sentiment analysis, a set of aspects and their respective sentiment is returned for each record. Similarly, for sentence-level sentiment analysis, the sentiment is returned at the sentence level.
For sentiment analysis, confidence scores are provided for each of the classes (positive, negative, neutral and mixed).
Learn more about sentiment analysis [here](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#sentiment).
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectLanguageSentiments
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchDetectLanguageTextClassificationResponse> batchDetectLanguageTextClassification(BatchDetectLanguageTextClassificationRequest request, AsyncHandler<BatchDetectLanguageTextClassificationRequest,BatchDetectLanguageTextClassificationResponse> handler)
AIServiceLanguageAsync
The API automatically classifies text into a set of pre-determined classes and sub-classes. A single class/subclass is returned for each record classified.
It supports passing a batch of records.
Learn more about text classification [here](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#text-class).
Limitations: - A batch may have up to 100 records. - A record may be up to 5000 characters long. - The total of characters to process in a request can be up to 20,000 characters.
batchDetectLanguageTextClassification
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<BatchLanguageTranslationResponse> batchLanguageTranslation(BatchLanguageTranslationRequest request, AsyncHandler<BatchLanguageTranslationRequest,BatchLanguageTranslationResponse> handler)
AIServiceLanguageAsync
Translates a batch of text documents from source to target language. A batch can contain: - up to 100 records. - documents length less than 5000 characters. - 20,000 characters in total as a sum of all documents length.
batchLanguageTranslation
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CancelJobResponse> cancelJob(CancelJobRequest request, AsyncHandler<CancelJobRequest,CancelJobResponse> handler)
AIServiceLanguageAsync
Canceling the job cancels all the tasks under it.
cancelJob
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeEndpointCompartmentResponse> changeEndpointCompartment(ChangeEndpointCompartmentRequest request, AsyncHandler<ChangeEndpointCompartmentRequest,ChangeEndpointCompartmentResponse> handler)
AIServiceLanguageAsync
Moves a Endpoint into a different compartment. When provided, If-Match is checked against ETag values of the resource.
changeEndpointCompartment
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeJobCompartmentResponse> changeJobCompartment(ChangeJobCompartmentRequest request, AsyncHandler<ChangeJobCompartmentRequest,ChangeJobCompartmentResponse> handler)
AIServiceLanguageAsync
Moves a Job into a different compartment. When provided, If-Match is checked against ETag values of the resource.
changeJobCompartment
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeModelCompartmentResponse> changeModelCompartment(ChangeModelCompartmentRequest request, AsyncHandler<ChangeModelCompartmentRequest,ChangeModelCompartmentResponse> handler)
AIServiceLanguageAsync
Moves a Model into a different compartment. When provided, If-Match is checked against ETag values of the resource.
changeModelCompartment
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ChangeProjectCompartmentResponse> changeProjectCompartment(ChangeProjectCompartmentRequest request, AsyncHandler<ChangeProjectCompartmentRequest,ChangeProjectCompartmentResponse> handler)
AIServiceLanguageAsync
Moves a Project into a different compartment. When provided, If-Match is checked against ETag values of the resource.
changeProjectCompartment
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateEndpointResponse> createEndpoint(CreateEndpointRequest request, AsyncHandler<CreateEndpointRequest,CreateEndpointResponse> handler)
AIServiceLanguageAsync
Creates a new endpoint and deploy the trained model
createEndpoint
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateJobResponse> createJob(CreateJobRequest request, AsyncHandler<CreateJobRequest,CreateJobResponse> handler)
AIServiceLanguageAsync
Creates a new language service async job.
createJob
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateModelResponse> createModel(CreateModelRequest request, AsyncHandler<CreateModelRequest,CreateModelResponse> handler)
AIServiceLanguageAsync
Creates a new model for training and train the model with date provided.
createModel
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<CreateProjectResponse> createProject(CreateProjectRequest request, AsyncHandler<CreateProjectRequest,CreateProjectResponse> handler)
AIServiceLanguageAsync
Creates a new Project.
createProject
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteEndpointResponse> deleteEndpoint(DeleteEndpointRequest request, AsyncHandler<DeleteEndpointRequest,DeleteEndpointResponse> handler)
AIServiceLanguageAsync
Deletes a provisioned endpoint resource by identifier. This operation fails with a 409 error unless all associated resources are in a DELETED state. You must delete all associated resources before deleting a model.
deleteEndpoint
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteJobResponse> deleteJob(DeleteJobRequest request, AsyncHandler<DeleteJobRequest,DeleteJobResponse> handler)
AIServiceLanguageAsync
Deletes the language service async Job
deleteJob
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteModelResponse> deleteModel(DeleteModelRequest request, AsyncHandler<DeleteModelRequest,DeleteModelResponse> handler)
AIServiceLanguageAsync
Deletes a provisioned model resource by identifier. This operation fails with a 409 error unless all associated resources are in a DELETED state. You must delete all associated resources before deleting a model.
deleteModel
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DeleteProjectResponse> deleteProject(DeleteProjectRequest request, AsyncHandler<DeleteProjectRequest,DeleteProjectResponse> handler)
AIServiceLanguageAsync
Deletes a Project resource by identifier. This operation fails with a 409 error unless all associated resources (models deployments or data assets) are in a DELETED state. You must delete all associated resources before deleting a project.
deleteProject
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DetectDominantLanguageResponse> detectDominantLanguage(DetectDominantLanguageRequest request, AsyncHandler<DetectDominantLanguageRequest,DetectDominantLanguageResponse> handler)
AIServiceLanguageAsync
Deprecated: This API will be retired Tuesday, 10 Oct 2023 00:00:00 GMT. We recommend you replace this API with the batch API, BatchDetectDominantLanguage.
The DetectDominantLanguage API returns the detected language and a related confidence score (between 0 and 1).
[List of supported languages](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#lang-detect)
Limitations: - A record may be up to 1000 characters long.
detectDominantLanguage
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DetectLanguageEntitiesResponse> detectLanguageEntities(DetectLanguageEntitiesRequest request, AsyncHandler<DetectLanguageEntitiesRequest,DetectLanguageEntitiesResponse> handler)
AIServiceLanguageAsync
Deprecated: This API will be retired Tuesday, 10 Oct 2023 00:00:00 GMT. We recommend you replace this API with the batch API, BatchDetectLanguageEntities.
The DetectLanguageEntities API extracts entities in text records. For each entity, its type and confidence score (between 0 and 1) is returned.
Limitations: - A text may be up to 1000 characters long.
detectLanguageEntities
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DetectLanguageKeyPhrasesResponse> detectLanguageKeyPhrases(DetectLanguageKeyPhrasesRequest request, AsyncHandler<DetectLanguageKeyPhrasesRequest,DetectLanguageKeyPhrasesResponse> handler)
AIServiceLanguageAsync
Deprecated: This API will be retired Tuesday, 10 Oct 2023 00:00:00 GMT. We recommend you replace this API with the batch API, BatchDetectLanguageKeyPhrases.
The DetectLanguageKeyPhrases API extracts key-phrases in text records. For each key-phrase, a score (between 0 and 1) is returned that highlights the importance of the key-phrase in the context of the text. Limitations: - A record may be up to 1000 characters long.
detectLanguageKeyPhrases
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DetectLanguageSentimentsResponse> detectLanguageSentiments(DetectLanguageSentimentsRequest request, AsyncHandler<DetectLanguageSentimentsRequest,DetectLanguageSentimentsResponse> handler)
AIServiceLanguageAsync
Deprecated: This API will be retired Tuesday, 10 Oct 2023 00:00:00 GMT. We recommend you replace this API with the batch API, BatchDetectLanguageSentiments.
The DetectLanguageSentiments API extracts aspect-based in text records.
For aspect-based sentiment analysis, a set of aspects and their respective sentiment is returned.
For sentiment analysis, confidence scores are provided for each of the classes (positive, negative, neutral).
Learn more about sentiment analysis [here](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#sentiment).
Limitations: - A record may be up to 1000 characters long.
detectLanguageSentiments
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<DetectLanguageTextClassificationResponse> detectLanguageTextClassification(DetectLanguageTextClassificationRequest request, AsyncHandler<DetectLanguageTextClassificationRequest,DetectLanguageTextClassificationResponse> handler)
AIServiceLanguageAsync
Deprecated: This API will be retired Tuesday, 10 Oct 2023 00:00:00 GMT. We recommend you replace this API with the batch API, BatchDetectLanguageTextClassification.
The DetectLanguageTextClassification API automatically classifies text into a set of pre-determined classes and sub-classes. A single class/subclass is returned for each record classified.
Learn more about text classification [here](https://docs.cloud.oracle.com/iaas/language/using/pretrain-models.htm#text-class).
Limitations: - A record may be up to 1000 characters long.
detectLanguageTextClassification
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetEndpointResponse> getEndpoint(GetEndpointRequest request, AsyncHandler<GetEndpointRequest,GetEndpointResponse> handler)
AIServiceLanguageAsync
Gets an endpoint by identifier
getEndpoint
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetJobResponse> getJob(GetJobRequest request, AsyncHandler<GetJobRequest,GetJobResponse> handler)
AIServiceLanguageAsync
Gets a language service async job
getJob
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetModelResponse> getModel(GetModelRequest request, AsyncHandler<GetModelRequest,GetModelResponse> handler)
AIServiceLanguageAsync
Gets a model by identifier
getModel
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetModelTypeResponse> getModelType(GetModelTypeRequest request, AsyncHandler<GetModelTypeRequest,GetModelTypeResponse> handler)
AIServiceLanguageAsync
Gets model capabilities
getModelType
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetProjectResponse> getProject(GetProjectRequest request, AsyncHandler<GetProjectRequest,GetProjectResponse> handler)
AIServiceLanguageAsync
Gets a Project by identifier
getProject
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<GetWorkRequestResponse> getWorkRequest(GetWorkRequestRequest request, AsyncHandler<GetWorkRequestRequest,GetWorkRequestResponse> handler)
AIServiceLanguageAsync
Gets the status of the work request with the given ID.
getWorkRequest
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListEndpointsResponse> listEndpoints(ListEndpointsRequest request, AsyncHandler<ListEndpointsRequest,ListEndpointsResponse> handler)
AIServiceLanguageAsync
Returns a list of Endpoints.
listEndpoints
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListEvaluationResultsResponse> listEvaluationResults(ListEvaluationResultsRequest request, AsyncHandler<ListEvaluationResultsRequest,ListEvaluationResultsResponse> handler)
AIServiceLanguageAsync
Get a (paginated) list of evaluation results for a given model.
listEvaluationResults
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListJobsResponse> listJobs(ListJobsRequest request, AsyncHandler<ListJobsRequest,ListJobsResponse> handler)
AIServiceLanguageAsync
Returns a list of language service async Jobs.
listJobs
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListModelsResponse> listModels(ListModelsRequest request, AsyncHandler<ListModelsRequest,ListModelsResponse> handler)
AIServiceLanguageAsync
Returns a list of models.
listModels
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListProjectsResponse> listProjects(ListProjectsRequest request, AsyncHandler<ListProjectsRequest,ListProjectsResponse> handler)
AIServiceLanguageAsync
Returns a list of Projects.
listProjects
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestErrorsResponse> listWorkRequestErrors(ListWorkRequestErrorsRequest request, AsyncHandler<ListWorkRequestErrorsRequest,ListWorkRequestErrorsResponse> handler)
AIServiceLanguageAsync
Return a (paginated) list of errors for a given work request.
listWorkRequestErrors
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestLogsResponse> listWorkRequestLogs(ListWorkRequestLogsRequest request, AsyncHandler<ListWorkRequestLogsRequest,ListWorkRequestLogsResponse> handler)
AIServiceLanguageAsync
Return a (paginated) list of logs for a given work request.
listWorkRequestLogs
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<ListWorkRequestsResponse> listWorkRequests(ListWorkRequestsRequest request, AsyncHandler<ListWorkRequestsRequest,ListWorkRequestsResponse> handler)
AIServiceLanguageAsync
Lists the work requests in a compartment.
listWorkRequests
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateEndpointResponse> updateEndpoint(UpdateEndpointRequest request, AsyncHandler<UpdateEndpointRequest,UpdateEndpointResponse> handler)
AIServiceLanguageAsync
Update the Endpoint identified by the id
updateEndpoint
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateJobResponse> updateJob(UpdateJobRequest request, AsyncHandler<UpdateJobRequest,UpdateJobResponse> handler)
AIServiceLanguageAsync
Updates the language service async Job
updateJob
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateModelResponse> updateModel(UpdateModelRequest request, AsyncHandler<UpdateModelRequest,UpdateModelResponse> handler)
AIServiceLanguageAsync
Updates the model
updateModel
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.public Future<UpdateProjectResponse> updateProject(UpdateProjectRequest request, AsyncHandler<UpdateProjectRequest,UpdateProjectResponse> handler)
AIServiceLanguageAsync
Updates the Project
updateProject
in interface AIServiceLanguageAsync
request
- The request object containing the details to sendhandler
- The request handler to invoke upon completion, may be null.protected ClientConfigurator getDefaultConfigurator()
public void useRealmSpecificEndpointTemplate(boolean useOfRealmSpecificEndpointTemplateEnabled)
useOfRealmSpecificEndpointTemplateEnabled
- This flag can be set to true or false to
enable or disable the use of realm-specific endpoint template respectivelypublic final void populateServiceParametersInEndpoint(String endpoint, Map<String,Object> requiredParametersMap)
endpoint
- The endpoint template in userequiredParametersMap
- Map of parameter name as key and value set in request path or
query parameter as valuepublic final void updateBaseEndpoint(String endpoint)
endpoint
- The updated endpoint to usepublic final void setEndpoint(String endpoint)
public final String getEndpoint()
public final void refreshClient()
HttpClient
. This will call ClientConfigurator
s again, and
can be used to e.g. refresh the SSL certificate.public final void close()
close
in interface AutoCloseable
public String getClientCommonLibraryVersion()
public Optional<String> getMinimumClientCommonLibraryVersionFromClient()
protected <REQ extends BmcRequest<?>,RESP extends BmcResponse,RESP_BUILDER extends BmcResponse.Builder<RESP>> ClientCall<REQ,RESP,RESP_BUILDER> clientCall(REQ request, Supplier<RESP_BUILDER> responseBuilder)
Copyright © 2016–2024. All rights reserved.