Five either/or questions reveal a travel archetype, and the archetype (plus its interests, folded into the hint) plans a matching trip.
Five A/B questions. Tally the answers into one of a few archetypes (โThe Culture Vultureโ), show a fun result card, then let the AI plan a trip that matches. The archetype's descriptive hint โ with its interest tags folded in โ does the personalization.
Each archetype carries a written hint and a list of interests. At the end you fold the interests into the hint string and hand off.
Each result type has a name, a descriptive hint sentence, and an interests array.
Count A vs. B; pick the archetype (or a โmixโ).
Append Interests: โฆ to the archetype's hint, then call showFrame().
The archetype's hint plus its interests โ as one string โ personalize an otherwise generic prompt.
window.mindtrip.showFrame(null, {
destination: 'New York City',
prompt: 'Plan me a New York City trip that matches my travel personality.',
hint: `${archetype.hint} Interests: ${archetype.vibes.join(', ')}.`,
id: 'nyc-quiz-result'
});
| Parameter | What it carries in this example |
|---|---|
destination | The city. |
prompt | A generic opener โ the personality lives in the hint, not here. |
hint | The archetype description plus its interests, folded into one string (per Mindtrip best practice). |
id | Tracking slug. |
vibes parameter โ the recommended pattern. One hint carries everything.A self-contained, working version of this experience. Copy it into an .html file, change the destination and content, and it runs. The Mindtrip embed script must be on the page (shown at the top).
<!-- Required on every page: the Mindtrip embed -->
<script src="https://partner.mindtrip.ai/overlay/embed.js?orgid=your-org-id" defer></script>
<div id="quiz"></div>
<div id="result" style="display:none">
<h2 id="r-name"></h2>
<button onclick="plan()">Plan My Trip โ</button>
</div>
<script>
const questions = [
{ q: 'Your ideal morning?', a: 'A quiet museum', b: 'Brunch with a crowd' },
{ q: 'Your ideal night?', a: 'Jazz in a small room', b: 'Rooftop bar hopping' }
// ...add up to 5
];
const archetypes = {
A: {
name: 'The Culture Vulture',
hint: 'This visitor is a cultural traveler โ museums, jazz, history, slow exploration.',
vibes: ['art', 'history', 'food']
},
B: {
name: 'The Social Explorer',
hint: 'This visitor is high-energy โ rooftops, trendy restaurants, nightlife.',
vibes: ['nightlife', 'food', 'shopping']
}
};
let answers = [];
// ...render each question, push 'A'/'B' to answers on click, then call showResult()
let chosen; // set by showResult() based on the A/B tally
function showResult() {
const aCount = answers.filter(x => x === 'A').length;
chosen = aCount >= questions.length / 2 ? archetypes.A : archetypes.B;
document.getElementById('r-name').textContent = chosen.name;
document.getElementById('result').style.display = 'block';
}
function plan() {
window.mindtrip.showFrame(null, {
destination: 'New York City',
prompt: 'Plan me a New York City trip that matches my travel personality.',
hint: `${chosen.hint} Interests: ${chosen.vibes.join(', ')}.`,
id: 'nyc-quiz-result'
});
}
</script>
Keep the questions playful and the archetypes flattering โ people share results they like. The real work is in each archetype's hint: make it a rich, specific description of that traveler.
Fold the interests into the hint string (as shown) rather than passing a separate vibes parameter โ that's the recommended Mindtrip pattern.