Stay organized with collections
Save and categorize content based on your preferences.
Creates a new version of a model from a trained TensorFlow model. If the
version created in the cloud by this call is the first deployed version
of the specified model, it will be made the default version of the
model. When you add a version to a model that already has one or more
versions, the default version does not automatically change. If you want
a new version to be the default, you must call
projects.models.versions.setDefault.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Method: googleapis.ml.v1.projects.models.versions.create\n\nCreates a new version of a model from a trained TensorFlow model. If the\nversion created in the cloud by this call is the first deployed version\nof the specified model, it will be made the default version of the\nmodel. When you add a version to a model that already has one or more\nversions, the default version does not automatically change. If you want\na new version to be the default, you must call\nprojects.models.versions.setDefault.\n\nArguments\n---------\n\nRaised exceptions\n-----------------\n\nResponse\n--------\n\nIf successful, the response contains an instance of [`GoogleLongrunning__Operation`](https://cloud.google.com/workflows/docs/reference/googleapis/ml/v1/Overview#GoogleLongrunning__Operation).\n\nSubworkflow snippet\n-------------------\n\nSome fields might be optional or required.\nTo identify required fields, refer to the [API documentation](https://cloud.google.com/ai-platform/training/docs/reference/rest/v1/projects.models.versions/create). \n\n### YAML\n\n```yaml\n- create:\n call: googleapis.ml.v1.projects.models.versions.create\n args:\n parent: ...\n body:\n acceleratorConfig:\n count: ...\n type: ...\n autoScaling:\n maxNodes: ...\n metrics: ...\n minNodes: ...\n container:\n args: ...\n command: ...\n env: ...\n image: ...\n ports: ...\n deploymentUri: ...\n description: ...\n etag: ...\n explanationConfig:\n integratedGradientsAttribution:\n numIntegralSteps: ...\n sampledShapleyAttribution:\n numPaths: ...\n xraiAttribution:\n numIntegralSteps: ...\n framework: ...\n labels: ...\n machineType: ...\n manualScaling:\n nodes: ...\n name: ...\n packageUris: ...\n predictionClass: ...\n pythonVersion: ...\n requestLoggingConfig:\n bigqueryTableName: ...\n samplingPercentage: ...\n routes:\n health: ...\n predict: ...\n runtimeVersion: ...\n serviceAccount: ...\n result: createResult\n```\n\n### JSON\n\n```json\n[\n {\n \"create\": {\n \"call\": \"googleapis.ml.v1.projects.models.versions.create\",\n \"args\": {\n \"parent\": \"...\",\n \"body\": {\n \"acceleratorConfig\": {\n \"count\": \"...\",\n \"type\": \"...\"\n },\n \"autoScaling\": {\n \"maxNodes\": \"...\",\n \"metrics\": \"...\",\n \"minNodes\": \"...\"\n },\n \"container\": {\n \"args\": \"...\",\n \"command\": \"...\",\n \"env\": \"...\",\n \"image\": \"...\",\n \"ports\": \"...\"\n },\n \"deploymentUri\": \"...\",\n \"description\": \"...\",\n \"etag\": \"...\",\n \"explanationConfig\": {\n \"integratedGradientsAttribution\": {\n \"numIntegralSteps\": \"...\"\n },\n \"sampledShapleyAttribution\": {\n \"numPaths\": \"...\"\n },\n \"xraiAttribution\": {\n \"numIntegralSteps\": \"...\"\n }\n },\n \"framework\": \"...\",\n \"labels\": \"...\",\n \"machineType\": \"...\",\n \"manualScaling\": {\n \"nodes\": \"...\"\n },\n \"name\": \"...\",\n \"packageUris\": \"...\",\n \"predictionClass\": \"...\",\n \"pythonVersion\": \"...\",\n \"requestLoggingConfig\": {\n \"bigqueryTableName\": \"...\",\n \"samplingPercentage\": \"...\"\n },\n \"routes\": {\n \"health\": \"...\",\n \"predict\": \"...\"\n },\n \"runtimeVersion\": \"...\",\n \"serviceAccount\": \"...\"\n }\n },\n \"result\": \"createResult\"\n }\n }\n]\n```"]]