@zibby/skills 0.1.96 → 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/README.md +1 -1
- package/dist/artifact.d.ts +1 -115
- package/dist/browser.d.ts +10 -19
- package/dist/chartRender.d.ts +46 -57
- package/dist/chartRender.js +1 -1
- package/dist/chat-memory.d.ts +26 -330
- package/dist/chat-notify.d.ts +30 -409
- package/dist/chat-notify.js +3 -3
- package/dist/chatProgress.d.ts +28 -47
- package/dist/code-scan.d.ts +52 -58
- package/dist/codeStats.d.ts +36 -136
- package/dist/codeStats.js +1 -1
- package/dist/codebaseMemory.d.ts +52 -32
- package/dist/codebaseMemory.js +2 -2
- package/dist/core-tools.d.ts +10 -131
- package/dist/datasetStore.d.ts +52 -326
- package/dist/discord.d.ts +32 -68
- package/dist/figma.d.ts +5 -408
- package/dist/function-skill.d.ts +23 -135
- package/dist/function-skill.js +1 -1
- package/dist/gbrain.d.ts +46 -114
- package/dist/git-write.d.ts +45 -137
- package/dist/git-write.js +6 -6
- package/dist/git.d.ts +2 -73
- package/dist/github.d.ts +2 -1202
- package/dist/gitlab.d.ts +55 -1059
- package/dist/gitlab.js +2 -2
- package/dist/googleDocs.d.ts +39 -175
- package/dist/hubspot.d.ts +1 -381
- package/dist/index.d.ts +19 -12
- package/dist/index.js +135 -135
- package/dist/integrations.d.ts +2 -2
- package/dist/jira.d.ts +2 -532
- package/dist/jira.js +4 -4
- package/dist/kvMemory.d.ts +47 -78
- package/dist/lark.d.ts +2 -161
- package/dist/lark.js +1 -1
- package/dist/larkDocs.d.ts +35 -236
- package/dist/linear.d.ts +36 -343
- package/dist/linkedin.d.ts +10 -120
- package/dist/llm-billing.d.ts +92 -180
- package/dist/llm-billing.js +1 -1
- package/dist/memory.d.ts +11 -137
- package/dist/notion.d.ts +28 -276
- package/dist/notion.js +4 -4
- package/dist/opendesign.d.ts +24 -202
- package/dist/opendesign.js +2 -2
- package/dist/package.json +3 -2
- package/dist/plane.d.ts +40 -24
- package/dist/report.d.ts +153 -110
- package/dist/review-dedup.d.ts +8 -8
- package/dist/review.d.ts +12 -2
- package/dist/reviewMemoryIo.d.ts +37 -3
- package/dist/reviewRecord.d.ts +41 -47
- package/dist/sentry.d.ts +25 -22
- package/dist/skill-installer.d.ts +11 -86
- package/dist/slack.d.ts +1 -284
- package/dist/socialCard.d.ts +35 -89
- package/dist/test-runner.d.ts +1 -220
- package/dist/trackers/github-adapter.d.ts +39 -94
- package/dist/trackers/index.d.ts +25 -18
- package/dist/trackers/jira-adapter.d.ts +20 -88
- package/dist/trackers/linear-adapter.d.ts +24 -87
- package/dist/trackers/plane-adapter.d.ts +29 -85
- package/dist/trackers/plane-adapter.js +1 -1
- package/dist/trackers/types.d.ts +1 -186
- package/dist/triggerAgent.d.ts +26 -42
- package/dist/triggerAgent.js +1 -1
- package/dist/workflow-builder.d.ts +11 -245
- package/docs/concepts/designing-agents.md +201 -0
- package/docs/self-host/backup-restore.md +52 -0
- package/docs/self-host/index.md +75 -0
- package/docs/self-host/storage.md +50 -0
- package/docs/self-host/troubleshooting.md +48 -0
- package/docs/self-host/upgrade.md +81 -0
- package/package.json +3 -2
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 5
|
|
3
|
+
title: Troubleshooting
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Troubleshooting
|
|
7
|
+
|
|
8
|
+
A self-hosted box is **one VM** — control-plane container + Scylla + object store + ephemeral run containers. When something is slow or failing, diagnose from the box's own logs; the reflex "it doesn't scale / the VM is overloaded" is almost always wrong (a `top` usually shows the box near-idle).
|
|
9
|
+
|
|
10
|
+
## First moves
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
top # CPU / memory — usually reveals it's idle
|
|
14
|
+
docker ps -a # are containers Up? did a run container Exit?
|
|
15
|
+
docker logs zibby-control-plane --tail 100 # the executor + reaper + API
|
|
16
|
+
docker logs zibby-bootstrap # first-boot template sync + the seeded token
|
|
17
|
+
curl -s http://localhost:3001/health # control-plane health
|
|
18
|
+
curl -s http://localhost:3001/selfhost/version # the running release (baked, authoritative)
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
To query the box's own API, use its `PROJECT_API_TOKEN` from `.env`:
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
curl -H "Authorization: Bearer <zby_...>" \
|
|
25
|
+
"http://localhost:3001/executions?projectId=selfhosted-project"
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
A failed run's `reapedReason` field tells you why it was reaped. (The cloud Zibby MCP/CLI talks to the *cloud* backend — it cannot reach a self-host box; you need the box's own token.)
|
|
29
|
+
|
|
30
|
+
## Failure signatures worth recognizing
|
|
31
|
+
|
|
32
|
+
**Runs "fail" with empty steps + `pull access denied for zibby-agent … repository does not exist`.** An agent-image tag mismatch after an upgrade — the executor is launching a tag the reused `.env` doesn't have. Fixed at the root in installer 0.1.53+; immediate unblock:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
docker tag zibby-agent:slim zibby-agent:local
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
**The dashboard shows the new version but the API still behaves like the old one.** `docker compose up -d` can judge a service "up to date" when only the image *content* changed. The installer force-recreates the control-plane container to avoid this; if you hit it, re-run the installer (or `docker compose up -d --no-deps --force-recreate control-plane`). Because `/selfhost/version` reads the **baked** file, a genuine version mismatch is *visible* rather than hidden behind a lying env-var label.
|
|
39
|
+
|
|
40
|
+
**Control plane won't become healthy right after boot.** Scylla cold-boots slowly (~1–2 min). The installer waits up to ~5 min; if it's still unhealthy, read `docker logs zibby-control-plane` — a broken data path shows up there, not in `top`.
|
|
41
|
+
|
|
42
|
+
**An upgrade ended at `rolled_back`.** The box is safe (back on the prior version). Read `GET /selfhost/upgrade/status` `logTail` for the failing phase, and check `docker logs zibby-control-plane`. Re-attempt with a **pinned** version (see [Upgrade & rollback](./upgrade)).
|
|
43
|
+
|
|
44
|
+
## Where things live
|
|
45
|
+
|
|
46
|
+
- **Data** — docker volumes `scylla-data` + the object store volume. Back them up (see [Backup & restore](./backup-restore)); they survive restarts but not `down -v`.
|
|
47
|
+
- **`.env`** — the runtime source of truth (`JWT_SECRET`, `ENCRYPTION_KEY`, tokens, `MAX_CONCURRENT_RUNS`, `AGENT_IMAGE`). Reused untouched on upgrade.
|
|
48
|
+
- **Upgrade backups + logs** — `<install-dir>/backups/upgrade-<id>/`.
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 2
|
|
3
|
+
title: Upgrade & rollback
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Upgrade & rollback
|
|
7
|
+
|
|
8
|
+
## Check the running version
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
curl -s http://<host>:3001/selfhost/version
|
|
12
|
+
# {"version":"0.1.126"}
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
This reads the **immutable file `/app/SELFHOST_VERSION`**, baked into the image at build time from `selfhosted/package.json`. It ships inside the image layer, so it **always matches the code actually running** and cannot be spoofed by a runtime env / compose `.env` override. That is the point: if an upgrade did not actually swap the control-plane image (a silent-upgrade failure), the baked file still reports the old version — you *see* the mismatch instead of trusting a lying label.
|
|
16
|
+
|
|
17
|
+
The dashboard renders this same value as a small `v0.1.126` label in the sidebar, so the running release is always visible. (The dashboard has no upgrade button — upgrades are driven by the API endpoint or by re-running the installer, below.)
|
|
18
|
+
|
|
19
|
+
The latest published version is in the release manifest:
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
curl -s https://dl.zibby.app/selfhosted/latest/manifest.env
|
|
23
|
+
# ZIBBY_SELFHOSTED_VERSION=0.1.126
|
|
24
|
+
# IMAGE_TARBALL=zibby-selfhosted-0.1.126.tar.gz
|
|
25
|
+
# ...
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Two ways to upgrade
|
|
29
|
+
|
|
30
|
+
### 1. Re-run the installer (in place)
|
|
31
|
+
|
|
32
|
+
The installer is idempotent — re-running it pulls a newer release, verifies + `docker load`s the new images, re-pins `AGENT_IMAGE`, and **force-recreates** the control-plane container from the freshly loaded image:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
curl -fsSL https://dl.zibby.app/selfhosted/latest/install.sh | bash
|
|
36
|
+
# or, from the install dir: cd zibby-selfhosted && bash install.sh
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Your `.env` (JWT_SECRET, ENCRYPTION_KEY, tokens) and data volumes are preserved.
|
|
40
|
+
|
|
41
|
+
### 2. The owner-only remote upgrade (recommended)
|
|
42
|
+
|
|
43
|
+
`POST /selfhost/upgrade` runs a **safe, self-driving upgrade** with an automatic backup and rollback — you can trigger it remotely and it survives the control-plane restart. It is **owner-only**: the endpoint requires the workspace-owner PAT/session or the admin project token (a run token or a non-owner member is refused `403`).
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
curl -s -X POST http://<host>:3001/selfhost/upgrade \
|
|
47
|
+
-H "Authorization: Bearer <owner-or-admin-token>" \
|
|
48
|
+
-H "Content-Type: application/json" \
|
|
49
|
+
-d '{"version":"0.1.126"}'
|
|
50
|
+
# → 202 { "upgradeId": "...", "phase": "starting", ... }
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Because a container can't recreate itself, the control plane launches a **detached helper** container (with the host docker socket) that outlives the control-plane bounce and drives the upgrade end to end:
|
|
54
|
+
|
|
55
|
+
1. **backup** — flush Scylla, tar the Scylla + object-store volumes, copy `.env`, into `<install-dir>/backups/upgrade-<id>/`.
|
|
56
|
+
2. **anchor** — pin the current control-plane image as `zibby-control-plane:rollback-<id>` so the new `docker load` can't garbage-collect the rollback target.
|
|
57
|
+
3. **download → install** — fetch the target release's `install.sh` (Ed25519 + checksum verified), `docker load`, re-pin `AGENT_IMAGE`, force-recreate.
|
|
58
|
+
4. **healthcheck** — poll the new control plane until container-healthy **and** `GET /selfhost/version` returns the target version.
|
|
59
|
+
5. **rollback** — on an unhealthy new control plane (or an installer that exited non-zero), re-tag the anchor back to `:local` and force-recreate → back to the working version.
|
|
60
|
+
|
|
61
|
+
Poll the status (owner-only, read-only):
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
curl -s http://<host>:3001/selfhost/upgrade/status \
|
|
65
|
+
-H "Authorization: Bearer <owner-or-admin-token>"
|
|
66
|
+
# { "upgrade": { "phase": "install", ... }, "logTail": "...", "history": [...] }
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Phases progress `starting → backup → anchor → download → install → healthcheck → success`. A failed upgrade ends at `rolled_back` (the box is back on the prior, healthy version) or, if even rollback fails, `rollback_failed` (manual restore needed — the backup dir and rollback-anchor tag are named in the status). The control plane restarts mid-upgrade, so the poll may briefly fail to connect — that is expected.
|
|
70
|
+
|
|
71
|
+
:::warning Pin the exact version, not `latest`
|
|
72
|
+
`{"version":"latest"}` resolves through the CDN, which can serve a **stale cached** `latest` for a while after a publish. For a deterministic upgrade, pass the exact version you verified against `manifest.env` (e.g. `{"version":"0.1.126"}`). The helper also treats "healthy but the version didn't advance to the pinned target" as a failure and rolls back — a guard you only get with a pinned version.
|
|
73
|
+
:::
|
|
74
|
+
|
|
75
|
+
## If a run fails with empty steps after an upgrade
|
|
76
|
+
|
|
77
|
+
Symptom: reviews/runs "fail" with `steps: []` and the control-plane log shows `pull access denied for zibby-agent … repository does not exist`. That is an **agent-image tag mismatch** — the executor is trying to launch a tag the reused `.env` points at but the tarball loaded a different one. Installer 0.1.53+ fixes this at the root (it pins `AGENT_IMAGE` to the loaded tag and aliases `zibby-agent:local`). Immediate operator unblock:
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
docker tag zibby-agent:slim zibby-agent:local
|
|
81
|
+
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zibby/skills",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "Built-in skill definitions for the Zibby agent-workflow framework",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -141,6 +141,7 @@
|
|
|
141
141
|
"esbuild": "^0.28.0",
|
|
142
142
|
"eslint": "^10.0.2",
|
|
143
143
|
"globals": "^17.4.0",
|
|
144
|
-
"typescript": "^5.9.3"
|
|
144
|
+
"typescript": "^5.9.3",
|
|
145
|
+
"@types/node": "^20.14.0"
|
|
145
146
|
}
|
|
146
147
|
}
|