version: v2
name: movielens_semantic_search

# Download the data from S3:
# https://shaped-onboarding-demo-datasets.s3.us-east-2.amazonaws.com/movielens/movielens_items.jsonl
data:
  item_table:
    name: movielens_items
    type: table

index:
  lexical_search: # enables BM25 lexical search on item fields
    item_fields:
      - movie_title
      - description
      - cast
      - genres
      - writers
      - directors
      - interests
  embeddings:
    - name: content_embedding # enables vector search
      encoder:
        type: hugging_face
        model_name: sentence-transformers/all-MiniLM-L6-v2
        item_fields:
          - movie_title
          - description
          - cast
          - genres
          - writers
          - directors
          - interests
    - name: poster_embedding
      encoder:
        type: hugging_face
        model_name: openai/clip-vit-base-patch32
        item_fields:
          - poster_url
