Skip to content

Instantly share code, notes, and snippets.

@virtadpt
Created September 30, 2014 18:18
Show Gist options
  • Save virtadpt/690d420ce5f1a35841d4 to your computer and use it in GitHub Desktop.
Save virtadpt/690d420ce5f1a35841d4 to your computer and use it in GitHub Desktop.
Exocortex: Ironmonger
{
"name": "Ironmonger",
"description": "Ironmonger is a network of agents which watches the stock prices of the 20 biggest defense contractors in the United States and alerts if their stock prices jump by more than three (3) standard deviations, meaning that one or more has just won a big contract and something's coming. Send an e-mail if something happens.",
"source_url": false,
"guid": "88f6cd314e66146e2314b6860c9e91d5",
"tag_fg_color": null,
"tag_bg_color": null,
"exported_at": "2014-09-30T18:16:54Z",
"agents": [
{
"type": "Agents::PeakDetectorAgent",
"name": "Ironmonger - Watch for rapid stock price changes",
"disabled": false,
"guid": "894d29210ca3415a06226951bed5b80a",
"options": {
"expected_receive_period_in_days": "4",
"value_path": "price",
"message": "The stock price of {{name}} (symbol: {{symbol}}) has suddenly spiked to ${{price}} USD per share. What's going on?",
"std_multiple": "2"
},
"keep_events_for": 7,
"propagate_immediately": false
},
{
"type": "Agents::WebsiteAgent",
"name": "Ironmonger - Watches stock prices of defense contractors",
"disabled": false,
"guid": "e2ec929ffdf9717cdc20b91f5f9a9b59",
"options": {
"expected_update_period_in_days": "4",
"url": "http://finance.yahoo.com/webservice/v1/symbols/CACI,GR,DCP,NAV,MANT,TXT,COL,ATK,URS,KBR,XLS,UTC,GE,HON,CSC,OSK,SAIC,UTX,LLL,RTN,GD,NOC,BA,LMT/quote?format=json",
"type": "json",
"mode": "all",
"extract": {
"name": {
"path": "$.list.resources[*].resource.fields.name"
},
"symbol": {
"path": "$.list.resources[*].resource.fields.symbol"
},
"price": {
"path": "$.list.resources[*].resource.fields.price"
}
}
},
"schedule": "every_1h",
"keep_events_for": 7,
"propagate_immediately": false
},
{
"type": "Agents::EmailAgent",
"name": "Tripwire - Immediate E-mail Alerts",
"disabled": false,
"guid": "aabc3c63be0bf9f36e14017146968e36",
"options": {
"subject": "Exocortex: Tripwire Alert",
"headline": "Tripwire has detected the following events in the exocortex:",
"expected_receive_period_in_days": "14"
},
"propagate_immediately": false
}
],
"links": [
{
"source": 0,
"receiver": 2
},
{
"source": 1,
"receiver": 0
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment