From 75410fdc8b419052ab153075481af574e972cdc3 Mon Sep 17 00:00:00 2001 From: Ayad Date: Sat, 7 Mar 2020 23:25:45 +0300 Subject: [PATCH] add simple description about get slot value Get the value of a slot using .get_slot() with simple example --- docs/core/slots.rst | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/core/slots.rst b/docs/core/slots.rst index d9c2d5c0052f..25aec4dd97a5 100644 --- a/docs/core/slots.rst +++ b/docs/core/slots.rst @@ -58,6 +58,13 @@ You can provide an initial value for a slot in your domain file: type: text initial_value: "human" +You can get the value of a slot using ``.get_slot()`` inside ``actions.py`` for example: + +.. code-block:: python + + data = tracker.get_slot("slot-name") + + There are multiple ways that slots are set during a conversation: