Teneo Developers

Work with Version Flags

Congratulations, you have now created a working Longberry Baristas solution identical to the one we worked on when we first started the tutorials! Next up, you may want to expand your solution to include Longberry Bakers. However, let's say Longberry Bakers will not be set to deploy for a few more months; this would mean that you need a way to keep the features you add for the expansion separate from the current working solution in some way.

For cases like this, we can use Version Flags. In this section, we will demonstrate how to use Version Flags to differentiate between Stable and Latest versions of a solution in order to add Longberry Bakers functionality without interfering with our published Longberry Baristas bot.

Prepare the Solution

In order to be able to set your solution to 'Stable' mode you will need to add all the necessary documents to 'Stable' mode. This includes the following:

You can add these to 'Stable' by selecting the relevant document and clicking the 'Set Stable' button.

Flows, language objects, and entities

To mark all flows, language objects, and entities as stable, we select each folder in the solution individually and click the ‘Set Stable’ button for each one.

Classes

For classes used inside the Longberry Baristas, we need to do the following:

  1. While in the solution main page, select the Class Manager located on the top navigation bar.
  2. Select the relevant classes and click on the 'Set stable' button.

This is how the Stable looks like inside the Class Manager:

Class Manager - Version Flags

Set entire solution to Stable

It is also possible to set the entire solution to 'Stable' at once. This can be done in the Solution Log.

  1. While inside the main solution window, click on the 'Solution' button located in the ribbon 'History' section. This will open up the 'Solution Log' which includes all of the recent changes made in the solution.
  2. Select the relevant 'Revision' number and click on the 'Stable' button. This will set all documents versions specific to the selected revision as stable.

Create a new Longberry Bakers flow

Let's start by creating a draft for our new use case. This draft is going to be about the baked goods we are offering; it will later be shown to and need approval from the team before it is completed.

  1. Start by creating a new flow and naming it User asks about baked goods we offer.
  2. Name the trigger something like Tell me about your baked goods.
  3. Add the following Intent examples:

example-inputs

1Do you have baked goods
2Do you serve cinnamon bun
3Do you have any desserts
4Do you serve muffins?
5Tell me about the baked goods you have
6Tell me about your baked goods
7What baked goods do you serve?
8What kinds of baked goods do you serve?
9What kinds of desserts do you sell
10Which baked goods are offered by Longberry Baristas?
11Which sorts of baked goods do you have
12
  1. Finally, click on the 'Generate' button under the 'Match' section to automatically generate a match requirement based on the example specification.
  2. As we are not sure yet what baked goods we intend to offer, we will leave the output node untouched and save the flow.

As you can see, the flow is currently not finished. This is shown with a yellow TODO label. Hovering over it will show what is currently missing in our flow to be considered done. In this case it is missing an answer from the bot when the flow is triggered.

Test the Stable Version

It is time to do a final test in our Tryout before publishing our Stable Version of Longberry Baristas. When testing, we need to make sure we are not including anything from Longberry Bakers, as we do not want this included in our published bot.

This can be done with the following steps,

  1. While inside the main solution window, click on the Tryout button located in the ribbon. This will open Tryout in advanced mode.
  2. Select the 'Stable' button located in the 'Stable Version' section in the ribbon. This will only include the stable elements inside the flow to be tested in Tryout.
  3. Test your Longberry Baristas solution by asking it some questions, such as:
  • What coffees do you serve?
  • Suggest me a coffee!
  1. Everything works as it should. To make sure that the latest created Longberry Bakers flow is not included in this version, try to trigger it by asking the following question:
  • Which baked goods do you have?

As you can see, it does not trigger as we are only testing the 'Stable Version' of our solution.

Publish the Stable Version

Now that we have tested our solution in Tryout we will proceed by publishing the 'Stable Version' of our Longberry Baristas.

  1. Close down the Tryout window. This will return you to the main solution page.
  2. Open the 'SOLUTION' tab in the main solution window.
  3. Select 'Publish' in the left sidebar.
  4. Click the 'Manage' button and in the drop-down you will see a lot of different alternatives. Locate the 'Stable' section and choose 'Publish'. This will publish your solution to Teneo Web Chat where you can access it by pressing the link.

Publish with version flags

More info and detailed steps about publishing your solution can be found in the Publish your bot page..

Test the Latest version

If we are interested in testing the whole solution and not the stable version we can do the following:

  1. While inside the advanced window of Tryout, switch over to the 'Latest' version by selecting the 'Latest' button located in the ribbon.
  2. Test the solution by asking the following questions:
  • What coffees do you serve?
  • Suggest me a coffee!
  1. Now let us make sure the Longberry Bakers flow is also included by asking the the following question:
  • Which baked goods do you have?

You may notice a yellow warning label; this is because the current flow we triggered is not finished. Let's proceed by finishing it now.

Finish the Longberry Bakers flow

As a final step, let us move on and finish the flow we started.

  1. Open the 'User asks about baked goods we offer' flow in edit move.
  2. Select the Output node and name it We offer a variety of handmade baked goods....
  3. Add the answer text We offer a variety of handmade baked goods - from cinnamon buns to muffins and much more..
  4. Go ahead and save the flow now.

Congratulations! You have now finished your first Longberry Bakers flow. If you want to publish the solution again including this flow, make sure to include it to stable and republish your solution.

Test yourself

Go ahead and add a new flow for Longberry Bakers, this time for ordering a baked good. The flow should follow the steps from the Extract Entities page, but instead of coffee types it should cover baked goods, such as cinnamon buns and muffins.