Skip to content

Commit 6daca91

Browse files
Releasing version ..
Releasing version ..
2 parents 233b772 + e464e84 commit 6daca91

File tree

107 files changed

+5209
-502
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+5209
-502
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66

7+
## 65.95.1 - 2025-07-08
8+
### Added
9+
- Support for insight of Autonomous Database on Exadata Cloud@Customer (ADB on ExaC@C) in the Operations Insights service
10+
- Support for Spanish and Portuguese language recognition with Azure-backed Optical Character Recognition (OCR) in the AI Document service
11+
- Support for UK, Australian, and Canadian address and tax form recognition in the AI Document service
12+
- Support for Personal-to-Corporate conversation check in the OSP Gateway service
13+
714
## 65.95.0 - 2025-07-01
815
### Added
916
- Support for calling Oracle Cloud Infrastructure services in the us-ashburn-2 region

aidocument/aidocument_aiservicedocument_client.go

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -864,6 +864,64 @@ func (client AIServiceDocumentClient) getModel(ctx context.Context, request comm
864864
return response, err
865865
}
866866

867+
// GetModelType Gets model capabilities
868+
//
869+
// # See also
870+
//
871+
// Click https://docs.oracle.com/en-us/iaas/tools/go-sdk-examples/latest/aidocument/GetModelType.go.html to see an example of how to use GetModelType API.
872+
// A default retry strategy applies to this operation GetModelType()
873+
func (client AIServiceDocumentClient) GetModelType(ctx context.Context, request GetModelTypeRequest) (response GetModelTypeResponse, err error) {
874+
var ociResponse common.OCIResponse
875+
policy := common.DefaultRetryPolicy()
876+
if client.RetryPolicy() != nil {
877+
policy = *client.RetryPolicy()
878+
}
879+
if request.RetryPolicy() != nil {
880+
policy = *request.RetryPolicy()
881+
}
882+
ociResponse, err = common.Retry(ctx, request, client.getModelType, policy)
883+
if err != nil {
884+
if ociResponse != nil {
885+
if httpResponse := ociResponse.HTTPResponse(); httpResponse != nil {
886+
opcRequestId := httpResponse.Header.Get("opc-request-id")
887+
response = GetModelTypeResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId}
888+
} else {
889+
response = GetModelTypeResponse{}
890+
}
891+
}
892+
return
893+
}
894+
if convertedResponse, ok := ociResponse.(GetModelTypeResponse); ok {
895+
response = convertedResponse
896+
} else {
897+
err = fmt.Errorf("failed to convert OCIResponse into GetModelTypeResponse")
898+
}
899+
return
900+
}
901+
902+
// getModelType implements the OCIOperation interface (enables retrying operations)
903+
func (client AIServiceDocumentClient) getModelType(ctx context.Context, request common.OCIRequest, binaryReqBody *common.OCIReadSeekCloser, extraHeaders map[string]string) (common.OCIResponse, error) {
904+
905+
httpRequest, err := request.HTTPRequest(http.MethodGet, "/modelTypes/{modelType}", binaryReqBody, extraHeaders)
906+
if err != nil {
907+
return nil, err
908+
}
909+
910+
var response GetModelTypeResponse
911+
var httpResponse *http.Response
912+
httpResponse, err = client.Call(ctx, &httpRequest)
913+
defer common.CloseBodyIfValid(httpResponse)
914+
response.RawResponse = httpResponse
915+
if err != nil {
916+
apiReferenceLink := "https://docs.oracle.com/iaas/api/#/en/document-understanding/20221109/ModelTypeInfo/GetModelType"
917+
err = common.PostProcessServiceError(err, "AIServiceDocument", "GetModelType", apiReferenceLink)
918+
return response, err
919+
}
920+
921+
err = common.UnmarshalResponse(httpResponse, &response)
922+
return response, err
923+
}
924+
867925
// GetProcessorJob Get the details of a processor job.
868926
//
869927
// # See also

aidocument/analyze_document_result.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ type AnalyzeDocumentResult struct {
4343
// The document table extraction model version.
4444
TableExtractionModelVersion *string `mandatory:"false" json:"tableExtractionModelVersion"`
4545

46+
// The document signature extraction model version.
47+
SignatureExtractionModelVersion *string `mandatory:"false" json:"signatureExtractionModelVersion"`
48+
49+
// The document bar code extraction model version.
50+
BarCodeExtractionModelVersion *string `mandatory:"false" json:"barCodeExtractionModelVersion"`
51+
4652
// The errors encountered during document analysis.
4753
Errors []ProcessingError `mandatory:"false" json:"errors"`
4854

aidocument/bar_code.go

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
// Copyright (c) 2016, 2018, 2025, Oracle and/or its affiliates. All rights reserved.
2+
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
3+
// Code generated. DO NOT EDIT.
4+
5+
// Document Understanding API
6+
//
7+
// Document AI helps customers perform various analysis on their documents. If a customer has lots of documents, they can process them in batch using asynchronous API endpoints.
8+
//
9+
10+
package aidocument
11+
12+
import (
13+
"fmt"
14+
"github.com/oracle/oci-go-sdk/v65/common"
15+
"strings"
16+
)
17+
18+
// BarCode A single bar code.
19+
type BarCode struct {
20+
21+
// the confidence score between 0 and 1.
22+
Confidence *float32 `mandatory:"true" json:"confidence"`
23+
24+
// the bar code value.
25+
Value *string `mandatory:"true" json:"value"`
26+
27+
BoundingPolygon *BoundingPolygon `mandatory:"true" json:"boundingPolygon"`
28+
29+
// the encoding schema of bar code.
30+
CodeType *string `mandatory:"false" json:"codeType"`
31+
}
32+
33+
func (m BarCode) String() string {
34+
return common.PointerString(m)
35+
}
36+
37+
// ValidateEnumValue returns an error when providing an unsupported enum value
38+
// This function is being called during constructing API request process
39+
// Not recommended for calling this function directly
40+
func (m BarCode) ValidateEnumValue() (bool, error) {
41+
errMessage := []string{}
42+
43+
if len(errMessage) > 0 {
44+
return true, fmt.Errorf(strings.Join(errMessage, "\n"))
45+
}
46+
return false, nil
47+
}

aidocument/capabilities.go

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
// Copyright (c) 2016, 2018, 2025, Oracle and/or its affiliates. All rights reserved.
2+
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
3+
// Code generated. DO NOT EDIT.
4+
5+
// Document Understanding API
6+
//
7+
// Document AI helps customers perform various analysis on their documents. If a customer has lots of documents, they can process them in batch using asynchronous API endpoints.
8+
//
9+
10+
package aidocument
11+
12+
import (
13+
"fmt"
14+
"github.com/oracle/oci-go-sdk/v65/common"
15+
"strings"
16+
)
17+
18+
// Capabilities Capabilities supported
19+
type Capabilities struct {
20+
21+
// Model information capabilities related to version
22+
Capability map[string]Capability `mandatory:"false" json:"capability"`
23+
}
24+
25+
func (m Capabilities) String() string {
26+
return common.PointerString(m)
27+
}
28+
29+
// ValidateEnumValue returns an error when providing an unsupported enum value
30+
// This function is being called during constructing API request process
31+
// Not recommended for calling this function directly
32+
func (m Capabilities) ValidateEnumValue() (bool, error) {
33+
errMessage := []string{}
34+
35+
if len(errMessage) > 0 {
36+
return true, fmt.Errorf(strings.Join(errMessage, "\n"))
37+
}
38+
return false, nil
39+
}

aidocument/capability.go

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
// Copyright (c) 2016, 2018, 2025, Oracle and/or its affiliates. All rights reserved.
2+
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
3+
// Code generated. DO NOT EDIT.
4+
5+
// Document Understanding API
6+
//
7+
// Document AI helps customers perform various analysis on their documents. If a customer has lots of documents, they can process them in batch using asynchronous API endpoints.
8+
//
9+
10+
package aidocument
11+
12+
import (
13+
"fmt"
14+
"github.com/oracle/oci-go-sdk/v65/common"
15+
"strings"
16+
)
17+
18+
// Capability Capability supported
19+
type Capability struct {
20+
21+
// values
22+
Details []string `mandatory:"false" json:"details"`
23+
}
24+
25+
func (m Capability) String() string {
26+
return common.PointerString(m)
27+
}
28+
29+
// ValidateEnumValue returns an error when providing an unsupported enum value
30+
// This function is being called during constructing API request process
31+
// Not recommended for calling this function directly
32+
func (m Capability) ValidateEnumValue() (bool, error) {
33+
errMessage := []string{}
34+
35+
if len(errMessage) > 0 {
36+
return true, fmt.Errorf(strings.Join(errMessage, "\n"))
37+
}
38+
return false, nil
39+
}

aidocument/create_model_details.go

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,21 @@ type CreateModelDetails struct {
3737
// The model version
3838
ModelVersion *string `mandatory:"false" json:"modelVersion"`
3939

40+
// Applicable to only PRE_TRAINED_KEY_VALUE_EXTRACTION, PRE_TRAINED_DOCUMENT_ELEMENTS_EXTRACTION.
41+
ModelSubType ModelSubType `mandatory:"false" json:"modelSubType"`
42+
43+
// Number of replicas required for this model.
44+
InferenceUnits *int `mandatory:"false" json:"inferenceUnits"`
45+
4046
// Set to true when experimenting with a new model type or dataset, so the model training is quick, with a predefined low number of passes through the training data.
4147
IsQuickMode *bool `mandatory:"false" json:"isQuickMode"`
4248

4349
// The maximum model training time in hours, expressed as a decimal fraction.
4450
MaxTrainingTimeInHours *float64 `mandatory:"false" json:"maxTrainingTimeInHours"`
4551

52+
// The document language for model training, abbreviated according to the BCP 47 syntax.
53+
Language *string `mandatory:"false" json:"language"`
54+
4655
TrainingDataset Dataset `mandatory:"false" json:"trainingDataset"`
4756

4857
TestingDataset Dataset `mandatory:"false" json:"testingDataset"`
@@ -89,8 +98,11 @@ func (m *CreateModelDetails) UnmarshalJSON(data []byte) (e error) {
8998
DisplayName *string `json:"displayName"`
9099
Description *string `json:"description"`
91100
ModelVersion *string `json:"modelVersion"`
101+
ModelSubType modelsubtype `json:"modelSubType"`
102+
InferenceUnits *int `json:"inferenceUnits"`
92103
IsQuickMode *bool `json:"isQuickMode"`
93104
MaxTrainingTimeInHours *float64 `json:"maxTrainingTimeInHours"`
105+
Language *string `json:"language"`
94106
TrainingDataset dataset `json:"trainingDataset"`
95107
TestingDataset dataset `json:"testingDataset"`
96108
ValidationDataset dataset `json:"validationDataset"`
@@ -114,10 +126,24 @@ func (m *CreateModelDetails) UnmarshalJSON(data []byte) (e error) {
114126

115127
m.ModelVersion = model.ModelVersion
116128

129+
nn, e = model.ModelSubType.UnmarshalPolymorphicJSON(model.ModelSubType.JsonData)
130+
if e != nil {
131+
return
132+
}
133+
if nn != nil {
134+
m.ModelSubType = nn.(ModelSubType)
135+
} else {
136+
m.ModelSubType = nil
137+
}
138+
139+
m.InferenceUnits = model.InferenceUnits
140+
117141
m.IsQuickMode = model.IsQuickMode
118142

119143
m.MaxTrainingTimeInHours = model.MaxTrainingTimeInHours
120144

145+
m.Language = model.Language
146+
121147
nn, e = model.TrainingDataset.UnmarshalPolymorphicJSON(model.TrainingDataset.JsonData)
122148
if e != nil {
123149
return

aidocument/detected_document_type.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ type DetectedDocumentType struct {
2323

2424
// The confidence score between 0 and 1.
2525
Confidence *float32 `mandatory:"true" json:"confidence"`
26+
27+
// The OCID (https://docs.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Key-Value Extraction model that was used to extract the key-value pairs.
28+
DocumentId *string `mandatory:"false" json:"documentId"`
2629
}
2730

2831
func (m DetectedDocumentType) String() string {

aidocument/document_classification_feature.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,11 @@ type DocumentClassificationFeature struct {
2222
// The maximum number of results to return.
2323
MaxResults *int `mandatory:"false" json:"maxResults"`
2424

25-
// The custom model ID.
25+
// Unique identifier custom model OCID that should be used for inference.
2626
ModelId *string `mandatory:"false" json:"modelId"`
27+
28+
// The custom model tenancy ID when modelId represents aliasName.
29+
TenancyId *string `mandatory:"false" json:"tenancyId"`
2730
}
2831

2932
func (m DocumentClassificationFeature) String() string {
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
// Copyright (c) 2016, 2018, 2025, Oracle and/or its affiliates. All rights reserved.
2+
// This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
3+
// Code generated. DO NOT EDIT.
4+
5+
// Document Understanding API
6+
//
7+
// Document AI helps customers perform various analysis on their documents. If a customer has lots of documents, they can process them in batch using asynchronous API endpoints.
8+
//
9+
10+
package aidocument
11+
12+
import (
13+
"encoding/json"
14+
"fmt"
15+
"github.com/oracle/oci-go-sdk/v65/common"
16+
"strings"
17+
)
18+
19+
// DocumentElementsExtractionFeature Extract information from bar code
20+
type DocumentElementsExtractionFeature struct {
21+
22+
// Unique identifier custom model OCID that should be used for inference.
23+
ModelId *string `mandatory:"false" json:"modelId"`
24+
}
25+
26+
func (m DocumentElementsExtractionFeature) String() string {
27+
return common.PointerString(m)
28+
}
29+
30+
// ValidateEnumValue returns an error when providing an unsupported enum value
31+
// This function is being called during constructing API request process
32+
// Not recommended for calling this function directly
33+
func (m DocumentElementsExtractionFeature) ValidateEnumValue() (bool, error) {
34+
errMessage := []string{}
35+
36+
if len(errMessage) > 0 {
37+
return true, fmt.Errorf(strings.Join(errMessage, "\n"))
38+
}
39+
return false, nil
40+
}
41+
42+
// MarshalJSON marshals to json representation
43+
func (m DocumentElementsExtractionFeature) MarshalJSON() (buff []byte, e error) {
44+
type MarshalTypeDocumentElementsExtractionFeature DocumentElementsExtractionFeature
45+
s := struct {
46+
DiscriminatorParam string `json:"featureType"`
47+
MarshalTypeDocumentElementsExtractionFeature
48+
}{
49+
"DOCUMENT_ELEMENTS_EXTRACTION",
50+
(MarshalTypeDocumentElementsExtractionFeature)(m),
51+
}
52+
53+
return json.Marshal(&s)
54+
}

0 commit comments

Comments
 (0)