Input¶
The Input Object is a JSON object that serves as the short-term AI Agent memory. The Input object is generated each time the user sends a message or provides a voice input to an AI Agent.
The Input object stores:
- General data about the user input, such as time and type of input
- Endpoint-specific data
- Results from the NLU Intent mapping process, such as the recognized Intent and Slots
Limitations¶
- You can store up to 1.5 MB in the Input object. For dedicated SaaS and on-premises installations, you can configure the limit using the
MAX_MEMORY_OBJECT_SIZE
variable in thevalues.yaml
file. Increasing the object size could lead to performance issues.
Properties¶
Note
The data in the Input object depends on the Endpoint through which the user input is received. This article doesn't include all possible property variations.
Deprecation of Understood Messages
With Cognigy.AI 4.91, the Understood Messages concept was deprecated. The shutdown date is June 2025. Use the Goals and Tasks concepts to evaluate whether your AI Agent understood a particular phrase.
Refer to the list of all upcoming removals on the Deprecations and Removals page.
The Input object contains the following properties:
Input Object Properties
Key | Type | Description |
---|---|---|
text |
String | The text of the user input. |
intent 1 |
String | The detected Intent name. If no Intent is detected, the property value is null . |
intentScore 1 |
Number | The detected Intent score. If no Intent is detected, the property value is null . |
intentFlow |
String | The Flow ID in which the Intent is detected. If no Intent is detected, the property value is null . |
slots |
Array | Contains the detected system-defined and user-defined Slots. |
nlu 1 |
Object | Contains the detailed NLU processing results. |
mode |
String | The type of input received by Cognigy.AI. Can be either TextOnly or TextData. |
type 1 |
String | The type of input sentence as determined by the NLU engine (Statement, Command, Greeting, BGreeting, whQuestion, howQuestion, ynQuestion, pAnswer, nAnswer). |
intentOutOfState |
String | Contains the detected Intent that has been excluded in the current Flow state. If no detected Intent was excluded in the current Flow state, the value is null . |
currentTime |
Object | Contains the timestamp data of the user input reception. |
language |
String | The locale language that was used to process the user input. For example, en-US , de-DE . |
ip |
String | The IP address of the user. If the IP address isn't available, for example, due to privacy or masking settings, the value is null . |
hashedIp |
String | The hashed IP address of the user. |
state |
String | The current state of the Flow. By default, the value is default . Other states can be defined. See State for more information. |
channel |
String | The channel through which the user input was received. This property is also available in the OData records to allow channel-based analytics filtering. |
endpointType |
String | The type of Endpoint through which the message was received, for example, Alexa or Facebook (Meta) Messenger. You can't change this value. |
entrypoint |
String | The ID of this property varies based on Snapshot usage:
|
userId |
String | The current user's ID. Cognigy.AI uses the user ID to identify their individual contact profile. See Contact Profiles for more information. |
inputId |
String | A unique ID that is generated for each user input received by Cognigy.AI. |
sessionId |
String | The current session ID. The session ID either provided by the channel or generated by Cognigy.AI. Most Endpoints allow defining an individual session expiration (TTL). |
flowName |
String | The name of the Flow in execution. |
URLToken |
String | The Endpoint URL Token. |
frustration |
Number | Indicates user frustration by representing how often the user repeatedly takes the same path in the Flow. |
completedGoals |
Array | The Goals that have been at the current stage in the Flow. |
execution |
Number | The number of messages received in the current session. |
traceId |
String | A unique identifier for the user input. |
activeQuestion |
Object | Contains information about an active question. |
apps |
Object | Contains information about the xApps that are active in the current session. |
intentLevel 1 |
Object | Contains information about the Intent Hierarchy level of the detected Intent. If no Intent was detected, the object is {"level1": null, "level2": null, "level3": null} |
understood 1 |
Boolean | An input is considered understood if any of the following conditions are met:
An input is considered not understood if any of the following conditions are met:
|
data |
Object | The data payload of the input. This object depends on the Endpoint through which the user input is received. |
attachments |
Array | An array of URLs pointing to the attachments uploaded to the chat. |
localeId 1 |
String | The unique ID for the current locale used to process the input message. |
result |
String | The answer from the user to a question from a Question or Optional Question. |
conditionalEntrypointWasExecuted 1 |
Boolean | Indicates if the Flow was executed on a conditional Node. |
Nested Objects¶
nlu
Object
Key | Property | Type | Description | |
---|---|---|---|---|
intentMapperResults |
Object | Provides details about the NLU Intent mapping results. | ||
finalIntentName |
String | The name of the detected Intent. | ||
finalIntentScore |
Number | The score of the detected Intent. | ||
finalIntentNegated |
Boolean | Indicates whether the detected Intent was negated. | ||
finalIntentConfirmationSentence |
String | The confirmation sentence of the detected Intent. | ||
finalIntentDisambiguationSentence |
String | The disambiguation sentence of the detected Intent. | ||
highestFlow |
String | Reference ID of the Flow in which the highest-scoring Intent was detected. | ||
intentPath |
String | The path of the Intent. | ||
intentPathIds |
Array | The IDs of the Intents in the path. | ||
intentPathFlowReferenceIds |
Array | The reference IDs of the Flows in which the Intents in the path were found. | ||
scores |
Array | Contains the results for the highest-scoring Intents for the current user input. | ||
id |
String | The ID of the Intent. | ||
name |
String | The name of the Intent. | ||
score |
Number | The score of the Intent. | ||
negated |
Boolean | Indicates whether the Intent was negated. | ||
confirmationSentence |
String | The confirmation sentence of the Intent. | ||
confirmationSentences |
Array | The confirmation sentences of the Intent. | ||
disambiguationSentence |
String | The disambiguation sentence of the Intent. | ||
flow |
String | The reference ID of the Flow in which the Intent was detected. | ||
description |
String | The description of the detected Intent. | ||
intentFlow |
String | A unique ID assigned to the Flow in which the Intent was detected. | ||
uniqueIntentFlowId |
String | A unique identifier for the Flow in which the Intent was detected. | ||
intentId |
String | A unique ID assigned to the Intent that was selected by the NLU processing. | ||
uniqueIntentId |
String | A unique identifier for the selected Intent. | ||
detailedSlots |
Array | Contains the detected system-defined and user-defined Slots, with more detailed information about the system-defined Slots. | ||
tokens |
Array | Contains the user input tokens. | ||
yesNoIntentResults |
Object | Contains the results of the Yes/No Intents model evaluation. See Yes/No Intents for more information. | ||
finalIntentName |
String | The name of the detected Yes/No Intent. | ||
finalIntentScore |
Number | The score of the detected Yes/No Intent. | ||
scores |
Array | Contains the results for the highest-scoring Yes/No Intents. | ||
id |
String | The ID of the Intent. | ||
name |
String | The name of the Intent. | ||
score |
Number | The score of the Intent. | ||
negated |
Boolean | Indicates whether the Yes/No Intent was negated. | ||
confirmationSentence |
String | The confirmation sentence of the Yes/No Intent. | ||
confirmationSentences |
Array | The confirmation sentences of the Yes/No Intent. | ||
disambiguationSentence |
String | The disambiguation sentence of the Yes/No Intent. | ||
flow |
String | The reference ID of the Flow in which the Yes/No Intent was detected. | ||
description |
String | The description of the detected Yes/No Intent. |
currentTime
Object
Key | Type | Description |
---|---|---|
year |
Number | The year. |
month |
Number | The month of the year. |
day |
Number | The day of the month. |
hour |
Number | The hour of the day. |
minute |
Number | The minute of the hour. |
second |
Number | The second of the minute. |
milliseconds |
Number | The milliseconds of the current time. |
weekday |
Number | The day of the week. |
dayOfWeek |
String | The day of the week. |
ISODate |
String | The date and time in ISO 8601 format. |
plain |
String | The current date and time in plain text. |
grain |
String | The grain of the current time. |
timezoneOffset |
String | The timezone offset of the current time. |
activeQuestion
Object
Key | Type | Description |
---|---|---|
nodeId |
String | The question Node's ID. |
type |
String | The type of question. |
lastExecutedAt |
String | The timestamp of the last execution of the active question. |
forgetQuestionThreshold |
Number | The threshold for forgetting the question. |
repromptCount |
Number | The number of times the question was reprompted. |
escalationCount |
Number | The number of times the question was escalated. |
apps
Object
Key | Property | Type | Description |
---|---|---|---|
customization |
Object | Contains the style customization options for the xApp Session as configured in the xApp: Init Session Node. | |
session |
Object | Contains xApp session-specific data. | |
token |
String | The xApp session token used to start a real-time connection with the xApp Shell Page. | |
pin |
String | The xApp session PIN, if the xApp: Get Session PIN Node is used. | |
baseUrl |
String | Base URL of the xApp Shell Page. | |
url |
String | The xApp session URL for the current conversation. |
intentLevel
Object
Key | Type | Description |
---|---|---|
level1 |
String | Level 1 Intent name. If no Intent was detected, the property value is null . |
level2 |
String | Level 2 Intent name. If no child Intent was detected, the property value is null . |
level3 |
String | Level 3 Intent name. If no grandchild Intent was detected, the property value is null . |
Working with the Input Object¶
You can view the Input object by navigating to Info > Input in the Interaction Panel. You can copy the exact JSON path of an Input object value by right-clicking it and selecting Copy JSON Path.
Accessing Input Properties¶
Nodes can dynamically access Input properties with CognigyScript, for example, {{input.property}}
or Tokens. The CognigyScript expression you use to access the input object follows the dot notation for JSON objects: property.child.child
.
Examples¶
{{input.text}}
returns the text that the user sent to the Flow.{{input.nlu.tokens}}
returns the tokens of the user input in an array.{{input.attachments[0].url}}
returns the URL of the first attachment uploaded to the chat.