Skip to content

Commit 4eb76f5

Browse files
Google APIscopybara-github
authored andcommitted
feat: Add env variables and agent framework to ReasoningEngineSpec
docs: Update comment for `package_spec` from required to optional in `ReasoningEngineSpec`. docs: Add `deployment_spec` and `agent_framework` field to `ReasoningEngineSpec`. PiperOrigin-RevId: 738059528
1 parent 9491391 commit 4eb76f5

2 files changed

Lines changed: 55 additions & 5 deletions

File tree

google/cloud/aiplatform/v1/env_var.proto

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ syntax = "proto3";
1717
package google.cloud.aiplatform.v1;
1818

1919
import "google/api/field_behavior.proto";
20-
import "google/api/resource.proto";
2120

2221
option csharp_namespace = "Google.Cloud.AIPlatform.V1";
2322
option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb";
@@ -41,3 +40,27 @@ message EnvVar {
4140
// exists or not.
4241
string value = 2 [(google.api.field_behavior) = REQUIRED];
4342
}
43+
44+
// Reference to a secret stored in the Cloud Secret Manager that will
45+
// provide the value for this environment variable.
46+
message SecretRef {
47+
// Required. The name of the secret in Cloud Secret Manager.
48+
// Format: {secret_name}.
49+
string secret = 1 [(google.api.field_behavior) = REQUIRED];
50+
51+
// The Cloud Secret Manager secret version.
52+
// Can be 'latest' for the latest version, an integer for a specific
53+
// version, or a version alias.
54+
string version = 2;
55+
}
56+
57+
// Represents an environment variable where the value is a secret in Cloud
58+
// Secret Manager.
59+
message SecretEnvVar {
60+
// Required. Name of the secret environment variable.
61+
string name = 1 [(google.api.field_behavior) = REQUIRED];
62+
63+
// Required. Reference to a secret stored in the Cloud Secret Manager that
64+
// will provide the value for this environment variable.
65+
SecretRef secret_ref = 2 [(google.api.field_behavior) = REQUIRED];
66+
}

google/cloud/aiplatform/v1/reasoning_engine.proto

Lines changed: 31 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ package google.cloud.aiplatform.v1;
1818

1919
import "google/api/field_behavior.proto";
2020
import "google/api/resource.proto";
21+
import "google/cloud/aiplatform/v1/env_var.proto";
2122
import "google/protobuf/struct.proto";
2223
import "google/protobuf/timestamp.proto";
2324

@@ -48,13 +49,39 @@ message ReasoningEngineSpec {
4849
string python_version = 4 [(google.api.field_behavior) = OPTIONAL];
4950
}
5051

51-
// Required. User provided package spec of the ReasoningEngine.
52-
PackageSpec package_spec = 2 [(google.api.field_behavior) = REQUIRED];
52+
// The specification of a Reasoning Engine deployment.
53+
message DeploymentSpec {
54+
// Optional. Environment variables to be set with the Reasoning Engine
55+
// deployment. The environment variables can be updated through the
56+
// UpdateReasoningEngine API.
57+
repeated EnvVar env = 1 [(google.api.field_behavior) = OPTIONAL];
58+
59+
// Optional. Environment variables where the value is a secret in Cloud
60+
// Secret Manager.
61+
// To use this feature, add 'Secret Manager Secret Accessor' role
62+
// (roles/secretmanager.secretAccessor) to AI Platform Reasoning Engine
63+
// Service Agent.
64+
repeated SecretEnvVar secret_env = 2
65+
[(google.api.field_behavior) = OPTIONAL];
66+
}
67+
68+
// Optional. User provided package spec of the ReasoningEngine.
69+
// Ignored when users directly specify a deployment image through
70+
// `deployment_spec.first_party_image_override`, but keeping the
71+
// field_behavior to avoid introducing breaking changes.
72+
PackageSpec package_spec = 2 [(google.api.field_behavior) = OPTIONAL];
73+
74+
// Optional. The specification of a Reasoning Engine deployment.
75+
DeploymentSpec deployment_spec = 4 [(google.api.field_behavior) = OPTIONAL];
5376

5477
// Optional. Declarations for object class methods in OpenAPI specification
5578
// format.
5679
repeated google.protobuf.Struct class_methods = 3
5780
[(google.api.field_behavior) = OPTIONAL];
81+
82+
// Optional. The OSS agent framework used to develop the agent.
83+
// Currently supported values: "langchain", "langgraph", "ag2", "custom".
84+
string agent_framework = 5 [(google.api.field_behavior) = OPTIONAL];
5885
}
5986

6087
// ReasoningEngine provides a customizable runtime for models to determine
@@ -76,8 +103,8 @@ message ReasoningEngine {
76103
// Optional. The description of the ReasoningEngine.
77104
string description = 7 [(google.api.field_behavior) = OPTIONAL];
78105

79-
// Required. Configurations of the ReasoningEngine
80-
ReasoningEngineSpec spec = 3 [(google.api.field_behavior) = REQUIRED];
106+
// Optional. Configurations of the ReasoningEngine
107+
ReasoningEngineSpec spec = 3 [(google.api.field_behavior) = OPTIONAL];
81108

82109
// Output only. Timestamp when this ReasoningEngine was created.
83110
google.protobuf.Timestamp create_time = 4

0 commit comments

Comments
 (0)