> For the complete documentation index, see [llms.txt](https://doc.lucky-cycle.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.lucky-cycle.com/games/index/personality.md).

# Personality

{% hint style="warning" %}
Demo: <https://campaigns.lucky-cycle.com/utils/games?game=personality-quizz>
{% endhint %}

1. [#configuration](#configuration "mention")
2. [#options](#options "mention")
3. [#assets](#assets "mention")

### Configuration

<details>

<summary>JSON</summary>

```json
{
  "options": {
    "tags": [
      {
        "id": 1,
        "name": "italy"
      },
      {
        "id": 2,
        "name": "japan"
      },
      {
        "id": 3,
        "name": "pizza"
      },
      {
        "id": 4,
        "name": "pasta"
      },
      {
        "id": 5,
        "name": "ossobucco"
      },
      {
        "id": 6,
        "name": "lasagna"
      },
      {
        "id": 7,
        "name": "sushi"
      },
      {
        "id": 8,
        "name": "ramen"
      }
    ],
    "questions": {
      "en": [
        {
          "id": 1,
          "question": "1. What do you prefer?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": "",
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [1],
              "next": 2,
              "image": "",
              "text": "Italian cuisine"
            },
            {
              "id": 2,
              "tags": [2],
              "next": 3,
              "image": "",
              "text": "Japanese cuisine"
            }
          ],
          "explanation": []
        },
        {
          "id": 2,
          "question": "2A. What do you prefer? (2 answers possible)",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 2,
          "cols": 2,
          "min": 1,
          "max": 2,
          "answers": [
            {
              "id": 1,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Pizza"
            },
            {
              "id": 2,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Pasta"
            },
            {
              "id": 3,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Osso Bucco"
            },
            {
              "id": 4,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Lasagne"
            }
          ],
          "explanation": []
        },
        {
          "id": 3,
          "question": "2B. What do you prefer?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [7],
              "next": "",
              "image": "",
              "text": "Sushi"
            },
            {
              "id": 2,
              "tags": [8],
              "next": "",
              "image": "",
              "text": "Ramen"
            }
          ],
          "explanation": []
        }
      ],
      "fr": [
        {
          "id": 1,
          "question": "1. Que préférez-vous&nbsp;?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": "",
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [1],
              "next": 2,
              "image": "",
              "text": "Cuisine italienne"
            },
            {
              "id": 2,
              "tags": [2],
              "next": 3,
              "image": "",
              "text": "Cuisine japonaise"
            }
          ],
          "explanation": []
        },
        {
          "id": 2,
          "question": "2A. Que préférez-vous&nbsp;? (2 réponses possibles)",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 2,
          "cols": 2,
          "min": 1,
          "max": 2,
          "answers": [
            {
              "id": 1,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Pizza"
            },
            {
              "id": 2,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Pâtes"
            },
            {
              "id": 3,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Osso Bucco"
            },
            {
              "id": 4,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Lasagne"
            }
          ],
          "explanation": []
        },
        {
          "id": 3,
          "question": "2B. Que préférez-vous&nbsp;?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [7],
              "next": "",
              "image": "",
              "text": "Sushi"
            },
            {
              "id": 2,
              "tags": [8],
              "next": "",
              "image": "",
              "text": "Ramen"
            }
          ],
          "explanation": []
        }
      ],
      "nl": [
        {
          "id": 1,
          "question": "1. Waar geef je de voorkeur aan?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": "",
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [1],
              "next": 2,
              "image": "",
              "text": "Italiaanse keuken"
            },
            {
              "id": 2,
              "tags": [2],
              "next": 3,
              "image": "",
              "text": "Japanse keuken"
            }
          ],
          "explanation": []
        },
        {
          "id": 2,
          "question": "2A. Waar geef je de voorkeur aan? (2 mogelijke antwoorden)",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 2,
          "cols": 2,
          "min": 1,
          "max": 2,
          "answers": [
            {
              "id": 1,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Pizza"
            },
            {
              "id": 2,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Pasta"
            },
            {
              "id": 3,
              "tags": [3],
              "next": "",
              "image": "",
              "text": "Osso Bucco"
            },
            {
              "id": 4,
              "tags": [4],
              "next": "",
              "image": "",
              "text": "Lasagne"
            }
          ],
          "explanation": []
        },
        {
          "id": 3,
          "question": "2B. Waar geef je de voorkeur aan?",
          "question_color": "white",
          "question_background_color": "black",
          "answer_color": "white",
          "answer_background_color": "rgba(0, 0, 0, .75)",
          "next": -1,
          "rows": 1,
          "cols": 2,
          "min": 1,
          "max": 1,
          "answers": [
            {
              "id": 1,
              "tags": [7],
              "next": "",
              "image": "",
              "text": "Sushi"
            },
            {
              "id": 2,
              "tags": [8],
              "next": "",
              "image": "",
              "text": "Ramen"
            }
          ],
          "explanation": []
        }
      ]
    },
    "use_images": true,
    "use_explanation": false,
    "use_recommandation": false,
    "recommandation_products": 4,
    "recommandation_rows": 2,
    "recommandation_cols": 2,
    "products": {
      "en": [
        {
          "name": "Lucky&nbsp;Cycle",
          "url": "https://www.lucky-cycle.com/en?utm_source=lck_demo",
          "image": "",
          "tags": [1, 2, 3, 4, 5, 6, 7, 8]
        }
      ],
      "fr": [
        {
          "name": "Lucky&nbsp;Cycle",
          "url": "https://www.lucky-cycle.com/fr?utm_source=lck_demo",
          "image": "",
          "tags": [1, 2, 3, 4, 5, 6, 7, 8]
        }
      ],
      "nl": [
        {
          "name": "Lucky&nbsp;Cycle",
          "url": "https://www.lucky-cycle.com/nl?utm_source=lck_demo",
          "image": "",
          "tags": [1, 2, 3, 4, 5, 6, 7, 8]
        }
      ]
    },
    "redirect": false
  },
  "texts": {
    "en": {
      "good": "Correct!",
      "bad": "Nope!",
      "confirm": "Confirm",
      "next": "Next question",
      "end": "Continue",
      "redirect": "Next page"
    },
    "fr": {
      "good": "Correct&nbsp;!",
      "bad": "Non&nbsp;!",
      "confirm": "Je valide",
      "next": "Question suivante",
      "end": "Continuer",
      "redirect": "Page suivante"
    },
    "nl": {
      "good": "Correct!",
      "bad": "Fout!",
      "confirm": "Bevestigen",
      "next": "Volgende vraag",
      "end": "Doorgaan",
      "redirect": "Volgende pagina"
    }
  },
  "images": {}
}
```

</details>

### Options

<table><thead><tr><th>Key</th><th>Type</th><th>Explanation</th><th>Default</th></tr></thead><tbody><tr><td><pre><code>tags > id / name
</code></pre></td><td>Int / String</td><td>Tags used to create a persona of the player <em>(<strong>name</strong> is only used in data extracts)</em>.</td><td>1 / "italy"</td></tr><tr><td><p></p><pre><code>questions > id
</code></pre></td><td>Int</td><td>Id of the question (used for redirection, should be <mark style="color:$danger;">unique</mark>).</td><td>1</td></tr><tr><td><p></p><pre><code>questions > question
</code></pre></td><td>String</td><td>Question displayed to the player.</td><td>"1. What do you prefer?"</td></tr><tr><td><p></p><pre><code>questions > question_color / question_background_color
</code></pre></td><td>String</td><td>Color and background color of the question.</td><td>"white" / "black"</td></tr><tr><td><p></p><pre><code>questions > answer_color / answer_background_color
</code></pre></td><td>String</td><td>Color and background color of the answers to the question.</td><td>"white" / "rgba(0, 0, 0, .75)"</td></tr><tr><td><p></p><pre><code>questions > next
</code></pre></td><td>Int (or String if empty...)</td><td>Target - id of the next question <mark style="color:orange;">(should only be used if answers don't have a target of their own)</mark>. </td><td>""</td></tr><tr><td><p></p><pre><code>questions > rows / cols
</code></pre></td><td>Int</td><td>Layout of the answers for the current question.</td><td>1 / 2</td></tr><tr><td><p></p><pre><code>questions > min / max
</code></pre></td><td>Int</td><td>Number of answers that can be selected <mark style="color:orange;">(should use </mark><em><mark style="color:orange;">next</mark></em><mark style="color:orange;"> if multiple answers)</mark>.</td><td>1 / 1</td></tr><tr><td><p></p><pre><code>questions > answers > id
</code></pre></td><td>Int</td><td>Id of the answer (should be <mark style="color:$danger;">unique per question</mark>).</td><td>1</td></tr><tr><td><pre><code>questions > answers > tags
</code></pre></td><td>Array</td><td>Tag(s) associated to the answer <mark style="color:$warning;">(uses ids, not names)</mark>.</td><td>[1]</td></tr><tr><td><pre><code>questions > answers > next
</code></pre></td><td>Int</td><td>Target - id of the next question <mark style="color:orange;">(should only be used if question don't have a target of its own)</mark>. </td><td>2</td></tr><tr><td><pre><code>questions > answers > image
</code></pre></td><td>String</td><td>Visual to be displayed as background of the answer.</td><td>/</td></tr><tr><td><pre><code>questions > answers > text
</code></pre></td><td>String</td><td>Text to be displayed for the answer.</td><td>"Italian cuisine"</td></tr><tr><td><p></p><pre><code>questions > explanation
</code></pre></td><td>String</td><td>Explanation of the answer to the question.</td><td>/</td></tr><tr><td><p></p><pre><code>use_images
</code></pre></td><td>Boolean</td><td>Display images for the answers.</td><td>true</td></tr><tr><td><p></p><pre><code>use_explanation
</code></pre></td><td>Boolean</td><td>Display explanation after each question (if not empty).</td><td>false</td></tr><tr><td><p></p><pre><code>use_recommandation
</code></pre></td><td>Boolean</td><td>Display products at the end of the game based on tags.</td><td>false</td></tr><tr><td><p></p><pre><code>recommandation_products
</code></pre></td><td>Int</td><td>Number of products to be displayed (if <em>use_recommandation</em> set to true).</td><td>4</td></tr><tr><td><p></p><pre><code>recommandation_rows / recommandation_cols
</code></pre></td><td>Int</td><td>Layout of the products page (if <em>use_recommandation</em> set to true).</td><td>2 / 2</td></tr><tr><td><p></p><pre><code>products > name
</code></pre></td><td>String</td><td>Text to be displayed for a product.</td><td>"Lucky Cycle"</td></tr><tr><td><p></p><pre><code>products > url
</code></pre></td><td>String</td><td>URL to be added to a product (will redirect on click).</td><td>"https://..."</td></tr><tr><td><p></p><pre><code>products > image
</code></pre></td><td>String</td><td>Visual to be displayed for a product.</td><td>/</td></tr><tr><td><pre><code>products > tags
</code></pre></td><td>Array</td><td>Tags associated to a product <mark style="color:$warning;">(used for selection)</mark>.</td><td>[1,2,...]</td></tr><tr><td><p></p><pre><code>redirect
</code></pre></td><td>Boolean</td><td>In <em>use_recommandation</em> mode, adds a button allowing the player to continue the pages flow.</td><td>false</td></tr><tr><td><p></p><pre><code>texts > good / bad
</code></pre></td><td>String</td><td>Title of the explanation screen (if <em>use_explanation</em> set to true).</td><td>"Correct!" / "Nope!"</td></tr><tr><td><pre><code>texts > confirm
</code></pre></td><td>String</td><td>CTA displayed on a question page if more than one answer can be selected.</td><td>"Confirm"</td></tr><tr><td><pre><code>texts > next
</code></pre></td><td>String</td><td>CTA displayed on the explanation page if this question isn't the last one (and <em>use_explanation</em> is set to true).</td><td>"Next question"</td></tr><tr><td><pre><code>texts > end
</code></pre></td><td>String</td><td>CTA displayed on the explanation page if this question is the last one (and <em>use_explanation</em> is set to true).</td><td>"Continue"</td></tr><tr><td><pre><code>texts > redirect
</code></pre></td><td>String</td><td>CTA displayed on the products page (if <em>redirect</em> is set to true).</td><td>"Next page"</td></tr></tbody></table>

### Assets

<table><thead><tr><th>Key</th><th>Size</th><th>Explanation</th><th>Default</th></tr></thead><tbody><tr><td><pre><code>answers > image
</code></pre></td><td>/</td><td>Background of the answer.</td><td>/</td></tr><tr><td><pre><code>products > image
</code></pre></td><td>/</td><td>Visual of the product (if <em>use_recommandation</em> is set to <mark style="color:$success;">true</mark>).</td><td>/</td></tr></tbody></table>
