velaclaw-dev 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitignore +14 -0
- package/ARCHITECTURE.md +143 -0
- package/README.dev.md +208 -0
- package/README.local-before-remote-sync.md +224 -0
- package/README.md +211 -0
- package/README.public.md +115 -0
- package/RELEASING.md +162 -0
- package/TESTING.md +195 -0
- package/dist/cli.js +213 -0
- package/dist/data.js +2988 -0
- package/dist/server.js +1020 -0
- package/dist/ui.js +1486 -0
- package/members/LAUNCH_CHECKLIST.md +13 -0
- package/members/README.md +17 -0
- package/members/member-template/README.md +9 -0
- package/members/member-template/private-docs/README.md +3 -0
- package/members/member-template/private-memory/README.md +3 -0
- package/members/member-template/private-skills/README.md +4 -0
- package/members/member-template/private-tools/README.md +4 -0
- package/members/member-template/runtime/config/README.md +3 -0
- package/members/member-template/runtime/config/local-plugins/member-quota-guard/index.js +123 -0
- package/members/member-template/runtime/config/local-plugins/member-quota-guard/openclaw.plugin.json +19 -0
- package/members/member-template/runtime/config/local-plugins/member-quota-guard/package.json +10 -0
- package/members/member-template/runtime/config/local-plugins/member-runtime-upgrader/index.js +97 -0
- package/members/member-template/runtime/config/local-plugins/member-runtime-upgrader/openclaw.plugin.json +21 -0
- package/members/member-template/runtime/config/local-plugins/member-runtime-upgrader/package.json +10 -0
- package/members/member-template/runtime/config/local-plugins/shared-asset-injector/index.js +548 -0
- package/members/member-template/runtime/config/local-plugins/shared-asset-injector/openclaw.plugin.json +33 -0
- package/members/member-template/runtime/config/local-plugins/shared-asset-injector/package.json +10 -0
- package/members/member-template/runtime/config/openclaw.json +104 -0
- package/members/member-template/runtime/docker-compose.yml +53 -0
- package/members/member-template/runtime/logs/README.md +3 -0
- package/members/member-template/runtime/secrets/.gitkeep +1 -0
- package/members/member-template/runtime/secrets/README.md +3 -0
- package/members/member-template/runtime/workspace/.gitkeep +1 -0
- package/members/member-template/runtime/workspace/README.md +3 -0
- package/package.json +57 -0
- package/pic/banner.jpg +0 -0
- package/provision-member.md +87 -0
- package/scripts/shared-asset-stack-test.mjs +369 -0
- package/scripts/shared-skill-combo-test.mjs +282 -0
- package/scripts/team-load-test.mjs +358 -0
- package/scripts/verify-install.mjs +44 -0
- package/services/litellm/config.yaml +35 -0
- package/services/litellm/docker-compose.yml +36 -0
- package/services/litellm/litellm.env.example +13 -0
- package/shared-snapshots/README.md +16 -0
- package/shared-snapshots/docs/README.md +3 -0
- package/shared-snapshots/memory/README.md +3 -0
- package/shared-snapshots/skills/README.md +3 -0
- package/shared-snapshots/tools/README.md +4 -0
- package/shared-snapshots/workflows/README.md +3 -0
- package/team-assets/README.md +11 -0
- package/team-assets/policies/README.md +7 -0
- package/team-assets/policies/asset-visibility.md +24 -0
- package/team-assets/policies/high-risk-action-approval.md +18 -0
- package/team-assets/policies/promotion-rules.md +25 -0
- package/team-assets/policies/tool-binding-rules.md +26 -0
- package/team-assets/shared-docs/README.md +3 -0
- package/team-assets/shared-memory/README.md +8 -0
- package/team-assets/shared-skills/README.md +8 -0
- package/team-assets/shared-tools/README.md +8 -0
- package/team-assets/shared-workflows/README.md +9 -0
package/.gitignore
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
node_modules/
|
|
2
|
+
dist/
|
|
3
|
+
*.log
|
|
4
|
+
state/*.json
|
|
5
|
+
!state/.gitkeep
|
|
6
|
+
|
|
7
|
+
members/*/runtime/secrets/*
|
|
8
|
+
!members/*/runtime/secrets/.gitkeep
|
|
9
|
+
|
|
10
|
+
members/*/runtime/workspace/*
|
|
11
|
+
!members/*/runtime/workspace/.gitkeep
|
|
12
|
+
|
|
13
|
+
members/*/runtime/config/team-policy.json
|
|
14
|
+
members/*/runtime/config/team-usage.json
|
package/ARCHITECTURE.md
ADDED
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
# Velaclaw Architecture v1
|
|
2
|
+
|
|
3
|
+
This directory defines a practical first-stage architecture for a team-oriented OpenClaw deployment using:
|
|
4
|
+
|
|
5
|
+
- one primary host instance as the control plane
|
|
6
|
+
- multiple secondary Docker instances as member runtimes
|
|
7
|
+
- shared team assets separated from member-private assets
|
|
8
|
+
- minimal direct sharing of writable state
|
|
9
|
+
|
|
10
|
+
## Goals
|
|
11
|
+
|
|
12
|
+
- keep the primary user instance in control
|
|
13
|
+
- isolate each member runtime from the primary workspace
|
|
14
|
+
- support both team-shared and member-private assets
|
|
15
|
+
- avoid direct access from child containers to host Docker or host secrets
|
|
16
|
+
- keep the design simple enough to run today on a single machine
|
|
17
|
+
|
|
18
|
+
## High-level model
|
|
19
|
+
|
|
20
|
+
### Control plane (host primary instance)
|
|
21
|
+
Responsible for:
|
|
22
|
+
- team policies
|
|
23
|
+
- team shared memory
|
|
24
|
+
- team shared skills
|
|
25
|
+
- team shared tool definitions
|
|
26
|
+
- approvals and audit decisions
|
|
27
|
+
- future asset API / synchronization
|
|
28
|
+
|
|
29
|
+
### Member runtime (one Docker container per member)
|
|
30
|
+
Responsible for:
|
|
31
|
+
- member-private memory
|
|
32
|
+
- member-private skills
|
|
33
|
+
- member-private workspace
|
|
34
|
+
- member-private credentials/bindings
|
|
35
|
+
- low-risk task execution
|
|
36
|
+
|
|
37
|
+
## Storage split
|
|
38
|
+
|
|
39
|
+
### Host control-plane assets
|
|
40
|
+
- `team-assets/`
|
|
41
|
+
- shared-memory/
|
|
42
|
+
- shared-skills/
|
|
43
|
+
- shared-tools/
|
|
44
|
+
- shared-workflows/
|
|
45
|
+
- shared-docs/
|
|
46
|
+
- policies/
|
|
47
|
+
- `teams/<team-slug>/assets/`
|
|
48
|
+
- drafts/
|
|
49
|
+
- collab/
|
|
50
|
+
- approvals/
|
|
51
|
+
- published/
|
|
52
|
+
- releases/
|
|
53
|
+
- current/
|
|
54
|
+
|
|
55
|
+
### Per-member assets
|
|
56
|
+
- `members/<member-id>/`
|
|
57
|
+
- private-memory/
|
|
58
|
+
- private-skills/
|
|
59
|
+
- private-tools/
|
|
60
|
+
- private-docs/
|
|
61
|
+
- runtime/
|
|
62
|
+
- config/
|
|
63
|
+
- workspace/
|
|
64
|
+
- secrets/
|
|
65
|
+
- logs/
|
|
66
|
+
|
|
67
|
+
## Security rules
|
|
68
|
+
|
|
69
|
+
1. Never mount host Docker socket into member containers.
|
|
70
|
+
2. Never mount the primary workspace into member containers.
|
|
71
|
+
3. Never store team secrets inside member runtime directories unless explicitly intended as team-level shared bindings.
|
|
72
|
+
4. Member containers only get:
|
|
73
|
+
- their own config
|
|
74
|
+
- their own workspace
|
|
75
|
+
- their own secrets
|
|
76
|
+
- team-scoped read-only shared snapshots
|
|
77
|
+
5. Prefer API-mediated or snapshot-based access to team assets instead of writable shared mounts.
|
|
78
|
+
6. Treat `current/` as a published snapshot, not as a collaboration directory.
|
|
79
|
+
|
|
80
|
+
## Shared vs private assets
|
|
81
|
+
|
|
82
|
+
### Shared assets
|
|
83
|
+
Examples:
|
|
84
|
+
- common skills
|
|
85
|
+
- playbooks / SOPs
|
|
86
|
+
- non-sensitive team docs
|
|
87
|
+
- common tool definitions
|
|
88
|
+
- common market analysis templates
|
|
89
|
+
|
|
90
|
+
## Governed publication flow
|
|
91
|
+
|
|
92
|
+
Team members do not write directly into the live shared snapshot.
|
|
93
|
+
|
|
94
|
+
Recommended lifecycle:
|
|
95
|
+
|
|
96
|
+
1. member creates a draft or collab asset
|
|
97
|
+
2. control plane checks the member's publication permission
|
|
98
|
+
3. if required, the asset enters the approval queue
|
|
99
|
+
4. manager/owner approves or rejects
|
|
100
|
+
5. approved assets publish into the release set
|
|
101
|
+
6. `current/` is updated for member runtimes
|
|
102
|
+
|
|
103
|
+
## Role policy examples
|
|
104
|
+
|
|
105
|
+
- `viewer`
|
|
106
|
+
- cannot propose shared assets
|
|
107
|
+
- `member` / `contributor`
|
|
108
|
+
- can propose
|
|
109
|
+
- requires approval before publish
|
|
110
|
+
- `publisher`
|
|
111
|
+
- can propose
|
|
112
|
+
- can publish without review
|
|
113
|
+
- `manager` / `owner`
|
|
114
|
+
- can approve
|
|
115
|
+
- can promote collab assets into the published layer
|
|
116
|
+
|
|
117
|
+
### Private assets
|
|
118
|
+
Examples:
|
|
119
|
+
- personal memory
|
|
120
|
+
- private credentials
|
|
121
|
+
- private Gmail or calendar bindings
|
|
122
|
+
- private preferences
|
|
123
|
+
- personal notes and drafts
|
|
124
|
+
|
|
125
|
+
## Access model
|
|
126
|
+
|
|
127
|
+
### Primary host instance can:
|
|
128
|
+
- read and manage team assets
|
|
129
|
+
- provision member runtimes
|
|
130
|
+
- publish approved shared assets
|
|
131
|
+
- eventually proxy high-risk actions
|
|
132
|
+
|
|
133
|
+
### Member runtime can:
|
|
134
|
+
- read its own private assets
|
|
135
|
+
- read allowed team assets through controlled means
|
|
136
|
+
- not directly modify host team assets unless explicitly synchronized/approved
|
|
137
|
+
|
|
138
|
+
## Recommended next steps
|
|
139
|
+
|
|
140
|
+
1. Treat this directory as the canonical Velaclaw control root.
|
|
141
|
+
2. Create one member runtime from the provided Docker template.
|
|
142
|
+
3. Keep shared assets read-only to member containers.
|
|
143
|
+
4. Introduce an asset API later if two-way sync is needed.
|
package/README.dev.md
ADDED
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="pic/banner.jpg" alt="Velaclaw — A better way for teams to work with AI" width="100%" />
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<h1 align="center">Velaclaw Dev</h1>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>The private development repository for Velaclaw.</strong><br/>
|
|
9
|
+
<sub>Assets, runtimes, onboarding, and team operations — in progress.</sub>
|
|
10
|
+
</p>
|
|
11
|
+
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="#-getting-started">Getting Started</a> ·
|
|
14
|
+
<a href="./TESTING.md">Tester Install</a> ·
|
|
15
|
+
<a href="./RELEASING.md">Release Flow</a> ·
|
|
16
|
+
<a href="#-core-capabilities">Core Capabilities</a> ·
|
|
17
|
+
<a href="#-project-structure">Project Structure</a> ·
|
|
18
|
+
<a href="#-roadmap">Roadmap</a>
|
|
19
|
+
</p>
|
|
20
|
+
|
|
21
|
+
<p align="center">
|
|
22
|
+
<img alt="Status" src="https://img.shields.io/badge/status-active--development-orange" />
|
|
23
|
+
<img alt="Runtime" src="https://img.shields.io/badge/runtime-Docker-blue" />
|
|
24
|
+
<img alt="Built on" src="https://img.shields.io/badge/built%20on-OpenClaw-black" />
|
|
25
|
+
<img alt="Repository" src="https://img.shields.io/badge/repo-private-lightgrey" />
|
|
26
|
+
</p>
|
|
27
|
+
|
|
28
|
+
---
|
|
29
|
+
|
|
30
|
+
Velaclaw Dev is where the working system takes shape.
|
|
31
|
+
This repository is focused on implementation: team assets, member runtimes, onboarding flow, runtime isolation, and the operator experience around them.
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## 🧩 Core Capabilities
|
|
36
|
+
|
|
37
|
+
<table>
|
|
38
|
+
<tr>
|
|
39
|
+
<td width="50%" valign="top">
|
|
40
|
+
|
|
41
|
+
### 🎛️ Shared System for Team AI
|
|
42
|
+
|
|
43
|
+
Velaclaw organizes AI work around **team assets** and **member assets** instead of leaving everything scattered across chats and one-off tools.
|
|
44
|
+
|
|
45
|
+
</td>
|
|
46
|
+
<td width="50%" valign="top">
|
|
47
|
+
|
|
48
|
+
### 📦 Isolated Member Runtimes
|
|
49
|
+
|
|
50
|
+
Each member runs inside an isolated Docker runtime with its own private assets, runtime config, and secrets.
|
|
51
|
+
|
|
52
|
+
</td>
|
|
53
|
+
</tr>
|
|
54
|
+
<tr>
|
|
55
|
+
<td width="50%" valign="top">
|
|
56
|
+
|
|
57
|
+
### 🔐 Asset Boundaries
|
|
58
|
+
|
|
59
|
+
Memory, skills, tools, workflows, documents, and bindings are treated as **assets**. Team assets and member assets are kept separate by design.
|
|
60
|
+
|
|
61
|
+
</td>
|
|
62
|
+
<td width="50%" valign="top">
|
|
63
|
+
|
|
64
|
+
### ✅ Approval-Aware Operations
|
|
65
|
+
|
|
66
|
+
High-risk actions go through the control plane first, so collaboration does not require giving up review or boundaries.
|
|
67
|
+
|
|
68
|
+
</td>
|
|
69
|
+
</tr>
|
|
70
|
+
</table>
|
|
71
|
+
|
|
72
|
+
---
|
|
73
|
+
|
|
74
|
+
## 🏗️ Architecture
|
|
75
|
+
|
|
76
|
+
```text
|
|
77
|
+
┌─────────────────────────────────────────────────┐
|
|
78
|
+
│ Control Plane (Host) │
|
|
79
|
+
│ │
|
|
80
|
+
│ policies · shared-assets · approvals │
|
|
81
|
+
│ asset-distribution · audit │
|
|
82
|
+
└──────────┬──────────┬──────────┬─────────────────┘
|
|
83
|
+
│ │ │
|
|
84
|
+
┌─────▼────┐┌────▼─────┐┌──▼───────┐
|
|
85
|
+
│ Member A ││ Member B ││ Member C │
|
|
86
|
+
│ (Docker) ││ (Docker) ││ (Docker) │
|
|
87
|
+
│ ││ ││ │
|
|
88
|
+
│ private ││ private ││ private │
|
|
89
|
+
│ assets ││ assets ││ assets │
|
|
90
|
+
│ runtime ││ runtime ││ runtime │
|
|
91
|
+
│ secrets ││ secrets ││ secrets │
|
|
92
|
+
└──────────┘└──────────┘└──────────┘
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
> **🛡️ Security boundary**
|
|
96
|
+
> Member containers never mount the host Docker socket, never touch the primary workspace, and never access team secrets directly. Team assets are distributed via read-only snapshots.
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## 🚀 Getting Started
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
# 1. Clone the repo
|
|
104
|
+
git clone https://github.com/Zavianx/velaclaw-dev.git
|
|
105
|
+
cd velaclaw-dev
|
|
106
|
+
|
|
107
|
+
# 2. Review the architecture
|
|
108
|
+
cat ARCHITECTURE.md
|
|
109
|
+
|
|
110
|
+
# 3. Review provisioning flow
|
|
111
|
+
cat provision-member.md
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### Run the local prototype
|
|
115
|
+
|
|
116
|
+
```bash
|
|
117
|
+
npm install -g velaclaw-dev
|
|
118
|
+
velaclaw init velaclaw-test
|
|
119
|
+
cd velaclaw-test
|
|
120
|
+
velaclaw start
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
By default the local service starts on:
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
http://127.0.0.1:4318
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
### Formal Tester Flow
|
|
130
|
+
|
|
131
|
+
If you are preparing a build for other people to test, do not send them this README alone.
|
|
132
|
+
Use these two documents:
|
|
133
|
+
|
|
134
|
+
- [TESTING.md](/home/ubuntu/.openclaw/workspace/velaclaw/TESTING.md)
|
|
135
|
+
- [RELEASING.md](/home/ubuntu/.openclaw/workspace/velaclaw/RELEASING.md)
|
|
136
|
+
|
|
137
|
+
They cover:
|
|
138
|
+
|
|
139
|
+
- host prerequisites
|
|
140
|
+
- LiteLLM env setup
|
|
141
|
+
- local startup order
|
|
142
|
+
- smoke verification
|
|
143
|
+
- current supported test scope
|
|
144
|
+
|
|
145
|
+
The intended tester install path is now:
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
npm install -g velaclaw-dev
|
|
149
|
+
velaclaw init velaclaw-test
|
|
150
|
+
cd velaclaw-test
|
|
151
|
+
velaclaw start
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
---
|
|
155
|
+
|
|
156
|
+
## 📁 Project Structure
|
|
157
|
+
|
|
158
|
+
```text
|
|
159
|
+
velaclaw-dev/
|
|
160
|
+
├── ARCHITECTURE.md # Control plane + member runtime design
|
|
161
|
+
├── provision-member.md # Member runtime provisioning guide
|
|
162
|
+
├── team-assets/ # Shared team asset sources
|
|
163
|
+
│ ├── policies/ # Team policies
|
|
164
|
+
│ ├── shared-memory/ # Shared memory assets
|
|
165
|
+
│ ├── shared-skills/ # Shared skill assets
|
|
166
|
+
│ ├── shared-tools/ # Shared tool assets
|
|
167
|
+
│ ├── shared-workflows/ # Shared workflow assets
|
|
168
|
+
│ └── shared-docs/ # Shared document assets
|
|
169
|
+
├── members/ # Per-member runtime templates and private assets
|
|
170
|
+
├── shared-snapshots/ # Read-only asset snapshots for controlled distribution
|
|
171
|
+
├── src/ # Local control-plane prototype
|
|
172
|
+
├── state/ # Team state and invitations
|
|
173
|
+
└── pic/ # Repo imagery
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
---
|
|
177
|
+
|
|
178
|
+
## 🗺️ Roadmap
|
|
179
|
+
|
|
180
|
+
**Shipped**
|
|
181
|
+
- [x] Control plane + member runtime architecture
|
|
182
|
+
- [x] Team / member asset separation
|
|
183
|
+
- [x] Member runtime provisioning flow
|
|
184
|
+
- [x] Read-only snapshot distribution
|
|
185
|
+
- [x] Local control-plane MVP
|
|
186
|
+
|
|
187
|
+
**Next**
|
|
188
|
+
- [ ] Asset sync API
|
|
189
|
+
- [ ] Approval workflow engine
|
|
190
|
+
- [ ] Runtime health and lifecycle views
|
|
191
|
+
- [ ] Invitee-facing onboarding flow
|
|
192
|
+
- [ ] Operator dashboard
|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
## Notes
|
|
197
|
+
|
|
198
|
+
This repository is intentionally more implementation-focused than the public repository.
|
|
199
|
+
Use the public repo for product-facing messaging, and this repo for the evolving system itself.
|
|
200
|
+
|
|
201
|
+
---
|
|
202
|
+
|
|
203
|
+
<p align="center">
|
|
204
|
+
<strong>Built on <a href="https://github.com/openclaw/openclaw">OpenClaw</a></strong>
|
|
205
|
+
</p>
|
|
206
|
+
<p align="center">
|
|
207
|
+
<em>A better way for teams to work with AI.</em>
|
|
208
|
+
</p>
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
# Velaclaw
|
|
2
|
+
|
|
3
|
+
**Velaclaw** is a control-plane-first multi-team AI product concept built on top of [OpenClaw](https://github.com/openclaw/openclaw).
|
|
4
|
+
|
|
5
|
+
Core idea:
|
|
6
|
+
- shared team intelligence
|
|
7
|
+
- private Docker-isolated member runtimes
|
|
8
|
+
- Docker-isolated member execution
|
|
9
|
+
- team assets and member assets split by default
|
|
10
|
+
- approval-oriented handling for high-risk actions
|
|
11
|
+
- manager-owned quota policy per member
|
|
12
|
+
|
|
13
|
+
## Current structure
|
|
14
|
+
|
|
15
|
+
- `ARCHITECTURE.md` — control-plane + member-runtime design
|
|
16
|
+
- `team-assets/` — shared team assets and policies
|
|
17
|
+
- `members/` — per-member runtime templates
|
|
18
|
+
- `shared-snapshots/` — read-only team asset snapshots for controlled distribution
|
|
19
|
+
- `provision-member.md` — how to create a new member runtime
|
|
20
|
+
- `src/` — runnable local control-plane MVP
|
|
21
|
+
|
|
22
|
+
## MVP prototype
|
|
23
|
+
|
|
24
|
+
The repository now includes a runnable local Node/TypeScript prototype that reads the repository layout and exposes it as a control-plane API.
|
|
25
|
+
|
|
26
|
+
### Endpoints
|
|
27
|
+
|
|
28
|
+
- `GET /health`
|
|
29
|
+
- `GET /team`
|
|
30
|
+
- `GET /team/:slug`
|
|
31
|
+
- `GET /invite/:code`
|
|
32
|
+
- `GET /api/team`
|
|
33
|
+
- `GET /api/teams`
|
|
34
|
+
- `GET /api/teams/:slug`
|
|
35
|
+
- `GET /api/team/assets`
|
|
36
|
+
- `GET /api/members`
|
|
37
|
+
- `GET /api/teams/:slug/members`
|
|
38
|
+
- `GET /api/members/:id/assets`
|
|
39
|
+
- `GET /api/teams/:slug/members/:id/assets`
|
|
40
|
+
- `GET /api/members/:id/runtime`
|
|
41
|
+
- `GET /api/teams/:slug/members/:id/runtime`
|
|
42
|
+
- `POST /api/members/provision`
|
|
43
|
+
- `POST /api/teams`
|
|
44
|
+
- `POST /api/teams/:slug/profile`
|
|
45
|
+
- `POST /api/teams/:slug/invitations`
|
|
46
|
+
- `POST /api/teams/:slug/members/provision`
|
|
47
|
+
- `POST /api/teams/:slug/members/:id/quota`
|
|
48
|
+
- `POST /api/teams/:slug/members/:id/secrets/telegram`
|
|
49
|
+
- `POST /api/teams/:slug/members/:id/onboard/start`
|
|
50
|
+
- `POST /api/teams/:slug/members/:id/runtime/:action`
|
|
51
|
+
- `POST /api/members/:id/secrets/telegram`
|
|
52
|
+
- `POST /api/members/:id/onboard/start`
|
|
53
|
+
- `POST /api/members/:id/runtime/:action`
|
|
54
|
+
- `POST /api/team/profile`
|
|
55
|
+
- `POST /api/team/invitations`
|
|
56
|
+
- `POST /api/team/members/:id/quota`
|
|
57
|
+
- `POST /api/team/invitations/:id/revoke`
|
|
58
|
+
- `POST /api/team/invitations/:code/accept`
|
|
59
|
+
|
|
60
|
+
### What it does today
|
|
61
|
+
|
|
62
|
+
- lists team-shared asset buckets under `team-assets/`
|
|
63
|
+
- lists read-only snapshot buckets under `shared-snapshots/`
|
|
64
|
+
- lists member runtime folders under `members/`
|
|
65
|
+
- reports whether a member has runtime/config/compose files
|
|
66
|
+
- exposes a lightweight landing page at `/`
|
|
67
|
+
- exposes a real team workspace at `/team`
|
|
68
|
+
- exposes a multi-team index at `/team` and per-team workspaces at `/team/:slug`
|
|
69
|
+
- provisions a new member runtime from `members/member-template/`
|
|
70
|
+
- auto-assigns the next free local port starting from `18800`
|
|
71
|
+
- generates a gateway token when one is not supplied
|
|
72
|
+
- stores team profile and invitation state in `state/team.json`
|
|
73
|
+
- turns a shareable invite link into a provisioned member skeleton
|
|
74
|
+
- writes a manager-owned runtime policy file for each accepted member
|
|
75
|
+
- lets the team manager update member quotas from `/team`
|
|
76
|
+
- syncs allowed models and max thinking into the member runtime config
|
|
77
|
+
- ships a member-side quota guard plugin that hard-blocks paused members and message quota overruns
|
|
78
|
+
- surfaces Docker runtime status, launch commands, and start/stop/restart actions for each member
|
|
79
|
+
- lets the manager save a member Telegram bot token from the control plane
|
|
80
|
+
- moves a member runtime from `needs-secrets` to `ready` once policy + token are both present
|
|
81
|
+
- exposes a bot-side command surface through the main OpenClaw bot plugin
|
|
82
|
+
- supports multiple teams, each with its own invites, quota policy, and member runtime tree
|
|
83
|
+
|
|
84
|
+
## Getting started
|
|
85
|
+
|
|
86
|
+
### Run locally
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
npm install
|
|
90
|
+
npm run dev
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
By default the local service starts on:
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
http://127.0.0.1:4318
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
### First steps
|
|
100
|
+
|
|
101
|
+
```bash
|
|
102
|
+
# 1. Clone the repo
|
|
103
|
+
git clone https://github.com/Zavianx/velaclaw-dev.git
|
|
104
|
+
cd velaclaw-dev
|
|
105
|
+
|
|
106
|
+
# 2. Start the local control plane
|
|
107
|
+
npm install
|
|
108
|
+
npm run dev
|
|
109
|
+
|
|
110
|
+
# 3. Open the team workspace
|
|
111
|
+
open http://127.0.0.1:4318/team
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
If `open` is unavailable on your machine, just visit the URL in your browser.
|
|
115
|
+
|
|
116
|
+
### Production-style run
|
|
117
|
+
|
|
118
|
+
```bash
|
|
119
|
+
npm run build
|
|
120
|
+
npm start
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Provision a member
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
curl -X POST http://127.0.0.1:4318/api/members/provision \
|
|
127
|
+
-H 'content-type: application/json' \
|
|
128
|
+
-d '{
|
|
129
|
+
"memberId": "zane",
|
|
130
|
+
"telegramUserId": "8555695623",
|
|
131
|
+
"identityName": "小虾-zane"
|
|
132
|
+
}'
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
Response highlights:
|
|
136
|
+
|
|
137
|
+
- generated member paths
|
|
138
|
+
- selected local port
|
|
139
|
+
- generated gateway token
|
|
140
|
+
- pending placeholders still requiring operator input
|
|
141
|
+
|
|
142
|
+
### Team and invitation flow
|
|
143
|
+
|
|
144
|
+
Open:
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
http://127.0.0.1:4318/team
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
From `/team` you can:
|
|
151
|
+
|
|
152
|
+
- list existing teams
|
|
153
|
+
- create a new team
|
|
154
|
+
- enter `/team/:slug` for a specific team
|
|
155
|
+
|
|
156
|
+
Inside a specific team page you can:
|
|
157
|
+
|
|
158
|
+
- set your team name and description
|
|
159
|
+
- set the visible team manager label
|
|
160
|
+
- create invite links
|
|
161
|
+
- open `/invite/<code>` pages
|
|
162
|
+
- accept an invite and provision a new member skeleton
|
|
163
|
+
- pause or tighten a member quota without touching the member's private workspace
|
|
164
|
+
- inspect runtime readiness and use start/stop/restart controls
|
|
165
|
+
- paste a member Telegram bot token and finish onboarding from `/team`
|
|
166
|
+
|
|
167
|
+
### Bot command surface
|
|
168
|
+
|
|
169
|
+
The main OpenClaw bot now loads a local plugin that intercepts team commands:
|
|
170
|
+
|
|
171
|
+
- `/team`
|
|
172
|
+
- `/team <slug>`
|
|
173
|
+
- `/create team <slug> <name>`
|
|
174
|
+
- `/members`
|
|
175
|
+
- `/invite <member_id> <label>`
|
|
176
|
+
- `/create invite <member_id> <label>`
|
|
177
|
+
- `/join <invite_code> [identity_name]`
|
|
178
|
+
- `/runtime <member_id>`
|
|
179
|
+
|
|
180
|
+
This means the operator can manage Velaclaw from the bot chat instead of only through the web page.
|
|
181
|
+
|
|
182
|
+
Current shape:
|
|
183
|
+
|
|
184
|
+
- `/team` lists teams and tells you what is currently selected
|
|
185
|
+
- `/team <slug>` switches into a specific team context
|
|
186
|
+
- `/create team <slug> <name>` creates a new team from chat
|
|
187
|
+
- `/invite` creates an invitation code
|
|
188
|
+
- `/join` accepts the invitation using the sender's Telegram user id
|
|
189
|
+
- `/runtime` shows the target member runtime state and launch commands
|
|
190
|
+
|
|
191
|
+
## Current enforcement model
|
|
192
|
+
|
|
193
|
+
- each accepted member gets a Docker-isolated runtime skeleton
|
|
194
|
+
- the team manager owns quota policy in the control plane
|
|
195
|
+
- accepted members receive `runtime/config/team-policy.json`
|
|
196
|
+
- the member runtime loads `member-quota-guard`, which currently enforces:
|
|
197
|
+
- paused / active runtime state
|
|
198
|
+
- daily message quota
|
|
199
|
+
- monthly message quota
|
|
200
|
+
- allowed models and max thinking are synchronized into the generated member `openclaw.json`
|
|
201
|
+
- `/team` now shows Docker reachability, expected container name, published port, and launch commands for each member
|
|
202
|
+
- member Telegram bot tokens are written to the member runtime secrets directory with `0600` permissions
|
|
203
|
+
|
|
204
|
+
Current gap:
|
|
205
|
+
|
|
206
|
+
- `maxSubagents` is stored in policy, but the current member template still keeps subagents disabled by default
|
|
207
|
+
- runtime actions use host Docker via `sudo -n docker`, so production hardening still needs a more explicit execution boundary
|
|
208
|
+
|
|
209
|
+
## Positioning
|
|
210
|
+
|
|
211
|
+
Velaclaw is not just a chat UI or a generic team agent hub.
|
|
212
|
+
It is intended to become a:
|
|
213
|
+
|
|
214
|
+
- team AI control plane
|
|
215
|
+
- shared/private asset governance layer
|
|
216
|
+
- isolated runtime management model for OpenClaw-based teams
|
|
217
|
+
|
|
218
|
+
## Next likely steps
|
|
219
|
+
|
|
220
|
+
- add snapshot publish/sync actions
|
|
221
|
+
- add policy-aware approval flow
|
|
222
|
+
- add stronger runtime health/detail views
|
|
223
|
+
- add a full invitee-facing onboarding page instead of operator-only setup on `/team`
|
|
224
|
+
- add a real operator dashboard
|