API - query-pattern


Query pattern for the given criteria.

Prerequisite

  • the entity code as{entity}, for example, “joe_bloggs”
  • the valid data stream code as {ds}, for example, “jb_sen01_pir”. This is optional, if it is omitted, all patterns fo the entity will return.

Method

POST

URI

/api/v1/pattern/query

Request Body

{
    "entity": "joe_bloggs",
    "ds": "jb_sen01_pir"
}

Response Sample

200 OK
[
    {
        "entity": "joe_bloggs",
        "ds": "jb_sen01_pir",
        "transitions": [
            [
                1.2,
                2.3
            ],
            [
                3.4,
                4.5
            ]
        ],
        "emissions": [
            [
                1.2,
                2.3
            ],
            [
                3.4,
                4.5
            ]
        ],
        "heat_map": [
            [
                1.2,
                2.3
            ],
            [
                3.4,
                4.5
            ]
        ],
        "trace": [
            1.2,
            2.3,
            3.4,
            4.5
        ],
        "mean_training_probablity": 123.456,
        "std_training_probablity": 1.23,
        "tga": 2.34,
        "tar": 3.45,
        "rw": 4.56,
        "emission_values": [
            1.2,
            2.3,
            3.4,
            4.5
        ],
        "n_symbols": 1,
        "n_epochs": 2,
        "n_training_days": 3,
        "training_probs": {
            "key1": 1.2,
            "key2": "abc"
        },
        "date_from": "2019-05-01 00:00:00",
        "date_to": "2019-06-01 00:00:00"
    }
]