-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.sample
More file actions
207 lines (148 loc) · 7.11 KB
/
.env.sample
File metadata and controls
207 lines (148 loc) · 7.11 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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
# =============================================================================
# Memory Engine Server — Environment Variables
# =============================================================================
# Copy to .env and fill in the required values.
# -----------------------------------------------------------------------------
# Required
# -----------------------------------------------------------------------------
# PostgreSQL connection string for the accounts database
# (stores identities, orgs, engines, sessions, API keys)
ACCOUNTS_DATABASE_URL=postgres://postgres:postgres@localhost:5432/me
# 32-byte hex key for encrypting API keys at rest
# Generate with: openssl rand -hex 32
ACCOUNTS_MASTER_KEY=
# PostgreSQL connection string for the engine database
# (stores memories — each engine gets its own schema)
ENGINE_DATABASE_URL=postgres://postgres:postgres@localhost:5432/me
# Public base URL for OAuth callbacks
API_BASE_URL=http://localhost:3000
# OpenAI API key (or compatible provider) for generating embeddings
EMBEDDING_API_KEY=
# -----------------------------------------------------------------------------
# OAuth Providers
# -----------------------------------------------------------------------------
# At least one provider is required for user authentication.
# GitHub OAuth app credentials
# Create at: https://github.com/settings/developers
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
# Google OAuth app credentials
# Create at: https://console.cloud.google.com/apis/credentials
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
# -----------------------------------------------------------------------------
# Optional — Server
# -----------------------------------------------------------------------------
# HTTP server port
# PORT=3000
# Maximum request body size in bytes (default: 1048576 = 1 MiB).
# Raise for memory.batchCreate-heavy workloads (e.g. transcript imports).
# MAX_REQUEST_BODY_BYTES=
# Schema name in the accounts database
# ACCOUNTS_SCHEMA=accounts
# Cron schedule for cleaning up expired device authorizations (UTC)
# DEVICE_FLOW_CLEANUP_CRON=*/15 * * * *
# -----------------------------------------------------------------------------
# Optional — Telemetry
# -----------------------------------------------------------------------------
# Logfire token for OpenTelemetry export (omit to disable)
# LOGFIRE_TOKEN=
# LOGFIRE_ENVIRONMENT=prod
# Print spans to console (useful for local development)
# LOGFIRE_CONSOLE=true
# Disable scrubbing of sensitive fields (content, embeddings, tokens)
# LOGFIRE_SCRUBBING=false
# -----------------------------------------------------------------------------
# Optional — Accounts Database Connection Pool
# -----------------------------------------------------------------------------
# Maximum connections in pool
# ACCOUNTS_POOL_MAX=10
# Close idle pooled connections after N seconds
# ACCOUNTS_POOL_IDLE_REAP_SECONDS=300
# Max connection lifetime in seconds (0 = forever)
# ACCOUNTS_POOL_MAX_LIFETIME=0
# Timeout for establishing new connections (seconds)
# ACCOUNTS_POOL_CONNECTION_TIMEOUT=30
# PostgreSQL statement timeout for accounts DB transactions
# ACCOUNTS_STATEMENT_TIMEOUT=25s
# PostgreSQL lock wait timeout for accounts DB transactions
# ACCOUNTS_LOCK_TIMEOUT=5s
# PostgreSQL transaction timeout for accounts DB transactions
# ACCOUNTS_TRANSACTION_TIMEOUT=30s
# PostgreSQL idle-in-transaction timeout for accounts DB transactions
# ACCOUNTS_IDLE_IN_TRANSACTION_SESSION_TIMEOUT=30s
# -----------------------------------------------------------------------------
# Optional — Engine Database Connection Pool
# -----------------------------------------------------------------------------
# Maximum connections in pool
# ENGINE_POOL_MAX=20
# Close idle pooled connections after N seconds
# ENGINE_POOL_IDLE_REAP_SECONDS=300
# Max connection lifetime in seconds (0 = forever)
# ENGINE_POOL_MAX_LIFETIME=0
# Timeout for establishing new connections (seconds)
# ENGINE_POOL_CONNECTION_TIMEOUT=30
# PostgreSQL statement timeout for engine DB transactions
# ENGINE_STATEMENT_TIMEOUT=25s
# PostgreSQL lock wait timeout for engine DB transactions
# ENGINE_LOCK_TIMEOUT=5s
# PostgreSQL transaction timeout for engine DB transactions
# ENGINE_TRANSACTION_TIMEOUT=30s
# PostgreSQL idle-in-transaction timeout for engine DB transactions
# ENGINE_IDLE_IN_TRANSACTION_SESSION_TIMEOUT=30s
# -----------------------------------------------------------------------------
# Optional — Embedding
# -----------------------------------------------------------------------------
# Base URL for the embedding API (omit for OpenAI default)
# EMBEDDING_BASE_URL=
# Timeout per embedding API call (ms)
# EMBEDDING_TIMEOUT_MS=
# Max retries on transient failures (default: 2, from Vercel AI SDK)
# EMBEDDING_MAX_RETRIES=
# Max concurrent chunk requests for batch embedding (default: Infinity)
# EMBEDDING_MAX_PARALLEL_CALLS=
# -----------------------------------------------------------------------------
# Optional — Embedding Worker
# -----------------------------------------------------------------------------
# Number of concurrent embedding workers
# WORKER_COUNT=2
# Queue entries to claim per batch
# WORKER_BATCH_SIZE=10
# PostgreSQL interval for claim lock duration
# WORKER_LOCK_DURATION=5 minutes
# Poll interval when idle (ms)
# WORKER_IDLE_DELAY_MS=10000
# Max error backoff (ms)
# WORKER_MAX_BACKOFF_MS=60000
# Engine re-discovery interval (ms)
# WORKER_REFRESH_INTERVAL_MS=60000
# -----------------------------------------------------------------------------
# Optional — Embedding Worker Engine Database
# -----------------------------------------------------------------------------
# PostgreSQL connection string for embedding worker engine traffic.
# Defaults to ENGINE_DATABASE_URL when unset.
# WORKER_ENGINE_DATABASE_URL=postgres://postgres:postgres@localhost:5432/me
# Maximum connections in the dedicated embedding worker engine pool.
# Defaults to max(WORKER_COUNT, 1) when unset.
# WORKER_ENGINE_POOL_MAX=2
# Close idle embedding worker engine connections after N seconds.
# Defaults to ENGINE_POOL_IDLE_REAP_SECONDS when unset.
# WORKER_ENGINE_POOL_IDLE_REAP_SECONDS=300
# Max embedding worker engine connection lifetime in seconds (0 = forever).
# Defaults to ENGINE_POOL_MAX_LIFETIME when unset.
# WORKER_ENGINE_POOL_MAX_LIFETIME=0
# Timeout for establishing embedding worker engine connections (seconds).
# Defaults to ENGINE_POOL_CONNECTION_TIMEOUT when unset.
# WORKER_ENGINE_POOL_CONNECTION_TIMEOUT=30
# PostgreSQL statement timeout for embedding worker engine DB transactions
# Defaults to ENGINE_STATEMENT_TIMEOUT when unset.
# WORKER_ENGINE_STATEMENT_TIMEOUT=25s
# PostgreSQL lock wait timeout for embedding worker engine DB transactions
# Defaults to ENGINE_LOCK_TIMEOUT when unset.
# WORKER_ENGINE_LOCK_TIMEOUT=5s
# PostgreSQL transaction timeout for embedding worker engine DB transactions
# Defaults to ENGINE_TRANSACTION_TIMEOUT when unset.
# WORKER_ENGINE_TRANSACTION_TIMEOUT=30s
# PostgreSQL idle-in-transaction timeout for embedding worker engine DB transactions
# Defaults to ENGINE_IDLE_IN_TRANSACTION_SESSION_TIMEOUT when unset.
# WORKER_ENGINE_IDLE_IN_TRANSACTION_SESSION_TIMEOUT=30s