Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Your voice experience may include questions such as "What are the nutritional facts about bananas?" (to return a specific answer) or "Give me another tip for healthy eating." (to return a random sample from the content group). Of course, you can have many more items than are shown in this example.

Create a content type

Important: Creating a content type involves knowledge of JSON coding.

...

  1. In the global menu, select Develop > Schema.

  2. Click Add (+) to start a new schema. Select Content as the schema type and click Add.

  3. The following image shows a partial Edit Schema form.

    Note: You can cut and paste the following sample code to the Schema Editor and modify the fields that appear when you create a content item:

    Code Block
    {
      "fields" : [
                  {
                    "key"        : "speaker",
                    "label"      : "Speaker voice",
                    "isDefault"  : false,
                    "validation" : [{ "required" : "false" }],
                    "options"    : [],
                    "ref"        : "",
                    "fieldType"  : "text",
                    "type"       : "Object"
                  },
                  {
                    "key"        : "source",
                    "label"      : "Source",
                    "isDefault"  : false,
                    "validation" : [{ "required": "true" }],
                    "options"    : [],
                    "ref"        : "",
                    "fieldType"  : "text",
                    "type"       : "Object"
                  },
                  {
                    "key"        : "tip",
                    "label"      : "Nutrition Tip",
                    "isDefault"  : true,
                    "validation" : [{ "required": "true" }],
                    "options"    : [],
                    "ref"        : "",
                    "fieldType"  : "richtext",
                    "type"       : "Object"
                  },
                  {
                    "label"      : "Title",
                    "key"        : "title",
                    "isDefault"  : false,
                    "validation" : [],
                    "options"    : [],
                    "ref"        : "",
                    "fieldType"  : "text",
                    "type"       : "String"
                  },
                  {
                    "label"      : "Tags",
                    "key"        : "tags",
                    "isDefault"  : false,
                    "validation" : [],
                    "options"    : [],
                    "ref"        : "",
                    "fieldType"  : "text",
                    "type"       : "Object"
                  }
                 ]
  4. Click Save (check markcheckmark).

Create a content item

You can create content data using Dynamic Data Manager node or you can add content data manually. See How to use the Dynamic Data Manager node.

Use the following steps to create content data manually:

...