环境变量¶
InnoClaw 使用的所有环境变量的完整参考。
核心配置¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
是 |
— |
以逗号分隔的绝对路径,用于创建工作空间。目录必须在服务器上已存在。 |
|
|
否 |
|
SQLite database filesystem path. Set to a local path when the project resides on NFS or another network filesystem. |
|
|
否 |
|
Next.js build output directory. Set to a local filesystem path to avoid Turbopack cache errors on network/shared filesystems. |
AI 提供商配置¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
用于对话和嵌入的 OpenAI API 密钥。 |
|
|
否 |
— |
用于 Claude 模型的 Anthropic API 密钥。 |
|
|
否 |
— |
Google Gemini API key for Gemini models. |
|
|
否 |
|
自定义 OpenAI 兼容 API 端点(用于代理或第三方提供商)。 |
|
|
否 |
|
自定义 Anthropic API 端点。 |
|
|
否 |
— |
Custom Gemini-compatible API endpoint (OpenAI-compatible proxy). |
|
|
否 |
|
Default LLM provider: |
|
|
否 |
|
Default model ID. Overridable in Settings UI. |
备注
At least one AI API key (OpenAI, Anthropic, or Gemini) is needed for AI chat and note generation features. Without any API key, workspace management, file browsing, and other non-AI features still work.
Agent Configuration¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
|
Maximum agent tool-call steps per request (1–100). Higher values allow complex multi-step tasks but cost more tokens. |
Embedding API 配置¶
这些配置允许使用独立于对话模型提供商的单独服务来生成向量嵌入。
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
回退到 |
Embedding 服务的 API 密钥。 |
|
|
否 |
回退到 |
Embedding 服务的端点。 |
|
|
否 |
|
要使用的 Embedding 模型名称。 |
示例 —— 使用专用的 Embedding 服务:
# Chat model (via OpenAI-compatible proxy)
OPENAI_API_KEY=sk-your-chat-key
OPENAI_BASE_URL=http://your-proxy:3888/v1
# Embedding model (separate configuration)
EMBEDDING_API_KEY=sk-your-embedding-key
EMBEDDING_BASE_URL=http://your-proxy:3888/v1
EMBEDDING_MODEL=google/gemini-embedding-001
GitHub 集成¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
用于克隆/拉取私有仓库的 GitHub 个人访问令牌。需要 |
HuggingFace / ModelScope Datasets¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
HuggingFace access token. Avoids rate limits when downloading datasets. Also settable via the Settings UI. |
|
|
否 |
|
Local directory for downloaded HuggingFace/ModelScope datasets. |
SCP Hub (Scientific Skills)¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
API key for the Intern-Discovery Platform, enabling 206 built-in SCP scientific skills (drug discovery, protein analysis, genomics, chemistry, etc.). |
HTTP Proxy¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
HTTP proxy for all outbound |
|
|
否 |
— |
HTTPS proxy. Typically the same value as |
|
|
否 |
— |
Comma-separated hosts/CIDRs that bypass the proxy, e.g. |
飞书机器人配置¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
|
启用飞书机器人集成。 |
|
|
否 |
— |
飞书应用 ID。 |
|
|
否 |
— |
飞书应用密钥。 |
|
|
否 |
— |
用于验证飞书 Webhook 请求的令牌。 |
|
|
否 |
— |
飞书事件负载的加密密钥。 |
|
|
否 |
— |
Shared secret for authenticating the push API ( |
|
|
否 |
|
SDK log verbosity: |
企业微信机器人配置¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
|
启用企业微信机器人集成。 |
|
|
否 |
— |
企业微信企业 ID。 |
|
|
否 |
— |
企业微信应用密钥。 |
|
|
否 |
— |
用于验证企业微信 Webhook 请求的令牌。 |
|
|
否 |
— |
用于加密/解密企业微信消息的 AES 密钥。 |
|
|
否 |
— |
企业微信应用(代理)ID。 |
Kubernetes / Cluster Integration¶
变量 |
类型 |
必需 |
默认值 |
描述 |
|---|---|---|---|---|
|
|
否 |
— |
Path to your kubeconfig file for Kubernetes cluster access. |
|
|
否 |
— |
AD account name used as the job submitter identity. |
|
|
否 |
— |
Kubernetes secret name for pulling container images. |
|
|
否 |
— |
PersistentVolumeClaim name for AI4S shared storage. |
|
|
否 |
— |
PersistentVolumeClaim name for user storage. |
|
|
否 |
— |
PersistentVolumeClaim name for AI4S A2 partition storage. |
|
|
否 |
— |
Username for PVC mount path resolution. |
安全说明¶
所有 API 密钥和令牌仅在服务器端使用,永远不会暴露给浏览器客户端。
请安全地存储您的
.env.local文件,不要将其提交到版本控制系统。.gitignore文件已排除.env*文件(.env.example除外)。