Skip to main content
POST
Predict an action on a temporary state

Authorizations

token
string
query
required

A plaintext token to secure your server, specified at startup in the argument --auth-token thisismysecret

Query Parameters

include_events
enum<string>
default:AFTER_RESTART

Specify which events of the tracker the response should contain.

  • ALL - every logged event.

  • APPLIED - only events that contribute to the trackers state. This excludes reverted utterances and actions that got undone.

  • AFTER_RESTART - all events since the last restarted event. This includes utterances that got reverted and actions that got undone.

  • NONE - no events.

Available options:
ALL,
APPLIED,
AFTER_RESTART,
NONE

Body

application/json

Event for incoming user message.

event
enum<string>
required

Event name

Available options:
user
Example:

"user"

timestamp
number

Unix timestamp (float) of when the event was applied.

Example:

1774447464.622012

metadata
object

Arbitrary metadata attached to the event by the channel or model, e.g. session_id, model_id, assistant_id, model_name.

Example:
text
string | null

Text of user message.

input_channel
string | null
message_id
string | null
parse_data
object

NLU parser information. If set, message will not be passed through NLU, but instead this parsing information will be used.

anonymized_at
string | null

ISO 8601 timestamp of when PII in this event was anonymized, or null if the event has not been anonymized.

Response

Success

scores
object[]

Prediction results

policy
string

Policy which predicted the most likely action

Example:

"policy_2_TEDPolicy"

confidence
number

Confidence of the prediction

Example:

0.057

tracker
object

Conversation tracker which stores the conversation state.