You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

70 lines
2.9 KiB

# --- Secrets (required) ---
# OpenAI API key used server-side only (never sent to the browser).
OPENAI_API_KEY=
# Secret used to sign short-lived browser session tokens for the realtime WS handshake.
# Generate one with: node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
REALTIME_TOKEN_SECRET=
# --- Server ---
# HTTP port the production server (server.js) listens on.
# PORT=3000
# Which RealtimeProvider to use. "openai" (default) talks to the real API and
# requires OPENAI_API_KEY above. "mock" replays a canned local script instead
# — no API key needed — for client/animation work without live usage. See
# docs/REALTIME_SESSION.md's "Development without a live API".
# REALTIME_PROVIDER=openai
# --- Analytics (see docs/ANALYTICS.md and docs/CONFIGURATION.md) ---
# Master switch. Set to false to disable analytics recording entirely — no
# data/analytics.db file is created at all.
# ANALYTICS_ENABLED=true
# Where the local SQLite analytics db lives.
# ANALYTICS_DB_PATH=./data/analytics.db
# Per-category toggles, independent of ANALYTICS_ENABLED and each other.
# Set any of these to false to stop recording that category's data while
# still recording session start/end (model, voice, timing) — that volume
# signal is always recorded whenever analytics is enabled at all.
# ANALYTICS_LOG_MESSAGES=true # conversation text (both roles)
# ANALYTICS_LOG_TOOL_CALLS=true # tool call arguments/output
# ANALYTICS_LOG_EVENTS=true # errors and session.closed detail
# --- Session ---
# Overrides the model configured in src/lib/project/persona.ts. Leave unset
# to use that file's default.
# SESSION_MODEL=
# Voice used when the browser's session.start doesn't specify one. Leave
# unset to let the provider pick its own default.
# SESSION_DEFAULT_VOICE=
# How long a client-executed tool call may go unanswered before the session
# gives up on it and resolves it with an error.
# CLIENT_TOOL_TIMEOUT_MS=10000
# TTL for the short-lived token minted by POST /api/realtime/session.
# REALTIME_TOKEN_TTL_MS=60000
# --- Debug logging (see docs/LOGGING.md) ---
# Shared secret a browser must present (via the debug panel's key field) to
# receive this app's server-side debug logs in production. Separate from
# REALTIME_TOKEN_SECRET on purpose — a different blast radius if leaked.
# In dev, forwarding is always on and this is ignored entirely. Leave unset
# in prod to disable server-log forwarding for everyone (the default).
# Generate one with: node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
# DEBUG_ACCESS_KEY=
# Set to false to stop the `messages` log category (full conversation text,
# including the system prompt) from mirroring to console/stdout — useful if
# server logs are shipped somewhere less trusted than the process's own
# stdout. Independent of DEBUG_ACCESS_KEY: the debug panel itself is
# unaffected either way, since that path is already key-gated in prod.
# DEBUG_LOG_MESSAGES=true