AI Assistant, Embeddings & Mail
FynnCloud’s AI Assistant, Vector Embeddings (Semantic Search), and Transactional Mail (SMTP) are all configured dynamically through Administration → Settings (with optional environment / <KEY>_FILE overrides and encrypted .secret storage).
For real-time calling and push notification infrastructure, see the dedicated LiveKit WebRTC SFU & TURN and Push Notifications & PushRelay guides.
AI Assistant (Ask AI)
Section titled “AI Assistant (Ask AI)”The AI Assistant works with any OpenAI-compatible /v1/chat/completions provider—including OpenAI, Anthropic proxies, OpenRouter, Mistral, Azure OpenAI, Ollama, vLLM, and llama.cpp.
| Setting Key | Environment Variable | Default | Range / Notes |
|---|---|---|---|
aiEnabled |
AI_ENABLED |
true |
Enable/disable Ask AI (note: standalone Compose sets AI_ENABLED=false by default) |
aiApiUrl |
AI_API_URL (aliases AI_URL, OPENAI_BASE_URL) |
https://api.openai.com/v1/chat/completions |
Chat completions endpoint (SSRF-validated; redirects disabled) |
aiApiKey |
AI_API_KEY (alias OPENAI_API_KEY) |
"" (secret) |
Bearer token (optional for local unauthenticated Ollama/vLLM) |
aiModel |
AI_MODEL |
gpt-4o-mini |
Model identifier sent in chat completion requests |
aiMaxToolIterations |
AI_MAX_TOOL_ITERATIONS |
12 |
Max agentic tool-calling turns per prompt (1..50) |
rateLimitAi |
RATE_LIMIT_AI (alias AI_RATE_LIMIT) |
20 |
Requests per minute per user (1..1000) |
Testing the AI Connection
Section titled “Testing the AI Connection”Use Test Connection in Administration → Settings → AI (or POST /api/ai/test). FynnCloud validates the target URL against SSRF rules using a non-redirecting HTTP client (15-second timeout) and sends a minimal 5-token "ping" completion, returning latency in milliseconds without leaking raw upstream error bodies.
Semantic File Search (pgvector Embeddings)
Section titled “Semantic File Search (pgvector Embeddings)”When backed by PostgreSQL with pgvector (default in AIO, Docker Compose, and Kubernetes), FynnCloud automatically enqueues ProcessFileEmbeddingJob in Vapor Queues whenever supported documents or images are uploaded or modified, enabling natural-language semantic matches inside ⌘K Hybrid Search.
| Setting Key | Environment Variable | Default | Range / Notes |
|---|---|---|---|
aiEmbeddingEnabled |
AI_EMBEDDING_ENABLED (alias EMBEDDING_ENABLED) |
true |
Enable background embedding generation & semantic search |
aiEmbeddingUrl |
AI_EMBEDDING_URL (alias EMBEDDING_URL) |
http://localhost:8000 |
OpenAI-compatible embeddings runner URL |
aiEmbeddingApiKey |
AI_EMBEDDING_API_KEY (alias EMBEDDING_API_KEY) |
"" (secret) |
Optional Bearer API key |
aiEmbeddingModel |
AI_EMBEDDING_MODEL (alias EMBEDDING_MODEL) |
jinaai/jina-clip-v2 |
Multimodal text + image embedding model |
aiSemanticSearchThreshold |
AI_SEMANTIC_SEARCH_THRESHOLD (alias SEMANTIC_SEARCH_THRESHOLD) |
0.75 |
Minimum cosine similarity score (0.0..1.0) |
Testing & Reindexing Embeddings
Section titled “Testing & Reindexing Embeddings”- Test connection: Click Test Embedding Connection in Admin Settings or call
POST /api/ai/test-embedding. - Reindex all files: After enabling embeddings on an existing drive or switching
aiEmbeddingModel, trigger a full reindex from Admin Settings (POST /api/ai/reindex) or run the CLI command./FynnCloudServer reindex-files.
Transactional Mail (SMTP)
Section titled “Transactional Mail (SMTP)”FynnCloud sends transactional emails (share invitations, password resets, security notifications, test emails) asynchronously via SendEmailJob over Vapor Queues.
| Setting Key | Environment Variable | Default | Range / Notes |
|---|---|---|---|
mailSmtpHost |
MAIL_SMTP_HOST (alias SMTP_HOST) |
"" |
SMTP server hostname (empty disables SMTP) |
mailSmtpPort |
MAIL_SMTP_PORT (alias SMTP_PORT) |
587 |
1..65535 (587 STARTTLS, 465 SSL/TLS, 25 plaintext) |
mailSmtpUsername |
MAIL_SMTP_USERNAME (alias SMTP_USERNAME) |
"" |
SMTP auth username |
mailSmtpPassword |
MAIL_SMTP_PASSWORD (alias SMTP_PASSWORD) |
"" (secret) |
SMTP auth password |
mailSmtpEncryption |
MAIL_SMTP_ENCRYPTION (alias SMTP_ENCRYPTION) |
"starttls" |
starttls, ssl, or none |
mailFromAddress |
MAIL_FROM_ADDRESS |
"" |
Sender email address (e.g. noreply@cloud.example.com) |
mailFromName |
MAIL_FROM_NAME |
"" |
Sender display name (e.g. FynnCloud) |