Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Dynamic Homepage and Personalization

Description / Background

Get personalized item recommendations based on the specific user you select. With this use case, Amazon Personalize automatically filters out items that the user purchased based on Purchase events and also the userId that you specify.

We expect that the result will be different for each user with the “Dynamic Homepage Personalization” feature. The difference will be based upon searches, views, country, likewise bookings on our platform.

Glossary

Private (https://app.clickup.com/9003122396/docs/8ca1fpw-35796/8ca1fpw-41516)

Objectives

  • User can find their personalized recommendation on Recommended For You section
  • We use aws recomended for you for the system
  • Phase 1:
    • Registered user feature:
      • User can see the customized restaurant list on Recommended For You
      • Get user behavior data from restaurant view and booking
  • Phase 2:
    • Adding recommendation based on user country
    • The default country will be Bangkok for user outside Thailand or Singapore
    • Rewrite the API from rest to graphql
    • Add new country params when the user is not from Thailand or Singapore
    • Add cache on app layer using Aiven
    • Change the transactiondb from posrgresql to aiven
    • Use Cloudflare R2 for object storage
    • Add NUXT tailwind template for the admin dashboard

Scope

Homepage, Restaurant detail page

Sequence Diagram / Flow

Flow Homepage Personalization:

ERD

-

Backend Implementation

  • Implementing AWS personalize → recommended for you
  • implementing drizzle orm?

[

docs.aws.amazon.com

https://docs.aws.amazon.com/personalize/latest/dg/ECOMMERCE-use-cases.html#recommended-for-you-use-case

](https://docs.aws.amazon.com/personalize/latest/dg/ECOMMERCE-use-cases.html#recommended-for-you-use-case)

[

github.com

https://github.com/hungryhub-team/hh-personalize?tab=readme-ov-file

](https://github.com/hungryhub-team/hh-personalize?tab=readme-ov-file)

Frontend Implementation

  • add pubic API for personalize domain on env
  • get recomended for you data from hh-personalize api
  • create recomended for you vue page
  • send event when user click restaurant detail to hh-personalize api (/services/analytics/trackEvents)
  • send event when user purchase to hh-personalize api (/services/analytics/trackEvents)

[

github.com

https://github.com/hungryhub-team/hh-pegasus/pull/1363

](https://github.com/hungryhub-team/hh-pegasus/pull/1363)

PRD & Task

Private (https://app.clickup.com/t/86cx5qhc1)

Private (https://app.clickup.com/t/86cza5hjz) Dynamic homepage PRD: https://docs.google.com/document/d/1MgRrTpqVCJA0Oa0QmkBsJn-IvSvjp9iaEhJTFccb_44/edit

Design

-

API Blueprint

How to get Grapghql query:

MethodPathURLDescriptionPayload
GET/graphqlstaging: https://hh-personalize.hh-engineering.my.id/get recomended for you data for registered user
POST(?)/services/analytics/track_eventsSent data event when user open detail restaurant and purchase

New Query

-

DB Schema / Database Migration

-


Improvement:

Feature NameDateWhat ChangedDescription
phase 13 Feb 2025initial document-