-
Notifications
You must be signed in to change notification settings - Fork 3
/
INPUT_SCHEMA.json
107 lines (107 loc) · 4.63 KB
/
INPUT_SCHEMA.json
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
{
"title": "Duplications checker input",
"type": "object",
"schemaVersion": 1,
"required": ["fields"],
"properties": {
"datasetId": {
"title": "Dataset ID",
"type": "string",
"description": "Id of dataset where the data are located. If you need to use other input types like Key value store or raw JSON, look at `Other data sources`",
"editor": "textfield",
"example": "s5NJ77qFv8b4osiGR"
},
"checkOnlyCleanItems": {
"title": "Check only clean dataset items",
"type": "boolean",
"description": "Only clean dataset items will be loaded and use for duplications checking if `datasetId` option is provided.",
"default": false
},
"fields": {
"title": "Fields",
"type": "array",
"description": "List of fields in each item that will be checked for duplicates. Each given field must not be nested and it should contain only simple value (string or number). You can prepare your data with preCheckFunction.",
"editor": "stringList",
"default": []
},
"preCheckFunction":{
"title": "Pre-check function",
"type": "string",
"description": "You can specify which fields should display in the debug OUTPUT to identify bad items. By default it shows all fields which may make it unnecessary big.",
"editor": "javascript",
"example": "(data) => data.map((item) => ({ url: item.url, imageSrc: item.images && item.images[0] ? item.images[0].src : null }))"
},
"minDuplications":{
"title": "Minimum duplications",
"type": "integer",
"description": "Minimum occurences to be included in the report. Defaults to 2",
"minimum": 2,
"default": 2,
"unit": "occurrences",
"example": 2
},
"showIndexes":{
"title": "Show indexes",
"type": "boolean",
"description": "Indexes of the duplicate items will be shown in the OUTPUT report. Set to false if you don't need them.",
"default": true,
"groupCaption": "Show options",
"groupDescription": "Showing more will help you debug but uses more memory."
},
"showItems":{
"title": "Show items",
"type": "boolean",
"description": "Duplicate items will be pushed to a dataset. Set to false if you don't need them.",
"default": true
},
"showMissing":{
"title": "Show missing fields",
"type": "boolean",
"description": "Items where the values for the `field` is missing or is `null` or `''` will be included in the report.",
"default": true
},
"limit":{
"title": "Limit",
"type": "integer",
"description": "How many items will be checked. Default is all",
"minimum": 1,
"unit": "items",
"example": 1000,
"sectionCaption": "Dataset pagination options",
"sectionDescription": "Allows you to pick parts of the dataset to check."
},
"offset":{
"title": "Offset",
"type": "integer",
"description": "From which item the checking will start. Use with limit to check specific items.",
"minimum": 1,
"unit": "items",
"example": 20000
},
"batchSize":{
"title": "Batch Size",
"type": "integer",
"description": "You can change number of loaded and processed items in each batch. This is only needed if you have really huge items.",
"default": 1000,
"minimum": 1,
"unit": "items",
"example": 5000
},
"keyValueStoreRecord": {
"title": "Key value store Record",
"type": "string",
"description": "ID and record key if you want to load from KV store. Format is `{keyValueStoreId}+{recordKey}`, e.g. `s5NJ77qFv8b4osiGR+MY-KEY`",
"editor": "textfield",
"example": "s5NJ77qFv8b4osiGR+MY-KEY",
"sectionCaption": "Other data sources",
"sectionDescription": "Allows you to load from Key value store or arbitrary JSON."
},
"rawData": {
"title": "Raw Data",
"type": "array",
"description": "Raw JSON array you want to check.",
"editor": "json",
"example": [{"url": "https://example.com","price": 20},{"url": "https://google.com","price": 30}]
}
}
}