Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 8 Next »

What is An Event?

Events are 

Basic Event Specification

The following code demonstrates how to specify a basic event (Note: The sample event specification and sample event output below is extracted from a MySql Database Source the full content of which can be viewed here.):

Basic Event Specification Example
{
    ...
    "events" : [
      {
        "entity1" : "$metadata.offense,$metadata.method",
        "verb" : "reported",
        "verb_category" : "crime",
        "time_start" : "$metadata.reportdatetime", 
        "geo_index" : "Location",
        "geotag" : {
           "latitude" : "$metadata.latitude",
           "longitude" : "$metadata.longitude"}
      },
    ],
    ...
}

In the basic example above the following fields have been specified:

  • entity1
    A free form text field containing information about the event "subject", i.e. an entity's disambiguous name. 
  • entity1_index
    If present this is the "gazateer_index" field of the entity matching the entity1 disambiguous name above.
  • verb
    A free form text field describing the event "verb"
  • verb_category
    Also a free form text field describing the event "verb", but intended to group related verbs together (eg "travel" for verbs: "flew", "drove")
  • geoindex
    If the event geotag maps into an entity from the parent document then this field is the "gazateer_index" of that entity
  • geotag
    • latitude
      String containing a floating point representation of latitude
    • longitude
      String containing a floating point representation of longitude

The result of the event specification above can be seen in the sample output below:

Example Event Output
{
    ...
    "events" : [
      {
         "entity1" : "robbery gun",
         "entity1_index" : "robbery gun/criminalactivity",
         "verb" : "reported",
         "verb_category" : "crime",
         "geotag" : {
             "latitude" : "38.9051666534795",
             "longitude" : "-77.0121735726172"
         },
         "geo_index" : "1100 b/o 1st st nw washington dc/place",
         "event_type" : "Event"
      }
    ],
    ...
}

In the sample output above please note that the Infinit.e harvester automatically generates the following fields as appropriate:

  • event_type
    "Event", "Fact", "Summary"
    The "event_type" field sub-categorizes the "event" object into one of three types, "Event", "Fact", or "Summary". Examples provided below should make the distinction clearer, but it can be simply described as follows:
    • "Event": link multiple entities (via "entity1_index", "entity2_index", "geo_index") and represent a transient activity (eg travel)
    • "Fact": link multiple entities like "Events" but represent (transient or permanent) relationships (eg being president)
    • "Summary": generally link 1 entity to a free text (eg a quotation: "Obama says...").
Specifying Additive Events

The Structured Analysis Harvester supports the specification of events...

Specifying Multiplicative Events

The Structured Analysis Harvester supports the creation of events that are specified 

Multiplicative Event Specification Example
{
    ...
    "events" : [
       {
          "iterateOver" : "entity1/entity2/geo_index",
          "verb" : "attacked",
          "verb_category" : "assault/attack",
          "entity1" : "PersonPerpetrator",
          "entity2" : "VictimType",
          "geo_index" : "Location",
          "time_start" : "$SCRIPT( return _doc.metadata.incidentdate[0]; )"
       },
    ],
    ...
}

Blah de blah, blah

Multiplicative Event Source Example
{
    ...
    "entities" : [
       {
            "actual_name" : "Batticaloa,North Eastern Province,Sri Lanka",
            "dimension" : "Where",
            "disambiguous_name" : "Batticaloa,North Eastern Province,Sri Lanka",
            "doccount" : NumberLong(18),
            "frequency" : 1,
            "gazateer_index" : "batticaloa,north eastern province,sri lanka/location",
            "geotag" : {
               "latitude" : "7.7166667",
               "longitude" : "81.7"
            },
            "totalfrequency" : NumberLong(18),
            "type" : "Location"
       },
       {
            "actual_name" : "Targeted, Police, Adult from Sri Lanka",
            "dimension" : "Who",
            "disambiguous_name" : "Targeted, Police, Adult from Sri Lanka",
            "doccount" : NumberLong(47),
            "frequency" : 3,
            "gazateer_index" : "targeted, police, adult from sri lanka/victimtype",
            "totalfrequency" : NumberLong(161),
            "type" : "VictimType"
       },
       {
            "actual_name" : "Targeted, Military, Adult, Combatant from Sri Lanka",
            "dimension" : "Who",
            "disambiguous_name" : "Targeted, Military, Adult, Combatant from Sri Lanka",
            "doccount" : NumberLong(20),
            "frequency" : 1,
            "gazateer_index" : "targeted, military, adult, combatant from sri lanka/victimtype",
            "totalfrequency" : NumberLong(147),
            "type" : "VictimType"
       },
       {
            "actual_name" : "Secular/Political/Anarchist from Sri Lanka",
            "dimension" : "Who",
            "disambiguous_name" : "Secular/Political/Anarchist from Sri Lanka",
            "doccount" : NumberLong(200),
            "frequency" : 1,
            "gazateer_index" : "secular/political/anarchist from sri lanka/personperpetrator",
            "totalfrequency" : NumberLong(200),
            "type" : "PersonPerpetrator"
        },
        ...
    ],
    ...
}

Blah de blah, blah

Multiplicative Event Output Example
{
    ...
    "events" : [
        {
           "entity1" : "secular/political/anarchist from sri lanka",
           "entity1_index" : "secular/political/anarchist from sri lanka/personperpetrator",
           "verb" : "attacked",
           "verb_category" : "assault/attack",
           "entity2" : "targeted, police, adult from sri lanka",
           "entity2_index" : "targeted, police, adult from sri lanka/victimtype",
           "time_start" : "09/07/2005",
           "geotag" : {
                "latitude" : "7.7166667",
                "longitude" : "81.7"
           },
           "geo_index" : "batticaloa,north eastern province,sri lanka/location",
           "event_type" : "Event"
        },
        {
           "entity1" : "secular/political/anarchist from sri lanka",
           "entity1_index" : "secular/political/anarchist from sri lanka/personperpetrator",
           "verb" : "attacked",
           "verb_category" : "assault/attack",
           "entity2" : "targeted, military, adult, combatant from sri lanka",
           "entity2_index" : "targeted, military, adult, combatant from sri lanka/victimtype",
           "time_start" : "09/07/2005",
           "geotag" : {
                "latitude" : "7.7166667",
                "longitude" : "81.7"
           },
           "geo_index" : "batticaloa,north eastern province,sri lanka/location",
           "event_type" : "Event"
        }
    ],
    ...
}
Further Reading
  • No labels