Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Default naming scheme, behavior for all concepts #778

@vishwacsena

Description

@vishwacsena

Default names

This specification outlines the default naming convention for all concepts in composer.

All triggers, actions start with a default name but is user editable.

Bot

There is no default name for a Bot. User must explictly provide a name.

Dialog

There is no default name for a dialog. User must explicitly provide a name.

Trigger

  • Only Intent trigger has a name property.
  • Default name for a trigger will be its type name - e.g. IntentTrigger
  • In case there already exists a trigger with the name, add a number increment as suffix - e.g. IntentTrigger, IntentTrigger1, IntentTrigger2, ...
  • All trigger names within a specific dialog must be unique.
  • In case of intent trigger, the intent name will default to the trigger name.
  • If user renames the trigger in the trigger's property editor, then the intent name is also updated.
  • If user changes the intent name of a trigger in all-up view and/ or if this intent is used as a reference in another intent, then ask the user for the intended behavior -
    • Update all references to the new name
    • Keep reference as is

Input/ prompt actions

  • Default name for an input action will be its type name - e.g. NumberInput, TextInput, ChoiceInput, ConfirmInput, DateTimeInput, OAuthInput, AttachmentInput
  • In case there already exists an input action with that name, add a number increment as suffix - e.g. NumberInput, NumberInput1, NumberInput2, ...
  • All input names tied to a specific dialog must be unique.
  • The intent name for an input default to the input name.
  • The prompt LG template name defaults to the input name.
  • The unrecognized prompt LG template name defaults to <input-name>.unrecognized.prompt
  • The invalid prompt LG template name defaults to <input-name>.invalid.prompt
  • If user renames the input in the input's property editor, then the intent name is also updated, LG template names are also updated.
  • If user changes the intent name of an input in the all-up view or changes the LG template name tied to an input in the all-up view and/ or if the intent or lG template is used as a reference in another intent/ LG template, then ask the user for the intended behavior -
    • Update all references to the new name
    • Keep reference as is

SendActivity

  • Default name is sendActivity, add an increment as suffix to de-dupe - e.g. SendActivity, SendActivity1, SendActivity2, ...
  • The default LG template name is the name of the SendActivity action
  • If user renames the send activity in its property editor, then the LG template name is also updated.
  • If user changes the LG template name in all-up view and/ or if this LG template is used as a reference in other intents or templates, then ask the user for the intended behavior -
    • Update all references to the new name
    • Keep reference as is

All other actions

  • Name is available, defaults to ActionType, add a number increment suffix to de-dupe
  • These names are just for organizational purposes and readaibility and do not have any runtime implications.

Note: This impacts the current naming scheme used for LG templates in send activity action. With this change, we will no longer use our current naming scheme bfd-<ID>

Metadata

Metadata

Assignees

Labels

Area: LUBelongs to LU feature areaP0Must Fix. Release-blockerR10Release 10 - August 17th, 2020Type: Engineering

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions