Skip to content

Exact BatchInference job gcsUri output path is missing #760

@GolanLevy

Description

@GolanLevy

Similar to #696, I have no way to get the exact output file path of a batch job response file.

The gcsUri field contains the output URI provided in the request, which is not very helpful as it is only a prefix.
The actual file resides in a subfolder, named {gcsUri}/prediction-model-{timestamp}/predictions.jsonl.
I was not able to correlate the timestamp to any field. It is very similar to the createTime field but not exact.

For example, if I set the gcsUri to be gs://bucket_name/output/ the output file path will be something like gs://bucket_name/output/prediction-model-2025-12-26T20:29:02.829566Z/predictions.jsonl

However, the batch inference UI web console does have an Export Location field that holds the correct output file path. This hopefully means that you can easily expose that to the Java SDK as well.

Can you please fix that or provide any proper workaround?
Currently I have to list all files under the gcsUri prefix and hope there is going to be only one response file.

Metadata

Metadata

Assignees

Labels

priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions