• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright (C) 2017 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//      http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15// LINT: ALLOW_GROUPS
16// Protocol buffer specifications for task configuration.
17
18syntax = "proto2";
19option optimize_for = LITE_RUNTIME;
20
21package libtextclassifier.nlp_core;
22
23// Task input descriptor.
24message TaskInput {
25  // Name of input resource.
26  required string name = 1;
27
28  // File format for resource.
29  repeated string file_format = 3;
30
31  // Record format for resource.
32  repeated string record_format = 4;
33
34  // An input can consist of multiple file sets.
35  repeated group Part = 6 {
36    // File pattern for file set.
37    optional string file_pattern = 7;
38
39    // File format for file set.
40    optional string file_format = 8;
41
42    // Record format for file set.
43    optional string record_format = 9;
44  }
45
46  reserved 2, 5;
47}
48
49// A task specification is used for describing executing parameters.
50message TaskSpec {
51  // Task parameters.
52  repeated group Parameter = 3 {
53    required string name = 4;
54    optional string value = 5;
55  }
56
57  // Task inputs.
58  repeated TaskInput input = 6;
59
60  reserved 1, 2, 7;
61}
62