File size: 962 Bytes
a1a5ffc
 
 
e1e4c9b
 
 
 
 
 
 
 
a1a5ffc
e1e4c9b
a1a5ffc
 
 
 
 
596e203
a1a5ffc
 
 
 
 
 
 
 
 
e1e4c9b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# config.py
import os

# Try to load local .env file if it exists (for local development)
try:
    from dotenv import load_dotenv
    load_dotenv()
except ImportError:
    # python-dotenv not installed, which is fine on HF Spaces 
    # as secrets are handled by the OS environment
    pass

# API Keys (loaded from Secrets on HF Spaces or .env locally)
HF_TOKEN = os.getenv("HF_TOKEN")
TMDB_API_KEY = os.getenv("TMDB_API_KEY")

# LLM Model Name (as specified on Hugging Face)
LLM_MODEL_NAME = "huggingface/meta-llama/Llama-3.2-3B-Instruct"
#LLM_MODEL_NAME = "ollama/llama3.2"

# Base prompt for LLM explanations
BASE_PROMPT = """
Digital Concierge for MovieLens. Explain the recommendation in exactly 3 sentences.
Max 60 words. Be punchy. Do not start with 'Based on your history'.
"""

# Injections for narrative styles
LOGIC_INJECTION = "Focus on technical alignment and genre overlap."
SOCIAL_INJECTION = "Focus on community acclaim and fan-favorite status."