Skip to content

Commit 796035e

Browse files
authored
Add roll up guide (#178)
1 parent 4f13484 commit 796035e

35 files changed

Lines changed: 655 additions & 5 deletions

File tree

docs/docs/Roll-Up-Guide.md

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
**NOTICE:** This software (or technical data) was produced for the U.S. Government under contract,
2+
and is subject to the Rights in Data-General Clause 52.227-14, Alt. IV (DEC 2007). Copyright 2023
3+
The MITRE Corporation. All Rights Reserved.
4+
5+
6+
# Roll Up Overview
7+
8+
The Workflow Manager can be configured to replace the values of track and detection properties after
9+
receiving tracks and detections from a component. This feature is commonly used to replace specific
10+
terms with a more general category. For example, the "CLASSIFICATION" property may be set to "car",
11+
"bus", and "truck". Those are all a kind of "vehicle". To use this feature, a JSON file in the
12+
format described below must be created. Then, the `ROLL_UP_FILE` job property must be set to the
13+
file path where that file is located.
14+
15+
16+
# Roll Up File
17+
18+
The JSON below is an example of a roll up file.
19+
20+
```json
21+
[
22+
{
23+
"propertyToProcess": "CLASSIFICATION",
24+
"originalPropertyCopy": "ORIGINAL CLASSIFICATION",
25+
"groups": [
26+
{
27+
"rollUp": "vehicle",
28+
"members": [
29+
"truck",
30+
"car",
31+
"bus"
32+
]
33+
},
34+
{
35+
"rollUp": "sandwich",
36+
"members": [
37+
"grilled cheese",
38+
"reuben",
39+
"hamburger",
40+
"hot dog"
41+
]
42+
}
43+
]
44+
},
45+
{
46+
"propertyToProcess": "COLOR",
47+
"groups": [
48+
{
49+
"rollUp": "purple",
50+
"members": [
51+
"indigo"
52+
]
53+
}
54+
]
55+
},
56+
{
57+
"propertyToProcess": "PROP3",
58+
"groups": [
59+
{
60+
"rollUp": "new name",
61+
"members": [
62+
"old name"
63+
]
64+
}
65+
]
66+
}
67+
]
68+
```
69+
70+
At the top level, the roll up file contains an array where each element defines a detection property
71+
that should be modified. In this example, there is one element for "CLASSIFICATION", one for
72+
"COLOR", and one for "PROP3". Each element contains the following fields:
73+
74+
- `propertyToProcess`: (Required) A detection property key. The value will be modified according to
75+
the `groups` key.
76+
- `originalPropertyCopy`: (Optional) Copies the value of `propertyToProcess` prior to roll up to
77+
another property. The copy is made even if the property is not modified.
78+
- `groups`: (Optional) Array containing an element for each roll up name. If the value of the
79+
detection property specified by `propertyToProcess` matches a string listed in `members`, it
80+
will be replaced by the content of the `rollUp` property.
81+
82+
In the example above, the value of the "CLASSIFICATION" detection property will be copied to
83+
"ORIGINAL CLASSIFICATION" before the roll up is performed. If the "CLASSIFICATION" detection
84+
property is set to "truck", "car", or "bus", the value of the detection property will be replaced
85+
by "vehicle".
86+
87+
In a real use case there will generally be multiple roll up groups for a single detection property.
88+
The "sandwich" group shows how to include an additional mapping for the same "CLASSIFICATION"
89+
property. The "COLOR" and "PROP3" sections show examples of how to apply roll up to different
90+
detection properties with different configurations.
91+
92+
If the roll up above was applied to these detection properties:
93+
94+
```json
95+
{
96+
"CLASSIFICATION": "truck",
97+
"COLOR": "red",
98+
"PROP3": "truck",
99+
"PROP4": "other"
100+
}
101+
```
102+
103+
it would result in:
104+
105+
```json
106+
{
107+
"CLASSIFICATION": "vehicle",
108+
"ORIGINAL CLASSIFICATION": "truck",
109+
"COLOR": "red",
110+
"PROP3": "truck",
111+
"PROP4": "other"
112+
}
113+
```
114+
115+
"COLOR" was not modified since it does not define a roll up group with "red" as a member. "PROP3"
116+
was not modified because only the "CLASSIFICATION" property has a roll up group with "truck" as a
117+
member. "PROP4" was not modified because it is not in the roll up file.

docs/mkdocs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ pages:
2727
- Markup Guide: Markup-Guide.md
2828
- TiesDb Guide: TiesDb-Guide.md
2929
- Trigger Guide: Trigger-Guide.md
30+
- Roll Up Guide: Roll-Up-Guide.md
3031
- Health Check Guide: Health-Check-Guide.md
3132
- REST API: REST-API.md
3233
- Component Development:

docs/site/404.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@
114114
</li>
115115
<li class="">
116116

117+
<a class="" href="/Roll-Up-Guide/index.html">Roll Up Guide</a>
118+
</li>
119+
<li class="">
120+
117121
<a class="" href="/Health-Check-Guide/index.html">Health Check Guide</a>
118122
</li>
119123
<li class="">

docs/site/Acknowledgements/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,10 @@
124124
</li>
125125
<li class="">
126126

127+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
128+
</li>
129+
<li class="">
130+
127131
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
128132
</li>
129133
<li class="">

docs/site/Admin-Guide/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,10 @@
143143
</li>
144144
<li class="">
145145

146+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
147+
</li>
148+
<li class="">
149+
146150
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
147151
</li>
148152
<li class="">

docs/site/CPP-Batch-Component-API/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@
121121
</li>
122122
<li class="">
123123

124+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
125+
</li>
126+
<li class="">
127+
124128
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
125129
</li>
126130
<li class="">

docs/site/CPP-Streaming-Component-API/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@
121121
</li>
122122
<li class="">
123123

124+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
125+
</li>
126+
<li class="">
127+
124128
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
125129
</li>
126130
<li class="">

docs/site/Component-API-Overview/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@
121121
</li>
122122
<li class="">
123123

124+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
125+
</li>
126+
<li class="">
127+
124128
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
125129
</li>
126130
<li class="">

docs/site/Component-Descriptor-Reference/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@
121121
</li>
122122
<li class="">
123123

124+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
125+
</li>
126+
<li class="">
127+
124128
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
125129
</li>
126130
<li class="">

docs/site/Contributor-Guide/index.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@
121121
</li>
122122
<li class="">
123123

124+
<a class="" href="../Roll-Up-Guide/index.html">Roll Up Guide</a>
125+
</li>
126+
<li class="">
127+
124128
<a class="" href="../Health-Check-Guide/index.html">Health Check Guide</a>
125129
</li>
126130
<li class="">

0 commit comments

Comments
 (0)