Skip to content

Commit

Permalink
feat(vision): Added option for user to set labels (#9359)
Browse files Browse the repository at this point in the history
- [ ] Regenerate this pull request now.

docs: Updated various comments
chore: configure longrunning operations

PiperOrigin-RevId: 604671304

Source-Link: https://togithub.com/googleapis/googleapis/commit/f4c047f491294628d60be57ede025aaee831e98c

Source-Link: https://togithub.com/googleapis/googleapis-gen/commit/939ab9ea6efe368126440b42e6beac7897d3a1c2
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiOTM5YWI5ZWE2ZWZlMzY4MTI2NDQwYjQyZTZiZWFjNzg5N2QzYTFjMiJ9
BEGIN_NESTED_COMMIT
feat(documentai): expose model_type in v1 processor, so that user can see the model_type after get or list processor version
PiperOrigin-RevId: 603727585

Source-Link: https://togithub.com/googleapis/googleapis/commit/7a9a855287b5042410c93e5a510f40efd4ce6cb1

Source-Link: https://togithub.com/googleapis/googleapis-gen/commit/9643051150762c3e15d1cd420ddfb978a1b7c24c
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiOTY0MzA1MTE1MDc2MmMzZTE1ZDFjZDQyMGRkZmI5NzhhMWI3YzI0YyJ9
END_NESTED_COMMIT
  • Loading branch information
gcf-owl-bot[bot] committed Feb 6, 2024
1 parent 14ce978 commit 2fcf55c
Show file tree
Hide file tree
Showing 15 changed files with 1,288 additions and 633 deletions.
335 changes: 205 additions & 130 deletions documentai/apiv1/documentaipb/processor.pb.go

Large diffs are not rendered by default.

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.

Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,52 @@
}
]
},
{
"regionTag": "vision_v1_generated_ImageAnnotator_GetOperation_sync",
"title": "vision GetOperation Sample",
"description": "GetOperation is a utility method from google.longrunning.Operations.",
"file": "ImageAnnotatorClient/GetOperation/main.go",
"language": "GO",
"clientMethod": {
"shortName": "GetOperation",
"fullName": "google.cloud.vision.v1.ImageAnnotatorClient.GetOperation",
"parameters": [
{
"type": "context.Context",
"name": "ctx"
},
{
"type": "longrunningpb.GetOperationRequest",
"name": "req"
},
{
"type": "...gax.CallOption",
"name": "opts"
}
],
"resultType": "*longrunningpb.Operation",
"client": {
"shortName": "ImageAnnotatorClient",
"fullName": "google.cloud.vision.v1.ImageAnnotatorClient"
},
"method": {
"shortName": "GetOperation",
"fullName": "google.longrunning.Operations.GetOperation",
"service": {
"shortName": "Operations",
"fullName": "google.longrunning.Operations"
}
}
},
"origin": "API_DEFINITION",
"segments": [
{
"start": 18,
"end": 53,
"type": "FULL"
}
]
},
{
"regionTag": "vision_v1_generated_ProductSearch_AddProductToProductSet_sync",
"title": "vision AddProductToProductSet Sample",
Expand Down Expand Up @@ -513,6 +559,52 @@
}
]
},
{
"regionTag": "vision_v1_generated_ProductSearch_GetOperation_sync",
"title": "vision GetOperation Sample",
"description": "GetOperation is a utility method from google.longrunning.Operations.",
"file": "ProductSearchClient/GetOperation/main.go",
"language": "GO",
"clientMethod": {
"shortName": "GetOperation",
"fullName": "google.cloud.vision.v1.ProductSearchClient.GetOperation",
"parameters": [
{
"type": "context.Context",
"name": "ctx"
},
{
"type": "longrunningpb.GetOperationRequest",
"name": "req"
},
{
"type": "...gax.CallOption",
"name": "opts"
}
],
"resultType": "*longrunningpb.Operation",
"client": {
"shortName": "ProductSearchClient",
"fullName": "google.cloud.vision.v1.ProductSearchClient"
},
"method": {
"shortName": "GetOperation",
"fullName": "google.longrunning.Operations.GetOperation",
"service": {
"shortName": "Operations",
"fullName": "google.longrunning.Operations"
}
}
},
"origin": "API_DEFINITION",
"segments": [
{
"start": 18,
"end": 53,
"type": "FULL"
}
]
},
{
"regionTag": "vision_v1_generated_ProductSearch_GetProduct_sync",
"title": "vision GetProduct Sample",
Expand Down Expand Up @@ -654,7 +746,7 @@
{
"regionTag": "vision_v1_generated_ProductSearch_ImportProductSets_sync",
"title": "vision ImportProductSets Sample",
"description": "ImportProductSets asynchronous API that imports a list of reference images to specified\nproduct sets based on a list of image information.\n\nThe [google.longrunning.Operation][google.longrunning.Operation] API can be used to keep track of the\nprogress and results of the request.\n`Operation.metadata` contains `BatchOperationMetadata`. (progress)\n`Operation.response` contains `ImportProductSetsResponse`. (results)\n\nThe input source of this method is a csv file on Google Cloud Storage.\nFor the format of the csv file please see\n[ImportProductSetsGcsSource.csv_file_uri][google.cloud.vision.v1.ImportProductSetsGcsSource.csv_file_uri].",
"description": "ImportProductSets asynchronous API that imports a list of reference images to specified\nproduct sets based on a list of image information.\n\nThe [google.longrunning.Operation][google.longrunning.Operation] API can be\nused to keep track of the progress and results of the request.\n`Operation.metadata` contains `BatchOperationMetadata`. (progress)\n`Operation.response` contains `ImportProductSetsResponse`. (results)\n\nThe input source of this method is a csv file on Google Cloud Storage.\nFor the format of the csv file please see\n[ImportProductSetsGcsSource.csv_file_uri][google.cloud.vision.v1.ImportProductSetsGcsSource.csv_file_uri].",
"file": "ProductSearchClient/ImportProductSets/main.go",
"language": "GO",
"clientMethod": {
Expand Down Expand Up @@ -884,7 +976,7 @@
{
"regionTag": "vision_v1_generated_ProductSearch_PurgeProducts_sync",
"title": "vision PurgeProducts Sample",
"description": "PurgeProducts asynchronous API to delete all Products in a ProductSet or all Products\nthat are in no ProductSet.\n\nIf a Product is a member of the specified ProductSet in addition to other\nProductSets, the Product will still be deleted.\n\nIt is recommended to not delete the specified ProductSet until after this\noperation has completed. It is also recommended to not add any of the\nProducts involved in the batch delete to a new ProductSet while this\noperation is running because those Products may still end up deleted.\n\nIt's not possible to undo the PurgeProducts operation. Therefore, it is\nrecommended to keep the csv files used in ImportProductSets (if that was\nhow you originally built the Product Set) before starting PurgeProducts, in\ncase you need to re-import the data after deletion.\n\nIf the plan is to purge all of the Products from a ProductSet and then\nre-use the empty ProductSet to re-import new Products into the empty\nProductSet, you must wait until the PurgeProducts operation has finished\nfor that ProductSet.\n\nThe [google.longrunning.Operation][google.longrunning.Operation] API can be used to keep track of the\nprogress and results of the request.\n`Operation.metadata` contains `BatchOperationMetadata`. (progress)",
"description": "PurgeProducts asynchronous API to delete all Products in a ProductSet or all Products\nthat are in no ProductSet.\n\nIf a Product is a member of the specified ProductSet in addition to other\nProductSets, the Product will still be deleted.\n\nIt is recommended to not delete the specified ProductSet until after this\noperation has completed. It is also recommended to not add any of the\nProducts involved in the batch delete to a new ProductSet while this\noperation is running because those Products may still end up deleted.\n\nIt's not possible to undo the PurgeProducts operation. Therefore, it is\nrecommended to keep the csv files used in ImportProductSets (if that was\nhow you originally built the Product Set) before starting PurgeProducts, in\ncase you need to re-import the data after deletion.\n\nIf the plan is to purge all of the Products from a ProductSet and then\nre-use the empty ProductSet to re-import new Products into the empty\nProductSet, you must wait until the PurgeProducts operation has finished\nfor that ProductSet.\n\nThe [google.longrunning.Operation][google.longrunning.Operation] API can be\nused to keep track of the progress and results of the request.\n`Operation.metadata` contains `BatchOperationMetadata`. (progress)",
"file": "ProductSearchClient/PurgeProducts/main.go",
"language": "GO",
"clientMethod": {
Expand Down
20 changes: 20 additions & 0 deletions vision/apiv1/gapic_metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@
"methods": [
"BatchAnnotateImages"
]
},
"GetOperation": {
"methods": [
"GetOperation"
]
}
}
},
Expand All @@ -54,6 +59,11 @@
"methods": [
"BatchAnnotateImages"
]
},
"GetOperation": {
"methods": [
"GetOperation"
]
}
}
}
Expand Down Expand Up @@ -99,6 +109,11 @@
"DeleteReferenceImage"
]
},
"GetOperation": {
"methods": [
"GetOperation"
]
},
"GetProduct": {
"methods": [
"GetProduct"
Expand Down Expand Up @@ -199,6 +214,11 @@
"DeleteReferenceImage"
]
},
"GetOperation": {
"methods": [
"GetOperation"
]
},
"GetProduct": {
"methods": [
"GetProduct"
Expand Down
Loading

0 comments on commit 2fcf55c

Please sign in to comment.