View
 

Metrics

Page history last edited by Jared Peterson 3 mos ago

Most of the query calls in REST API return metrics.  It's important to understand what the various metrics mean and what impact they have on query parameters and JSON result properties.

 

Supported URL Parameters:

 

Name Description Default
ml Metric Level.  Either 0, 1, or 2.  See the table below for an explanation of each. 0
ns Normalize Score.  If normalize is set to false, the counts are used directly.  If set to true, an output probability is computed from the counts based on the total observation space of each input. false

 

Metric Levels:

 

Name Description
0 Base rollup metric.
1 Base rollup metric and the advanced metric breakdown.
2 Base rollup metric, adcanced metric breakdown, and input explanations

 

JSON Response Properties:

 

The following tables describe the JSON result properties that will be returned in the JSON result based on what metric level you specify.

 

Base Rollup Metric:

 

Name Description
m Metric.  The base rollup metric refers to the relative rank ordering metric for the result.  For example, if result A had a metric of 0.5 and result B had a metric of 0.25, we would consider result A to be twice as relavent as result B.  The base rollup metrics do not generally reflect a absolute metric, unless otherwise noted.  An example of this can be found in the "trends" API.  As the base metric, it returns the slope of a linear regression line (which is an absolute metric).  Relative metrics should not be compared across query invocations, whereas, absolute metrics can be.
mn Minimum Metric.  This will always be on the ottermost JSON object.  It specifies what the minimum metric value is across the entire result set.
mx Maximum Metric.  This will always be on the ottermost JSON object.  It specifies what the maximum metric value is across the entire result set.

 

Advance Metric Breakdown:

 

The advanced metric breakdown adds the following JSON properties to the base rollup metric properties.

 

Name Description
acn And Group Connections reflects the number of and-group input attributes (query terms) that are connected to any given output attribute (result).  This metric can be found in the advanced metric.
am Advanced Metrics.  This property contains the actual advanced metric JSON array.  The advanced metric provides raw metrics that are used to compute the rank-ordering metric (base rollup metric).
cn Connections reflects the number of input attributes (query terms) that are connected to any given output attribute (result).  This metric can be found in the advanced metric.
ct Counts reflects the sum of the association counts of the input attributes (query terms) to any given output attribute (result).
d Distance reflects the releavancy of the memory perspective.  The closer the distance, the more relavant the memory.  For example, triple memories will have a distance of 0, while the directory memory will have a distance of 1.  Distance is also used when evaluating temporal memories when the query has specified a preferred time.  Associations with times that are closer to the preferred time will have smaller distances, whereas, associations with times that are farther away from the preferred time will have greater distances.
me Memory.  Specifies the perspective for the advanced metric JSON object.
mecn Memory connections. Reflects the number of memories that scored the output.  Memory connections are only used in muti-memory queries when you have separate memory perspectives, i.e. either 'me=as' or multiple 'me' params.
s Score reflects the rollup process of the raw metrics (memory connections, distance, attribute connections, and-group attribute connections and association counts).

 

Input Explanations:

 

When you add input explanations you don't get any new JSON properties that have not been specified elsewhere.  TODO - Add more explanation here.

 

 

Comments (0)

You don't have permission to comment on this page.