// Copyright 2026 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

syntax = "proto3";

package google.cloud.ces.v1;

import "google/api/field_behavior.proto";

option go_package = "cloud.google.com/go/ces/apiv1/cespb;cespb";
option java_multiple_files = true;
option java_outer_classname = "FileSearchToolProto";
option java_package = "com.google.cloud.ces.v1";

// The file search tool allows the agent to search across the files uploaded by
// the app/agent developer. It has presets to give relatively good quality
// search over the uploaded files and summarization of the retrieved results.
message FileSearchTool {
  // The type of the Vertex RAG corpus.
  enum CorpusType {
    // Unspecified corpus type.
    CORPUS_TYPE_UNSPECIFIED = 0;

    // The corpus is created and owned by the user.
    USER_OWNED = 1;

    // The corpus is created by the agent.
    FULLY_MANAGED = 2;
  }

  // Optional. The type of the corpus. Default is FULLY_MANAGED.
  CorpusType corpus_type = 3 [(google.api.field_behavior) = OPTIONAL];

  // Required. The tool name.
  string name = 4 [(google.api.field_behavior) = REQUIRED];

  // Optional. The tool description.
  string description = 5 [(google.api.field_behavior) = OPTIONAL];

  // Optional. The corpus where files are stored.
  // Format:
  // projects/{project}/locations/{location}/ragCorpora/{rag_corpus}
  string file_corpus = 6 [(google.api.field_behavior) = OPTIONAL];
}
