-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy path.env.example
More file actions
101 lines (79 loc) · 3.9 KB
/
.env.example
File metadata and controls
101 lines (79 loc) · 3.9 KB
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# Local development placeholders for Mastra
# Google / Gemini API key (embedding + LLM)
GOOGLE_GENERATIVE_AI_API_KEY='your-google-api-key'
GOOGLE_API_KEY='your-google-api-key'
# Opencode Zen API Key
OPENCODE_API_KEY='your_opencode_zen_api_key_here'
# OpenAI (alternative provider)
# OpenAI API Configuration
# Can also use gemini must set OPENAI_BASE_URL and OPENAI_MODEL, OPENAI_EMBEDDING_BASE_URL, and EMBEDDING_MODEL
OPENAI_API_KEY='your_openai_api_key_here'
OPENAI_BASE_URL='https://api.openai.com/v1'
OPENAI_MODEL='gpt-5-mini'
# Gemini OAuth Cache Directory
GEMINI_OAUTH_CACHE='~/.gemini/oauth_creds.json'
# Anthropic API Configuration
ANTHROPIC_API_KEY='your_anthropic_api_key_here'
# OpenRouter Configuration
OPENROUTER_API_KEY='your_openrouter_api_key_here'
# AI Ga
AI_GATEWAY_API_KEY='your_api_key_here'
# Lamina Configuration
LMNR_PROJECT_API_KEY='your_project_api_key_here'
# Database (Postgres / PgVector) - Supabase Configuration
# Get from Supabase Dashboard > Project Settings > Database > Connection String (Session Pooler)
SUPABASE='postgresql://user:password@your-supabase-url.supabase.co:5432/mastra'
# Authentication for Supabase { to be used by lib/auth.ts not used directly by Mastra }
SUPABASE_KEY='your_supabase_anon_key_here'
SUPABASE_URL='https://your-project.supabase.co'
USER_EMAIL=''
USER_PASSWORD=''
# Direct Database URL (for connection pooling)
DATABASE_URL='postgresql://user:password@localhost:5432/mastra'
DB_SCHEMA='mastra'
DB_MAX_CONNECTIONS='20'
DB_IDLE_TIMEOUT='30000'
DB_CONNECTION_TIMEOUT='2000'
# Embedding & RAG (Lists is ivf lists for PgVector)
EMBEDDING_MODEL='gemini-embedding-001'
EMBEDDING_MAX_RETRIES='3'
MEMORY_LAST_MESSAGES='500'
# PgVector HNSW Index Configuration (for high-dimensional embeddings)
# HNSW index type supports dimensions > 2000 (IVFFlat is limited to 2000)
LISTS='3072' # IVF lists for PgVector (adjust based on dataset size, default: 3072 for gemini-embedding-001 1-4k limits, this so can use 3072 dims)
#PG_HNSW_M=16 # HNSW connections per layer (default: 16, higher = better recall, more memory)
#PG_HNSW_EF_CONSTRUCTION=64 # HNSW build-time candidates (default: 64, higher = better quality, slower build)
PG_M='32'
PG_EF='79' # HNSW query-time candidates (default: 100, higher = better recall, slower queries)
PG_MIN_SCORE='0.65' # Minimum similarity score for vector search results (default: 0.7, lower = more results, less relevant)
# Graph-based Retrieval Configuration
GRAPH_THRESHOLD='0.7' # Graph similarity threshold for random walk connections (0.0 - 1.0 range high to low)
GRAPH_RANDOM_WALK_STEPS='10' # Number of random walk steps for graph-based retrieval (default: 10, higher = more exploration, slower)
SEMANTIC_TOP_K='4' # Number of top semantic results to retrieve (default: 5 higher = more results, slower)
# SerpAPI
SERPAPI_API_KEY='your_serpapi_api_key_here'
# Financial APIs
ALPHA_VANTAGE_API_KEY='your_alpha_vantage_api_key_here'
FINNHUB_API_KEY='your_finnhub_api_key_here'
POLYGON_API_KEY='your_polygon_api_key_here'
# Smithery Configuration (optional, for advanced mcp)
SMITHERY_API_KEY='your_smithery_api_key_here'
SMITHERY_PROFILE='your_smithery_profile_here'
# Convex Configuration
CONVEX_URL=''
CONVEX_ADMIN_KEY=''
# Other optional, but helpful values
LOG_LEVEL='debug'
# Enable Next.js Bundle Analyzer
ANALYZE='false'
# Next.js + Mastra Client SDK
NEXT_PUBLIC_MASTRA_API_URL='http://localhost:4111'
# used by server-side code
MASTRA_API_URL='http://localhost:4111'
# Example placeholders for local testing
LOCAL_DEV='true'
# UPSTASH Configuration (for Redis and Vector DB) as an alternative to Supabase
UPSTASH_REDIS_REST_URL='your_upstash_redis_rest_url_here'
UPSTASH_REDIS_REST_TOKEN='your_upstash_redis_rest_token_here'
UPSTASH_VECTOR_REST_URL='your_upstash_vector_rest_url_here'
UPSTASH_VECTOR_REST_TOKEN='your_upstash_vector_rest_token_here'