Repository navigation
Expand file tree
/
Copy pathworkflow.json
More file actions
52 lines (52 loc) · 2.03 KB
/
Copy pathworkflow.json
File metadata and controls
52 lines (52 loc) · 2.03 KB
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
{
"package_format": "tin-workflow-package-v1",
"definition": {
"key": "example.order_classification",
"title": "Classify fixture orders",
"description": "Filter fixture orders, classify the selected records with one declared model call, validate and report.",
"version": "1.0.0",
"executor": "workflow.code",
"schedule_modes": ["on_demand"],
"input_schema": {
"type": "object",
"additionalProperties": false,
"properties": {
"project_id": {"type": "string", "format": "uuid"},
"minimum_cents": {"type": "integer", "minimum": 0, "maximum": 100000, "default": 1000}
},
"required": ["project_id"]
},
"code": {
"runtime": "python3.12.8-stdlib-v1",
"entrypoint": "main.py",
"files": ["main.py", "fixtures/orders.json"],
"timeout_seconds": 60,
"model_routes": {
"classification": {
"provider": "openai", "model": "gpt-6-luna",
"max_calls": 1, "max_input_bytes": 4096, "max_output_tokens": 512
}
},
"output": {
"kind": "project.artifact", "path": "reports/custom/ORDER_CLASSIFICATION.md",
"media_type": "text/markdown", "max_bytes": 8000
}
},
"presentation": {
"flow": {
"direction": "TD",
"nodes": [
{"id": "filter", "kind": "step", "label": "Keep the larger orders", "fact": "fixture orders at or above your minimum"},
{"id": "classify", "kind": "step", "label": "Classify each order", "fact": "one model call: small, medium or large"},
{"id": "check", "kind": "step", "label": "Check every label", "fact": "same orders back, and the amount rule holds"},
{"id": "report", "kind": "receipt", "label": "Classified orders in Files", "fact": "reports/custom/ORDER_CLASSIFICATION.md"}
],
"edges": [
{"from": "filter", "to": "classify", "kind": "call"},
{"from": "classify", "to": "check", "kind": "call"},
{"from": "check", "to": "report", "kind": "call"}
]
}
}
}
}