somratpro commited on
Commit
b0dbb67
Β·
1 Parent(s): bcbf1ad

docs: reorganize README configuration into structured tables and update section headers

Browse files
Files changed (1) hide show
  1. README.md +36 -64
README.md CHANGED
@@ -28,7 +28,7 @@ license: mit
28
  - [πŸ’Ύ Workspace Backup *(Optional)*](#-workspace-backup-optional)
29
  - [πŸ“Š Dashboard & Monitoring](#-dashboard--monitoring)
30
  - [πŸ”” Webhooks *(Optional)*](#-webhooks-optional)
31
- - [βš™οΈ Full Configuration Reference](#-full-configuration-reference)
32
  - [πŸ€– LLM Providers](#-llm-providers)
33
  - [πŸ’» Local Development](#-local-development)
34
  - [πŸ”— CLI Access](#-cli-access)
@@ -87,29 +87,37 @@ To chat via Telegram:
87
 
88
  1. Create a bot via [@BotFather](https://t.me/BotFather): send `/newbot`, follow prompts, and copy the bot token.
89
  2. Find your Telegram user ID with [@userinfobot](https://t.me/userinfobot).
90
- 3. Add these secrets in Settings β†’ Secrets:
91
- - `TELEGRAM_BOT_TOKEN` – The token from @BotFather.
92
- - `TELEGRAM_USER_ID` – Your Telegram user ID (for a single user).
93
- - `TELEGRAM_USER_IDS` – Comma-separated user IDs (for team access, e.g. `123,456,789`).
94
 
95
- After restarting, the bot should appear online on Telegram.
 
 
 
 
96
 
97
  ## πŸ’¬ WhatsApp Setup *(Optional)*
98
 
99
- To use WhatsApp:
100
 
101
- 1. Add `WHATSAPP_ENABLED=true` in Hugging Face Space Variables or Secrets.
102
- 2. In the Control UI, go to **Channels** β†’ **WhatsApp** β†’ **Login**.
103
- 3. Scan the QR code with your phone. πŸ“±
104
 
105
  ## πŸ’Ύ Workspace Backup *(Optional)*
106
 
107
- For persistent chat history and configuration:
108
 
109
- - Set `HF_USERNAME` to your HuggingFace username.
110
- - Set `HF_TOKEN` to a HuggingFace token with write access.
 
 
 
 
 
 
111
 
112
- Optionally set `BACKUP_DATASET_NAME` (default: `huggingclaw-backup`) to choose the HF Dataset name. On first run, HuggingClaw will create (or use) the private Dataset repo `HF_USERNAME/SPACE-backup`, then restore your workspace on startup and sync changes every 10 minutes. The workspace is also saved on graceful shutdown. If you use WhatsApp, HuggingClaw also stores a hidden backup of the WhatsApp session credentials so paired logins can survive restarts.
 
113
 
114
  ## πŸ“Š Dashboard & Monitoring
115
 
@@ -123,59 +131,19 @@ HuggingClaw now features a built-in dashboard at `/dashboard`, served from the s
123
 
124
  Get notified when your Space restarts or if a backup fails:
125
 
126
- - Set `WEBHOOK_URL` to your endpoint (e.g., Make.com, IFTTT, Discord Webhook).
127
- - HuggingClaw sends a POST JSON payload with event details.
128
-
129
- ## βš™οΈ Full Configuration Reference
130
-
131
- See `.env.example` for runtime settings. Key configuration values:
132
-
133
- ### Core
134
-
135
- | Variable | Description |
136
- |-----------------|-------------------------------------------------------------|
137
- | `LLM_API_KEY` | LLM provider API key (e.g. OpenAI, Anthropic, etc.) |
138
- | `LLM_MODEL` | Model ID (prefix `<provider>/`, auto-detected from prefix) |
139
- | `GATEWAY_TOKEN` | Gateway token for Control UI access (required) |
140
-
141
- ### Chat Integrations
142
-
143
- | Variable | Default | Description |
144
- |-----------------------|---------|----------------------------------------------------|
145
- | `WHATSAPP_ENABLED` | `false` | Enable WhatsApp pairing/login support |
146
- | `TELEGRAM_BOT_TOKEN` | β€” | Telegram bot token from BotFather |
147
- | `TELEGRAM_USER_ID` | β€” | Single Telegram user ID allowlist |
148
- | `TELEGRAM_USER_IDS` | β€” | Comma-separated Telegram user IDs for team access |
149
 
150
- ### Background Services
151
 
152
- | Variable | Default | Description |
153
- |-----------------------|---------|---------------------------------------------|
154
- | `KEEP_ALIVE_INTERVAL` | `300` | Self-ping interval in seconds (0 to disable)|
155
- | `SYNC_INTERVAL` | `600` | Workspace sync interval (sec.) to HF Dataset|
156
 
157
- ### Security
158
-
159
- | Variable | Description |
160
- |----------------------|---------------------------------------------------------|
161
- | `OPENCLAW_PASSWORD` | (optional) Enable simple password auth instead of token |
162
- | `TRUSTED_PROXIES` | Comma-separated IPs of HF proxies |
163
- | `ALLOWED_ORIGINS` | Comma-separated allowed origins for Control UI |
164
-
165
- ### Workspace Backup
166
-
167
- | Variable | Default | Description |
168
- |-----------------------|----------------------|--------------------------------------|
169
- | `HF_USERNAME` | β€” | Your HuggingFace username |
170
- | `HF_TOKEN` | β€” | HF token with write access |
171
- | `BACKUP_DATASET_NAME` | `huggingclaw-backup` | Dataset name for backup repo |
172
- | `WORKSPACE_GIT_USER` | `openclaw@example.com`| Git commit email for workspace sync |
173
- | `WORKSPACE_GIT_NAME` | `OpenClaw Bot` | Git commit name for workspace sync |
174
-
175
- ### Advanced
176
-
177
- | Variable | Default | Description |
178
- |--------------------|----------|-------------------------------------|
179
  | `OPENCLAW_VERSION` | `latest` | Build-time pin for the OpenClaw image tag |
180
 
181
  ## πŸ€– LLM Providers
@@ -291,6 +259,10 @@ HuggingClaw keeps the Space awake without external cron tools:
291
  - **Health endpoint:** `/health` returns `200 OK` and uptime info.
292
  - **No external deps:** Fully managed within HF Spaces (no outside pingers or servers).
293
 
 
 
 
 
294
  ## πŸ› Troubleshooting
295
 
296
  - **Missing secrets:** Ensure `LLM_API_KEY`, `LLM_MODEL`, and `GATEWAY_TOKEN` are set in your Space **Settings β†’ Secrets**.
 
28
  - [πŸ’Ύ Workspace Backup *(Optional)*](#-workspace-backup-optional)
29
  - [πŸ“Š Dashboard & Monitoring](#-dashboard--monitoring)
30
  - [πŸ”” Webhooks *(Optional)*](#-webhooks-optional)
31
+ - [πŸ” Security & Advanced *(Optional)*](#-security--advanced-optional)
32
  - [πŸ€– LLM Providers](#-llm-providers)
33
  - [πŸ’» Local Development](#-local-development)
34
  - [πŸ”— CLI Access](#-cli-access)
 
87
 
88
  1. Create a bot via [@BotFather](https://t.me/BotFather): send `/newbot`, follow prompts, and copy the bot token.
89
  2. Find your Telegram user ID with [@userinfobot](https://t.me/userinfobot).
90
+ 3. Add these secrets in Settings β†’ Secrets. After restarting, the bot should appear online on Telegram.
 
 
 
91
 
92
+ | Variable | Default | Description |
93
+ | :--- | :--- | :--- |
94
+ | `TELEGRAM_BOT_TOKEN` | β€” | Telegram bot token from BotFather |
95
+ | `TELEGRAM_USER_ID` | β€” | Single Telegram user ID allowlist |
96
+ | `TELEGRAM_USER_IDS` | β€” | Comma-separated Telegram user IDs for team access |
97
 
98
  ## πŸ’¬ WhatsApp Setup *(Optional)*
99
 
100
+ To use WhatsApp, enable the channel and scan the QR code from the Control UI (**Channels** β†’ **WhatsApp** β†’ **Login**):
101
 
102
+ | Variable | Default | Description |
103
+ | :--- | :--- | :--- |
104
+ | `WHATSAPP_ENABLED` | `false` | Enable WhatsApp pairing support |
105
 
106
  ## πŸ’Ύ Workspace Backup *(Optional)*
107
 
108
+ For persistent chat history and configuration, HuggingClaw can sync your workspace to a private HuggingFace Dataset. On first run, it will automatically create (or use) the Dataset repo `HF_USERNAME/SPACE-backup`, restore your workspace on startup, and sync changes periodically.
109
 
110
+ | Variable | Default | Description |
111
+ | :--- | :--- | :--- |
112
+ | `HF_USERNAME` | β€” | Your HuggingFace username |
113
+ | `HF_TOKEN` | β€” | HF token with write access |
114
+ | `BACKUP_DATASET_NAME` | `huggingclaw-backup` | Dataset name for backup repo |
115
+ | `SYNC_INTERVAL` | `600` | Sync interval in seconds |
116
+ | `WORKSPACE_GIT_USER` | `openclaw@example.com` | Git commit email for syncs |
117
+ | `WORKSPACE_GIT_NAME` | `OpenClaw Bot` | Git commit name for syncs |
118
 
119
+ > [!TIP]
120
+ > This backup also stores a hidden copy of your WhatsApp session credentials, allowing paired logins to survive Space restarts automatically.
121
 
122
  ## πŸ“Š Dashboard & Monitoring
123
 
 
131
 
132
  Get notified when your Space restarts or if a backup fails:
133
 
134
+ | Variable | Default | Description |
135
+ | :--- | :--- | :--- |
136
+ | `WEBHOOK_URL` | β€” | Endpoint URL for POST JSON notifications |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
137
 
138
+ ## πŸ” Security & Advanced *(Optional)*
139
 
140
+ Configure password access and network restrictions:
 
 
 
141
 
142
+ | Variable | Default | Description |
143
+ | :--- | :--- | :--- |
144
+ | `OPENCLAW_PASSWORD` | β€” | Enable simple password auth instead of token |
145
+ | `TRUSTED_PROXIES` | β€” | Comma-separated IPs of HF proxies |
146
+ | `ALLOWED_ORIGINS` | β€” | Comma-separated allowed origins for Control UI |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
147
  | `OPENCLAW_VERSION` | `latest` | Build-time pin for the OpenClaw image tag |
148
 
149
  ## πŸ€– LLM Providers
 
259
  - **Health endpoint:** `/health` returns `200 OK` and uptime info.
260
  - **No external deps:** Fully managed within HF Spaces (no outside pingers or servers).
261
 
262
+ | Variable | Default | Description |
263
+ | :--- | :--- | :--- |
264
+ | `KEEP_ALIVE_INTERVAL` | `300` | Self-ping interval in seconds (0 to disable) |
265
+
266
  ## πŸ› Troubleshooting
267
 
268
  - **Missing secrets:** Ensure `LLM_API_KEY`, `LLM_MODEL`, and `GATEWAY_TOKEN` are set in your Space **Settings β†’ Secrets**.