File: Process.yml

package info (click to toggle)
python-schema-salad 8.9.20251102115403-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,060 kB
  • sloc: python: 19,247; cpp: 2,631; cs: 1,869; java: 1,341; makefile: 187; xml: 184; sh: 103; javascript: 46
file content (543 lines) | stat: -rw-r--r-- 16,131 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
$base: "https://w3id.org/cwl/cwl#"

$namespaces:
  cwl: "https://w3id.org/cwl/cwl#"
  sld: "https://w3id.org/cwl/salad#"
  rdfs: "http://www.w3.org/2000/01/rdf-schema#"

$graph:

- name: "Common Workflow Language, v1.0"
  type: documentation
  doc: {$include: concepts.md}

- $import: "metaschema_base.yml"

- $import: Base.yml

- name: BaseTypesDoc
  type: documentation
  doc: |
    ## Base types
  docChild:
    - "#CWLType"
    - "#Process"

- type: enum
  name: CWLVersion
  doc: "Version symbols for published CWL document versions."
  symbols:
    - cwl:draft-2
    - cwl:draft-3.dev1
    - cwl:draft-3.dev2
    - cwl:draft-3.dev3
    - cwl:draft-3.dev4
    - cwl:draft-3.dev5
    - cwl:draft-3
    - cwl:draft-4.dev1
    - cwl:draft-4.dev2
    - cwl:draft-4.dev3
    - cwl:v1.0.dev4
    - cwl:v1.0


- name: SchemaBase
  type: record
  abstract: true
  fields:
    - name: label
      type:
        - "null"
        - string
      jsonldPredicate: "rdfs:label"
      doc: "A short, human-readable label of this object."


- name: Parameter
  type: record
  extends: SchemaBase
  abstract: true
  doc: |
    Define an input or output parameter to a process.

  fields:
    - name: secondaryFiles
      type:
        - "null"
        - string
        - Expression
        - type: array
          items: [string, Expression]
      jsonldPredicate: "cwl:secondaryFiles"
      doc: |
        Only valid when `type: File` or is an array of `items: File`.

        Provides a pattern or expression specifying files or directories that
        must be included alongside the primary file.  All listed secondary
        files must be present.  An implementation may fail workflow execution
        if an expected secondary file does not exist.

        If the value is an expression, the value of `self` in the expression
        must be the primary input or output File object to which this binding
        applies.  The `basename`, `nameroot` and `nameext` fields must be
        present in `self`.  For `CommandLineTool` outputs the `path` field must
        also be present.  The expression must return a filename string relative
        to the path to the primary File, a File or Directory object with either
        `path` or `location` and `basename` fields set, or an array consisting
        of strings or File or Directory objects.  It is legal to reference an
        unchanged File or Directory object taken from input as a secondaryFile.

        To work on non-filename-preserving storage systems, portable tool
        descriptions should avoid constructing new values from `location`, but
        should construct relative references using `basename` or `nameroot`
        instead.

        If a value in `secondaryFiles` is a string that is not an expression,
        it specifies that the following pattern should be applied to the path
        of the primary file to yield a filename relative to the primary File:

          1. If string begins with one or more caret `^` characters, for each
            caret, remove the last file extension from the path (the last
            period `.` and all following characters).  If there are no file
            extensions, the path is unchanged.
          2. Append the remainder of the string to the end of the file path.

    - name: streamable
      type: boolean?
      default: false
      doc: |
        Only valid when `type: File` or is an array of `items: File`.

        A value of `true` indicates that the file is read or written
        sequentially without seeking.  An implementation may use this flag to
        indicate whether it is valid to stream file contents using a named
        pipe.  Default: `false`.

    - name: doc
      type:
        - string?
        - string[]?
      doc: "A documentation string for this type, or an array of strings which should be concatenated."
      jsonldPredicate: "rdfs:comment"


- type: enum
  name: Expression
  doc: |
    'Expression' is not a real type.  It indicates that a field must allow
    runtime parameter references.  If [InlineJavascriptRequirement](#InlineJavascriptRequirement)
    is declared and supported by the platform, the field must also allow
    Javascript expressions.
  symbols:
    - cwl:ExpressionPlaceholder


- name: InputBinding
  type: record
  abstract: true
  fields:
    - name: loadContents
      type:
        - "null"
        - boolean
      jsonldPredicate: "cwl:loadContents"
      doc: |
        Only valid when `type: File` or is an array of `items: File`.

        Read up to the first 64 KiB of text from the file and place it in the
        "contents" field of the file object for use by expressions.


- name: OutputBinding
  type: record
  abstract: true


- name: InputSchema
  extends: SchemaBase
  type: record
  abstract: true


- name: OutputSchema
  extends: SchemaBase
  type: record
  abstract: true


- name: InputRecordField
  type: record
  extends: CWLRecordField
  specialize:
    - specializeFrom: CWLRecordSchema
      specializeTo: InputRecordSchema
    - specializeFrom: "sld:EnumSchema"
      specializeTo: InputEnumSchema
    - specializeFrom: CWLArraySchema
      specializeTo: InputArraySchema
    - specializeFrom: "sld:PrimitiveType"
      specializeTo: CWLType
  fields:
    - name: inputBinding
      type: InputBinding?
      jsonldPredicate: "cwl:inputBinding"
    - name: label
      type: string?
      jsonldPredicate: "rdfs:label"
      doc: "A short, human-readable label of this process object."


- name: InputRecordSchema
  type: record
  extends: [CWLRecordSchema, InputSchema]
  specialize:
    - specializeFrom: CWLRecordField
      specializeTo: InputRecordField
  fields:
    - name: name
      type: string?
      jsonldPredicate: "@id"


- name: InputEnumSchema
  type: record
  extends: ["sld:EnumSchema", InputSchema]
  fields:
    - name: name
      type: string?
      jsonldPredicate: "@id"
    - name: inputBinding
      type: InputBinding?
      jsonldPredicate: "cwl:inputBinding"


- name: InputArraySchema
  type: record
  extends: [CWLArraySchema, InputSchema]
  specialize:
    - specializeFrom: CWLRecordSchema
      specializeTo: InputRecordSchema
    - specializeFrom: "sld:EnumSchema"
      specializeTo: InputEnumSchema
    - specializeFrom: CWLArraySchema
      specializeTo: InputArraySchema
    - specializeFrom: "sld:PrimitiveType"
      specializeTo: CWLType
  fields:
    - name: inputBinding
      type: InputBinding?
      jsonldPredicate: "cwl:inputBinding"


- name: OutputRecordField
  type: record
  extends: CWLRecordField
  specialize:
    - specializeFrom: CWLRecordSchema
      specializeTo: OutputRecordSchema
    - specializeFrom: "sld:EnumSchema"
      specializeTo: OutputEnumSchema
    - specializeFrom: CWLArraySchema
      specializeTo: OutputArraySchema
    - specializeFrom: "sld:PrimitiveType"
      specializeTo: CWLType
  fields:
    - name: outputBinding
      type: OutputBinding?
      jsonldPredicate: "cwl:outputBinding"


- name: OutputRecordSchema
  type: record
  extends: [CWLRecordSchema, "#OutputSchema"]
  docParent: "#OutputParameter"
  specialize:
    - specializeFrom: CWLRecordField
      specializeTo: OutputRecordField


- name: OutputEnumSchema
  type: record
  extends: ["sld:EnumSchema", OutputSchema]
  docParent: "#OutputParameter"
  fields:
    - name: outputBinding
      type: OutputBinding?
      jsonldPredicate: "cwl:outputBinding"

- name: OutputArraySchema
  type: record
  extends: [CWLArraySchema, OutputSchema]
  docParent: "#OutputParameter"
  specialize:
    - specializeFrom: CWLRecordSchema
      specializeTo: OutputRecordSchema
    - specializeFrom: "sld:EnumSchema"
      specializeTo: OutputEnumSchema
    - specializeFrom: CWLArraySchema
      specializeTo: OutputArraySchema
    - specializeFrom: "sld:PrimitiveType"
      specializeTo: CWLType
  fields:
    - name: outputBinding
      type: OutputBinding?
      jsonldPredicate: "cwl:outputBinding"


- name: InputParameter
  type: record
  extends: Parameter
  fields:
    - name: id
      type: string
      jsonldPredicate: "@id"
      doc: "The unique identifier for this parameter object."

    - name: format
      type:
        - "null"
        - string
        - type: array
          items: string
        - Expression
      jsonldPredicate:
        _id: cwl:format
        _type: "@id"
        identity: true
        noLinkCheck: true
      doc: |
        Only valid when `type: File` or is an array of `items: File`.

        This must be one or more IRIs of concept nodes
        that represents file formats which are allowed as input to this
        parameter, preferrably defined within an ontology.  If no ontology is
        available, file formats may be tested by exact match.


    - name: inputBinding
      type: InputBinding?
      jsonldPredicate: "cwl:inputBinding"
      doc: |
        Describes how to handle the inputs of a process and convert them
        into a concrete form for execution, such as command line parameters.

    - name: default
      type: CWLObjectType?
      jsonldPredicate:
        _id: "cwl:default"
        _container: "@list"
        noLinkCheck: true
      doc: |
        The default value to use for this parameter if the parameter is missing
        from the input object, or if the value of the parameter in the input
        object is `null`.  Default values are applied before evaluating expressions
        (e.g. dependent `valueFrom` fields).

    - name: type
      type:
        - "null"
        - CWLType
        - InputRecordSchema
        - InputEnumSchema
        - InputArraySchema
        - string
        - type: array
          items:
            - CWLType
            - InputRecordSchema
            - InputEnumSchema
            - InputArraySchema
            - string
      jsonldPredicate:
        "_id": "sld:type"
        "_type": "@vocab"
        refScope: 2
        typeDSL: True
      doc: |
        Specify valid types of data that may be assigned to this parameter.

- name: OutputParameter
  type: record
  extends: Parameter
  fields:
    - name: id
      type: string
      jsonldPredicate: "@id"
      doc: "The unique identifier for this parameter object."
    - name: outputBinding
      type: OutputBinding?
      jsonldPredicate: "cwl:outputBinding"
      doc: |
        Describes how to handle the outputs of a process.
    - name: format
      type:
        - "null"
        - string
        - Expression
      jsonldPredicate:
        _id: cwl:format
        _type: "@id"
        identity: true
        noLinkCheck: true
      doc: |
        Only valid when `type: File` or is an array of `items: File`.

        This is the file format that will be assigned to
        the output parameter.



- type: record
  name: ProcessRequirement
  abstract: true
  doc: |
    A process requirement declares a prerequisite that may or must be fulfilled
    before executing a process.  See [`Process.hints`](#process) and
    [`Process.requirements`](#process).

    Process requirements are the primary mechanism for specifying extensions to
    the CWL core specification.


- type: record
  name: Process
  abstract: true
  doc: |

    The base executable type in CWL is the `Process` object defined by the
    document.  Note that the `Process` object is abstract and cannot be
    directly executed.

  fields:
    - name: id
      type: string?
      jsonldPredicate: "@id"
      doc: "The unique identifier for this process object."
    - name: inputs
      type:
        type: array
        items: InputParameter
      jsonldPredicate:
        _id: "cwl:inputs"
        mapSubject: id
        mapPredicate: type
      doc: |
        Defines the input parameters of the process.  The process is ready to
        run when all required input parameters are associated with concrete
        values.  Input parameters include a schema for each parameter which is
        used to validate the input object.  It may also be used to build a user
        interface for constructing the input object.

        When accepting an input object, all input parameters must have a value.
        If an input parameter is missing from the input object, it must be
        assigned a value of `null` (or the value of `default` for that
        parameter, if provided) for the purposes of validation and evaluation
        of expressions.

    - name: outputs
      type:
        type: array
        items: OutputParameter
      jsonldPredicate:
        _id: "cwl:outputs"
        mapSubject: id
        mapPredicate: type
      doc: |
        Defines the parameters representing the output of the process.  May be
        used to generate and/or validate the output object.
    - name: requirements
      type: ProcessRequirement[]?
      jsonldPredicate:
        _id: "cwl:requirements"
        mapSubject: class
      doc: |
        Declares requirements that apply to either the runtime environment or the
        workflow engine that must be met in order to execute this process.  If
        an implementation cannot satisfy all requirements, or a requirement is
        listed which is not recognized by the implementation, it is a fatal
        error and the implementation must not attempt to run the process,
        unless overridden at user option.
    - name: hints
      type:
        - "null"
        - type: array
          items: [ProcessRequirement, Any]
      doc: |
        Declares hints applying to either the runtime environment or the
        workflow engine that may be helpful in executing this process.  It is
        not an error if an implementation cannot satisfy all hints, however
        the implementation may report a warning.
      jsonldPredicate:
        _id: cwl:hints
        noLinkCheck: true
        mapSubject: class
    - name: label
      type: string?
      jsonldPredicate: "rdfs:label"
      doc: "A short, human-readable label of this process object."
    - name: doc
      type: string?
      jsonldPredicate: "rdfs:comment"
      doc: "A long, human-readable description of this process object."
    - name: cwlVersion
      type: CWLVersion?
      doc: |
        CWL document version. Always required at the document root. Not
        required for a Process embedded inside another Process.
      jsonldPredicate:
        "_id": "cwl:cwlVersion"
        "_type": "@vocab"

- name: InlineJavascriptRequirement
  type: record
  extends: ProcessRequirement
  doc: |
    Indicates that the workflow platform must support inline Javascript expressions.
    If this requirement is not present, the workflow platform must not perform expression
    interpolatation.
  fields:
    - name: class
      type:
        type: enum
        name: InlineJavascriptRequirement_class
        symbols:
          - cwl:InlineJavascriptRequirement
      doc: "Always 'InlineJavascriptRequirement'"
      jsonldPredicate:
        "_id": "@type"
        "_type": "@vocab"
    - name: expressionLib
      type: string[]?
      doc: |
        Additional code fragments that will also be inserted
        before executing the expression code.  Allows for function definitions that may
        be called from CWL expressions.


- name: SchemaDefRequirement
  type: record
  extends: ProcessRequirement
  doc: |
    This field consists of an array of type definitions which must be used when
    interpreting the `inputs` and `outputs` fields.  When a `type` field
    contain a IRI, the implementation must check if the type is defined in
    `schemaDefs` and use that definition.  If the type is not found in
    `schemaDefs`, it is an error.  The entries in `schemaDefs` must be
    processed in the order listed such that later schema definitions may refer
    to earlier schema definitions.
  fields:
    - name: class
      type:
        type: enum
        name: SchemaDefRequirement_class
        symbols:
          - cwl:SchemaDefRequirement
      doc: "Always 'SchemaDefRequirement'"
      jsonldPredicate:
        "_id": "@type"
        "_type": "@vocab"
    - name: types
      type:
        type: array
        items: InputSchema
      doc: The list of type definitions.