~nskaggs/+junk/xenial-test

« back to all changes in this revision

Viewing changes to src/google.golang.org/api/prediction/v1.2/prediction-gen.go

  • Committer: Nicholas Skaggs
  • Date: 2016-10-24 20:56:05 UTC
  • Revision ID: nicholas.skaggs@canonical.com-20161024205605-z8lta0uvuhtxwzwl
Initi with beta15

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Package prediction provides access to the Prediction API.
 
2
//
 
3
// See https://developers.google.com/prediction/docs/developer-guide
 
4
//
 
5
// Usage example:
 
6
//
 
7
//   import "google.golang.org/api/prediction/v1.2"
 
8
//   ...
 
9
//   predictionService, err := prediction.New(oauthHttpClient)
 
10
package prediction
 
11
 
 
12
import (
 
13
        "bytes"
 
14
        "encoding/json"
 
15
        "errors"
 
16
        "fmt"
 
17
        "google.golang.org/api/googleapi"
 
18
        "io"
 
19
        "net/http"
 
20
        "net/url"
 
21
        "strconv"
 
22
        "strings"
 
23
)
 
24
 
 
25
// Always reference these packages, just in case the auto-generated code
 
26
// below doesn't.
 
27
var _ = bytes.NewBuffer
 
28
var _ = strconv.Itoa
 
29
var _ = fmt.Sprintf
 
30
var _ = json.NewDecoder
 
31
var _ = io.Copy
 
32
var _ = url.Parse
 
33
var _ = googleapi.Version
 
34
var _ = errors.New
 
35
var _ = strings.Replace
 
36
 
 
37
const apiId = "prediction:v1.2"
 
38
const apiName = "prediction"
 
39
const apiVersion = "v1.2"
 
40
const basePath = "https://www.googleapis.com/prediction/v1.2/"
 
41
 
 
42
// OAuth2 scopes used by this API.
 
43
const (
 
44
        // Manage your data and permissions in Google Cloud Storage
 
45
        DevstorageFull_controlScope = "https://www.googleapis.com/auth/devstorage.full_control"
 
46
 
 
47
        // View your data in Google Cloud Storage
 
48
        DevstorageRead_onlyScope = "https://www.googleapis.com/auth/devstorage.read_only"
 
49
 
 
50
        // Manage your data in Google Cloud Storage
 
51
        DevstorageRead_writeScope = "https://www.googleapis.com/auth/devstorage.read_write"
 
52
 
 
53
        // Manage your data in the Google Prediction API
 
54
        PredictionScope = "https://www.googleapis.com/auth/prediction"
 
55
)
 
56
 
 
57
func New(client *http.Client) (*Service, error) {
 
58
        if client == nil {
 
59
                return nil, errors.New("client is nil")
 
60
        }
 
61
        s := &Service{client: client, BasePath: basePath}
 
62
        s.Hostedmodels = NewHostedmodelsService(s)
 
63
        s.Training = NewTrainingService(s)
 
64
        return s, nil
 
65
}
 
66
 
 
67
type Service struct {
 
68
        client   *http.Client
 
69
        BasePath string // API endpoint base URL
 
70
 
 
71
        Hostedmodels *HostedmodelsService
 
72
 
 
73
        Training *TrainingService
 
74
}
 
75
 
 
76
func NewHostedmodelsService(s *Service) *HostedmodelsService {
 
77
        rs := &HostedmodelsService{s: s}
 
78
        return rs
 
79
}
 
80
 
 
81
type HostedmodelsService struct {
 
82
        s *Service
 
83
}
 
84
 
 
85
func NewTrainingService(s *Service) *TrainingService {
 
86
        rs := &TrainingService{s: s}
 
87
        return rs
 
88
}
 
89
 
 
90
type TrainingService struct {
 
91
        s *Service
 
92
}
 
93
 
 
94
type Input struct {
 
95
        Input *InputInput `json:"input,omitempty"`
 
96
}
 
97
 
 
98
type InputInput struct {
 
99
        CsvInstance []interface{} `json:"csvInstance,omitempty"`
 
100
}
 
101
 
 
102
type Output struct {
 
103
        Id string `json:"id,omitempty"`
 
104
 
 
105
        Kind string `json:"kind,omitempty"`
 
106
 
 
107
        OutputLabel string `json:"outputLabel,omitempty"`
 
108
 
 
109
        OutputMulti []*OutputOutputMulti `json:"outputMulti,omitempty"`
 
110
 
 
111
        OutputValue float64 `json:"outputValue,omitempty"`
 
112
 
 
113
        SelfLink string `json:"selfLink,omitempty"`
 
114
}
 
115
 
 
116
type OutputOutputMulti struct {
 
117
        Label string `json:"label,omitempty"`
 
118
 
 
119
        Score float64 `json:"score,omitempty"`
 
120
}
 
121
 
 
122
type Training struct {
 
123
        Id string `json:"id,omitempty"`
 
124
 
 
125
        Kind string `json:"kind,omitempty"`
 
126
 
 
127
        ModelInfo *TrainingModelInfo `json:"modelInfo,omitempty"`
 
128
 
 
129
        SelfLink string `json:"selfLink,omitempty"`
 
130
 
 
131
        TrainingStatus string `json:"trainingStatus,omitempty"`
 
132
}
 
133
 
 
134
type TrainingModelInfo struct {
 
135
        ClassificationAccuracy float64 `json:"classificationAccuracy,omitempty"`
 
136
 
 
137
        MeanSquaredError float64 `json:"meanSquaredError,omitempty"`
 
138
 
 
139
        ModelType string `json:"modelType,omitempty"`
 
140
}
 
141
 
 
142
type Update struct {
 
143
        // ClassLabel: The true class label of this instance
 
144
        ClassLabel string `json:"classLabel,omitempty"`
 
145
 
 
146
        // CsvInstance: The input features for this instance
 
147
        CsvInstance []interface{} `json:"csvInstance,omitempty"`
 
148
}
 
149
 
 
150
// method id "prediction.predict":
 
151
 
 
152
type PredictCall struct {
 
153
        s     *Service
 
154
        data  string
 
155
        input *Input
 
156
        opt_  map[string]interface{}
 
157
}
 
158
 
 
159
// Predict: Submit data and request a prediction
 
160
func (s *Service) Predict(data string, input *Input) *PredictCall {
 
161
        c := &PredictCall{s: s, opt_: make(map[string]interface{})}
 
162
        c.data = data
 
163
        c.input = input
 
164
        return c
 
165
}
 
166
 
 
167
// Fields allows partial responses to be retrieved.
 
168
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
169
// for more information.
 
170
func (c *PredictCall) Fields(s ...googleapi.Field) *PredictCall {
 
171
        c.opt_["fields"] = googleapi.CombineFields(s)
 
172
        return c
 
173
}
 
174
 
 
175
func (c *PredictCall) Do() (*Output, error) {
 
176
        var body io.Reader = nil
 
177
        body, err := googleapi.WithoutDataWrapper.JSONReader(c.input)
 
178
        if err != nil {
 
179
                return nil, err
 
180
        }
 
181
        ctype := "application/json"
 
182
        params := make(url.Values)
 
183
        params.Set("alt", "json")
 
184
        if v, ok := c.opt_["fields"]; ok {
 
185
                params.Set("fields", fmt.Sprintf("%v", v))
 
186
        }
 
187
        urls := googleapi.ResolveRelative(c.s.BasePath, "training/{data}/predict")
 
188
        urls += "?" + params.Encode()
 
189
        req, _ := http.NewRequest("POST", urls, body)
 
190
        googleapi.Expand(req.URL, map[string]string{
 
191
                "data": c.data,
 
192
        })
 
193
        req.Header.Set("Content-Type", ctype)
 
194
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
195
        res, err := c.s.client.Do(req)
 
196
        if err != nil {
 
197
                return nil, err
 
198
        }
 
199
        defer googleapi.CloseBody(res)
 
200
        if err := googleapi.CheckResponse(res); err != nil {
 
201
                return nil, err
 
202
        }
 
203
        var ret *Output
 
204
        if err := json.NewDecoder(res.Body).Decode(&ret); err != nil {
 
205
                return nil, err
 
206
        }
 
207
        return ret, nil
 
208
        // {
 
209
        //   "description": "Submit data and request a prediction",
 
210
        //   "httpMethod": "POST",
 
211
        //   "id": "prediction.predict",
 
212
        //   "parameterOrder": [
 
213
        //     "data"
 
214
        //   ],
 
215
        //   "parameters": {
 
216
        //     "data": {
 
217
        //       "description": "mybucket%2Fmydata resource in Google Storage",
 
218
        //       "location": "path",
 
219
        //       "required": true,
 
220
        //       "type": "string"
 
221
        //     }
 
222
        //   },
 
223
        //   "path": "training/{data}/predict",
 
224
        //   "request": {
 
225
        //     "$ref": "Input"
 
226
        //   },
 
227
        //   "response": {
 
228
        //     "$ref": "Output"
 
229
        //   },
 
230
        //   "scopes": [
 
231
        //     "https://www.googleapis.com/auth/prediction"
 
232
        //   ]
 
233
        // }
 
234
 
 
235
}
 
236
 
 
237
// method id "prediction.hostedmodels.predict":
 
238
 
 
239
type HostedmodelsPredictCall struct {
 
240
        s               *Service
 
241
        hostedModelName string
 
242
        input           *Input
 
243
        opt_            map[string]interface{}
 
244
}
 
245
 
 
246
// Predict: Submit input and request an output against a hosted model
 
247
func (r *HostedmodelsService) Predict(hostedModelName string, input *Input) *HostedmodelsPredictCall {
 
248
        c := &HostedmodelsPredictCall{s: r.s, opt_: make(map[string]interface{})}
 
249
        c.hostedModelName = hostedModelName
 
250
        c.input = input
 
251
        return c
 
252
}
 
253
 
 
254
// Fields allows partial responses to be retrieved.
 
255
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
256
// for more information.
 
257
func (c *HostedmodelsPredictCall) Fields(s ...googleapi.Field) *HostedmodelsPredictCall {
 
258
        c.opt_["fields"] = googleapi.CombineFields(s)
 
259
        return c
 
260
}
 
261
 
 
262
func (c *HostedmodelsPredictCall) Do() (*Output, error) {
 
263
        var body io.Reader = nil
 
264
        body, err := googleapi.WithoutDataWrapper.JSONReader(c.input)
 
265
        if err != nil {
 
266
                return nil, err
 
267
        }
 
268
        ctype := "application/json"
 
269
        params := make(url.Values)
 
270
        params.Set("alt", "json")
 
271
        if v, ok := c.opt_["fields"]; ok {
 
272
                params.Set("fields", fmt.Sprintf("%v", v))
 
273
        }
 
274
        urls := googleapi.ResolveRelative(c.s.BasePath, "hostedmodels/{hostedModelName}/predict")
 
275
        urls += "?" + params.Encode()
 
276
        req, _ := http.NewRequest("POST", urls, body)
 
277
        googleapi.Expand(req.URL, map[string]string{
 
278
                "hostedModelName": c.hostedModelName,
 
279
        })
 
280
        req.Header.Set("Content-Type", ctype)
 
281
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
282
        res, err := c.s.client.Do(req)
 
283
        if err != nil {
 
284
                return nil, err
 
285
        }
 
286
        defer googleapi.CloseBody(res)
 
287
        if err := googleapi.CheckResponse(res); err != nil {
 
288
                return nil, err
 
289
        }
 
290
        var ret *Output
 
291
        if err := json.NewDecoder(res.Body).Decode(&ret); err != nil {
 
292
                return nil, err
 
293
        }
 
294
        return ret, nil
 
295
        // {
 
296
        //   "description": "Submit input and request an output against a hosted model",
 
297
        //   "httpMethod": "POST",
 
298
        //   "id": "prediction.hostedmodels.predict",
 
299
        //   "parameterOrder": [
 
300
        //     "hostedModelName"
 
301
        //   ],
 
302
        //   "parameters": {
 
303
        //     "hostedModelName": {
 
304
        //       "description": "The name of a hosted model",
 
305
        //       "location": "path",
 
306
        //       "required": true,
 
307
        //       "type": "string"
 
308
        //     }
 
309
        //   },
 
310
        //   "path": "hostedmodels/{hostedModelName}/predict",
 
311
        //   "request": {
 
312
        //     "$ref": "Input"
 
313
        //   },
 
314
        //   "response": {
 
315
        //     "$ref": "Output"
 
316
        //   },
 
317
        //   "scopes": [
 
318
        //     "https://www.googleapis.com/auth/prediction"
 
319
        //   ]
 
320
        // }
 
321
 
 
322
}
 
323
 
 
324
// method id "prediction.training.delete":
 
325
 
 
326
type TrainingDeleteCall struct {
 
327
        s    *Service
 
328
        data string
 
329
        opt_ map[string]interface{}
 
330
}
 
331
 
 
332
// Delete: Delete a trained model
 
333
func (r *TrainingService) Delete(data string) *TrainingDeleteCall {
 
334
        c := &TrainingDeleteCall{s: r.s, opt_: make(map[string]interface{})}
 
335
        c.data = data
 
336
        return c
 
337
}
 
338
 
 
339
// Fields allows partial responses to be retrieved.
 
340
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
341
// for more information.
 
342
func (c *TrainingDeleteCall) Fields(s ...googleapi.Field) *TrainingDeleteCall {
 
343
        c.opt_["fields"] = googleapi.CombineFields(s)
 
344
        return c
 
345
}
 
346
 
 
347
func (c *TrainingDeleteCall) Do() error {
 
348
        var body io.Reader = nil
 
349
        params := make(url.Values)
 
350
        params.Set("alt", "json")
 
351
        if v, ok := c.opt_["fields"]; ok {
 
352
                params.Set("fields", fmt.Sprintf("%v", v))
 
353
        }
 
354
        urls := googleapi.ResolveRelative(c.s.BasePath, "training/{data}")
 
355
        urls += "?" + params.Encode()
 
356
        req, _ := http.NewRequest("DELETE", urls, body)
 
357
        googleapi.Expand(req.URL, map[string]string{
 
358
                "data": c.data,
 
359
        })
 
360
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
361
        res, err := c.s.client.Do(req)
 
362
        if err != nil {
 
363
                return err
 
364
        }
 
365
        defer googleapi.CloseBody(res)
 
366
        if err := googleapi.CheckResponse(res); err != nil {
 
367
                return err
 
368
        }
 
369
        return nil
 
370
        // {
 
371
        //   "description": "Delete a trained model",
 
372
        //   "httpMethod": "DELETE",
 
373
        //   "id": "prediction.training.delete",
 
374
        //   "parameterOrder": [
 
375
        //     "data"
 
376
        //   ],
 
377
        //   "parameters": {
 
378
        //     "data": {
 
379
        //       "description": "mybucket/mydata resource in Google Storage",
 
380
        //       "location": "path",
 
381
        //       "required": true,
 
382
        //       "type": "string"
 
383
        //     }
 
384
        //   },
 
385
        //   "path": "training/{data}",
 
386
        //   "scopes": [
 
387
        //     "https://www.googleapis.com/auth/prediction"
 
388
        //   ]
 
389
        // }
 
390
 
 
391
}
 
392
 
 
393
// method id "prediction.training.get":
 
394
 
 
395
type TrainingGetCall struct {
 
396
        s    *Service
 
397
        data string
 
398
        opt_ map[string]interface{}
 
399
}
 
400
 
 
401
// Get: Check training status of your model
 
402
func (r *TrainingService) Get(data string) *TrainingGetCall {
 
403
        c := &TrainingGetCall{s: r.s, opt_: make(map[string]interface{})}
 
404
        c.data = data
 
405
        return c
 
406
}
 
407
 
 
408
// Fields allows partial responses to be retrieved.
 
409
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
410
// for more information.
 
411
func (c *TrainingGetCall) Fields(s ...googleapi.Field) *TrainingGetCall {
 
412
        c.opt_["fields"] = googleapi.CombineFields(s)
 
413
        return c
 
414
}
 
415
 
 
416
func (c *TrainingGetCall) Do() (*Training, error) {
 
417
        var body io.Reader = nil
 
418
        params := make(url.Values)
 
419
        params.Set("alt", "json")
 
420
        if v, ok := c.opt_["fields"]; ok {
 
421
                params.Set("fields", fmt.Sprintf("%v", v))
 
422
        }
 
423
        urls := googleapi.ResolveRelative(c.s.BasePath, "training/{data}")
 
424
        urls += "?" + params.Encode()
 
425
        req, _ := http.NewRequest("GET", urls, body)
 
426
        googleapi.Expand(req.URL, map[string]string{
 
427
                "data": c.data,
 
428
        })
 
429
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
430
        res, err := c.s.client.Do(req)
 
431
        if err != nil {
 
432
                return nil, err
 
433
        }
 
434
        defer googleapi.CloseBody(res)
 
435
        if err := googleapi.CheckResponse(res); err != nil {
 
436
                return nil, err
 
437
        }
 
438
        var ret *Training
 
439
        if err := json.NewDecoder(res.Body).Decode(&ret); err != nil {
 
440
                return nil, err
 
441
        }
 
442
        return ret, nil
 
443
        // {
 
444
        //   "description": "Check training status of your model",
 
445
        //   "httpMethod": "GET",
 
446
        //   "id": "prediction.training.get",
 
447
        //   "parameterOrder": [
 
448
        //     "data"
 
449
        //   ],
 
450
        //   "parameters": {
 
451
        //     "data": {
 
452
        //       "description": "mybucket/mydata resource in Google Storage",
 
453
        //       "location": "path",
 
454
        //       "required": true,
 
455
        //       "type": "string"
 
456
        //     }
 
457
        //   },
 
458
        //   "path": "training/{data}",
 
459
        //   "response": {
 
460
        //     "$ref": "Training"
 
461
        //   },
 
462
        //   "scopes": [
 
463
        //     "https://www.googleapis.com/auth/prediction"
 
464
        //   ]
 
465
        // }
 
466
 
 
467
}
 
468
 
 
469
// method id "prediction.training.insert":
 
470
 
 
471
type TrainingInsertCall struct {
 
472
        s        *Service
 
473
        training *Training
 
474
        opt_     map[string]interface{}
 
475
}
 
476
 
 
477
// Insert: Begin training your model
 
478
func (r *TrainingService) Insert(training *Training) *TrainingInsertCall {
 
479
        c := &TrainingInsertCall{s: r.s, opt_: make(map[string]interface{})}
 
480
        c.training = training
 
481
        return c
 
482
}
 
483
 
 
484
// Data sets the optional parameter "data": mybucket/mydata resource in
 
485
// Google Storage
 
486
func (c *TrainingInsertCall) Data(data string) *TrainingInsertCall {
 
487
        c.opt_["data"] = data
 
488
        return c
 
489
}
 
490
 
 
491
// Fields allows partial responses to be retrieved.
 
492
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
493
// for more information.
 
494
func (c *TrainingInsertCall) Fields(s ...googleapi.Field) *TrainingInsertCall {
 
495
        c.opt_["fields"] = googleapi.CombineFields(s)
 
496
        return c
 
497
}
 
498
 
 
499
func (c *TrainingInsertCall) Do() (*Training, error) {
 
500
        var body io.Reader = nil
 
501
        body, err := googleapi.WithoutDataWrapper.JSONReader(c.training)
 
502
        if err != nil {
 
503
                return nil, err
 
504
        }
 
505
        ctype := "application/json"
 
506
        params := make(url.Values)
 
507
        params.Set("alt", "json")
 
508
        if v, ok := c.opt_["data"]; ok {
 
509
                params.Set("data", fmt.Sprintf("%v", v))
 
510
        }
 
511
        if v, ok := c.opt_["fields"]; ok {
 
512
                params.Set("fields", fmt.Sprintf("%v", v))
 
513
        }
 
514
        urls := googleapi.ResolveRelative(c.s.BasePath, "training")
 
515
        urls += "?" + params.Encode()
 
516
        req, _ := http.NewRequest("POST", urls, body)
 
517
        googleapi.SetOpaque(req.URL)
 
518
        req.Header.Set("Content-Type", ctype)
 
519
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
520
        res, err := c.s.client.Do(req)
 
521
        if err != nil {
 
522
                return nil, err
 
523
        }
 
524
        defer googleapi.CloseBody(res)
 
525
        if err := googleapi.CheckResponse(res); err != nil {
 
526
                return nil, err
 
527
        }
 
528
        var ret *Training
 
529
        if err := json.NewDecoder(res.Body).Decode(&ret); err != nil {
 
530
                return nil, err
 
531
        }
 
532
        return ret, nil
 
533
        // {
 
534
        //   "description": "Begin training your model",
 
535
        //   "httpMethod": "POST",
 
536
        //   "id": "prediction.training.insert",
 
537
        //   "parameters": {
 
538
        //     "data": {
 
539
        //       "description": "mybucket/mydata resource in Google Storage",
 
540
        //       "location": "query",
 
541
        //       "type": "string"
 
542
        //     }
 
543
        //   },
 
544
        //   "path": "training",
 
545
        //   "request": {
 
546
        //     "$ref": "Training"
 
547
        //   },
 
548
        //   "response": {
 
549
        //     "$ref": "Training"
 
550
        //   },
 
551
        //   "scopes": [
 
552
        //     "https://www.googleapis.com/auth/devstorage.full_control",
 
553
        //     "https://www.googleapis.com/auth/devstorage.read_only",
 
554
        //     "https://www.googleapis.com/auth/devstorage.read_write",
 
555
        //     "https://www.googleapis.com/auth/prediction"
 
556
        //   ]
 
557
        // }
 
558
 
 
559
}
 
560
 
 
561
// method id "prediction.training.update":
 
562
 
 
563
type TrainingUpdateCall struct {
 
564
        s      *Service
 
565
        data   string
 
566
        update *Update
 
567
        opt_   map[string]interface{}
 
568
}
 
569
 
 
570
// Update: Add new data to a trained model
 
571
func (r *TrainingService) Update(data string, update *Update) *TrainingUpdateCall {
 
572
        c := &TrainingUpdateCall{s: r.s, opt_: make(map[string]interface{})}
 
573
        c.data = data
 
574
        c.update = update
 
575
        return c
 
576
}
 
577
 
 
578
// Fields allows partial responses to be retrieved.
 
579
// See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
 
580
// for more information.
 
581
func (c *TrainingUpdateCall) Fields(s ...googleapi.Field) *TrainingUpdateCall {
 
582
        c.opt_["fields"] = googleapi.CombineFields(s)
 
583
        return c
 
584
}
 
585
 
 
586
func (c *TrainingUpdateCall) Do() (*Training, error) {
 
587
        var body io.Reader = nil
 
588
        body, err := googleapi.WithoutDataWrapper.JSONReader(c.update)
 
589
        if err != nil {
 
590
                return nil, err
 
591
        }
 
592
        ctype := "application/json"
 
593
        params := make(url.Values)
 
594
        params.Set("alt", "json")
 
595
        if v, ok := c.opt_["fields"]; ok {
 
596
                params.Set("fields", fmt.Sprintf("%v", v))
 
597
        }
 
598
        urls := googleapi.ResolveRelative(c.s.BasePath, "training/{data}")
 
599
        urls += "?" + params.Encode()
 
600
        req, _ := http.NewRequest("PUT", urls, body)
 
601
        googleapi.Expand(req.URL, map[string]string{
 
602
                "data": c.data,
 
603
        })
 
604
        req.Header.Set("Content-Type", ctype)
 
605
        req.Header.Set("User-Agent", "google-api-go-client/0.5")
 
606
        res, err := c.s.client.Do(req)
 
607
        if err != nil {
 
608
                return nil, err
 
609
        }
 
610
        defer googleapi.CloseBody(res)
 
611
        if err := googleapi.CheckResponse(res); err != nil {
 
612
                return nil, err
 
613
        }
 
614
        var ret *Training
 
615
        if err := json.NewDecoder(res.Body).Decode(&ret); err != nil {
 
616
                return nil, err
 
617
        }
 
618
        return ret, nil
 
619
        // {
 
620
        //   "description": "Add new data to a trained model",
 
621
        //   "httpMethod": "PUT",
 
622
        //   "id": "prediction.training.update",
 
623
        //   "parameterOrder": [
 
624
        //     "data"
 
625
        //   ],
 
626
        //   "parameters": {
 
627
        //     "data": {
 
628
        //       "description": "mybucket/mydata resource in Google Storage",
 
629
        //       "location": "path",
 
630
        //       "required": true,
 
631
        //       "type": "string"
 
632
        //     }
 
633
        //   },
 
634
        //   "path": "training/{data}",
 
635
        //   "request": {
 
636
        //     "$ref": "Update"
 
637
        //   },
 
638
        //   "response": {
 
639
        //     "$ref": "Training"
 
640
        //   },
 
641
        //   "scopes": [
 
642
        //     "https://www.googleapis.com/auth/prediction"
 
643
        //   ]
 
644
        // }
 
645
 
 
646
}