Skip to content

Commit 8e468ea

Browse files
authored
Create README.md
1 parent bc7be8f commit 8e468ea

File tree

1 file changed

+25
-0
lines changed
  • Server-Side Components/Background Scripts/Tag Incident Outliers

1 file changed

+25
-0
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Tag incident resolution outliers by z score
2+
3+
## What this solves
4+
Average resolution time hides long-tail outliers. This script calculates mean and standard deviation of resolution minutes and tags incidents whose z score exceeds a threshold, helping teams investigate anomalies.
5+
6+
## Where to use
7+
Run as a Background Script or convert into a Scheduled Job for periodic tagging.
8+
9+
## How it works
10+
- Uses `GlideAggregate` to compute count, mean, and approximate variance
11+
- Calculates z score per resolved incident
12+
- Sets a flag field or work note on outliers above a configurable z threshold
13+
14+
## Configure
15+
- `DAYS`: look-back window
16+
- `Z_THRESHOLD`: default 2.5
17+
- `FLAG_FIELD`: field to set, for example a custom boolean `u_outlier`
18+
19+
## References
20+
- GlideAggregate API
21+
https://www.servicenow.com/docs/bundle/zurich-api-reference/page/app-store/dev_portal/API_reference/GlideAggregate/concept/c_GlideAggregateAPI.html
22+
- GlideRecord API
23+
https://www.servicenow.com/docs/bundle/zurich-api-reference/page/app-store/dev_portal/API_reference/GlideRecord/concept/c_GlideRecordAPI.html
24+
- GlideDateTime API
25+
https://www.servicenow.com/docs/bundle/zurich-api-reference/page/app-store/dev_portal/API_reference/GlideDateTime/concept/c_GlideDateTimeAPI.html

0 commit comments

Comments
 (0)