Spaces:
Running on CPU Upgrade
Running on CPU Upgrade
| """ | |
| Configuration for the Agentic Memory demo. | |
| Manages OpenSearch connection, memory container IDs, and model settings. | |
| """ | |
| import os | |
| from dotenv import load_dotenv | |
| load_dotenv() | |
| # OpenSearch cluster | |
| OPENSEARCH_ENDPOINT = os.getenv("OPENSEARCH_ENDPOINT", "") | |
| AWS_REGION = os.getenv("AWS_REGION", "us-east-1") | |
| # Bedrock model for agents | |
| BEDROCK_MODEL_ID_FAST = os.getenv( | |
| "BEDROCK_MODEL_ID_FAST", | |
| "us.amazon.nova-micro-v1:0" | |
| ) | |
| BEDROCK_MODEL_ID = os.getenv( | |
| "BEDROCK_MODEL_ID", | |
| "us.anthropic.claude-sonnet-4-6" | |
| ) | |
| # Embedding model for memory containers | |
| EMBEDDING_MODEL_ID = os.getenv("EMBEDDING_MODEL_ID", "") | |
| EMBEDDING_DIMENSION = int(os.getenv("EMBEDDING_DIMENSION", "1024")) | |
| # LLM model for memory processing (extraction/summarization) | |
| MEMORY_LLM_MODEL_ID = os.getenv("MEMORY_LLM_MODEL_ID", "") | |
| # Single memory container (holds all memory types: long-term, sessions, working, history) | |
| CONTAINER_NAME = "product-search-agent" | |
| CONTAINER_ID = os.getenv("MEMORY_CONTAINER_ID") | |
| # Persona IDs | |
| PERSONAS = { | |
| "sarah": "user1", | |
| "alex": "user2", | |
| } | |
| # Persona genders (used for gender_affinity matching in product personalization) | |
| PERSONA_GENDERS = { | |
| "user1": "female", | |
| "user2": "male", | |
| } | |