Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
182 changes: 177 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,24 @@ jobs:
> ```
> Then open the app normally. This only needs to be done once.

### CLI Binary (Terminal Only)
| Platform | Download | Size |
|----------|----------|------|
| **Linux** (x64) | [`cachi-linux-x64.tar.gz`](https://github.com/${{ github.repository }}/releases/download/v${{ steps.bump_version.outputs.new_version }}/cachi-linux-x64.tar.gz) | — |
| **macOS** (Apple Silicon) | [`cachi-mac-arm64.tar.gz`](https://github.com/${{ github.repository }}/releases/download/v${{ steps.bump_version.outputs.new_version }}/cachi-mac-arm64.tar.gz) | — |
| **Windows** (x64) | [`cachi-win-x64.zip`](https://github.com/${{ github.repository }}/releases/download/v${{ steps.bump_version.outputs.new_version }}/cachi-win-x64.zip) | — |

### Mini Server (Dashboard — no Python required)
| Platform | Download | Size |
|----------|----------|------|
| **Linux** (x64) | [`cachibot-server-mini-linux-x64.tar.gz`](https://github.com/${{ github.repository }}/releases/download/v${{ steps.bump_version.outputs.new_version }}/cachibot-server-mini-linux-x64.tar.gz) | — |

> Lightweight server with web dashboard, database, and auth. No knowledge base or platform integrations. Ideal for Raspberry Pi, VPS, and edge deployments.

### Python Package (pip)
```bash
pip install cachibot==${{ steps.bump_version.outputs.new_version }}
pip install cachibot==${{ steps.bump_version.outputs.new_version }} # CLI only
pip install cachibot[full]==${{ steps.bump_version.outputs.new_version }} # CLI + server + all extras
```

---
Expand Down Expand Up @@ -222,7 +237,7 @@ jobs:
shell: bash
run: |
echo "${{ needs.release.outputs.new_version }}" > VERSION
pip install -e .
pip install -e ".[full]"
pip install pyinstaller

- name: Clean __pycache__
Expand Down Expand Up @@ -275,6 +290,157 @@ jobs:
name: ${{ matrix.artifact }}
path: dist/cachibot-server/

# =========================================================================
# 2b. Build CLI-only binary with PyInstaller (3 platforms)
# =========================================================================
build-cli:
needs: release
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
artifact: cachi-linux-x64
archive_name: cachi-linux-x64.tar.gz
archive_cmd: tar -czf
- os: macos-latest
artifact: cachi-mac-arm64
archive_name: cachi-mac-arm64.tar.gz
archive_cmd: tar -czf
- os: windows-latest
artifact: cachi-win-x64
archive_name: cachi-win-x64.zip
archive_cmd: zip -r

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
with:
ref: v${{ needs.release.outputs.new_version }}

- uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: pip

- name: Install CachiBot (core only) + PyInstaller
shell: bash
run: |
echo "${{ needs.release.outputs.new_version }}" > VERSION
pip install -e .
pip install pyinstaller

- name: Clean __pycache__
shell: bash
run: find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true

- name: Build CLI binary
run: pyinstaller cachibot-cli.spec --clean

Copilot AI Mar 4, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow references cachibot-cli.spec (line 339) and cachibot-server-mini.spec (line 403), but neither file exists in the repository. The build-cli and build-server-mini jobs will fail at the PyInstaller step. These spec files need to be created and included in this PR.

Suggested change
run: pyinstaller cachibot-cli.spec --clean
run: pyinstaller -n cachi --distpath dist/cachi -F -m cachi --clean

Copilot uses AI. Check for mistakes.

- name: Smoke test CLI binary
shell: bash
run: |
BINARY="./dist/cachi/cachi"
if [[ "$RUNNER_OS" == "Windows" ]]; then
BINARY="./dist/cachi/cachi.exe"
fi
"$BINARY" --help
echo "CLI smoke test passed"

- name: Archive CLI binary
shell: bash
run: |
cd dist
if [[ "${{ matrix.archive_name }}" == *.zip ]]; then
${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/
else
${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/
fi
Comment on lines +355 to +359

Copilot AI Mar 4, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The if and else branches are identical — both execute ${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/. The conditional is dead code. Since archive_cmd already varies per matrix entry (tar -czf vs zip -r), the if/else is unnecessary and should be simplified to a single unconditional command.

Suggested change
if [[ "${{ matrix.archive_name }}" == *.zip ]]; then
${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/
else
${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/
fi
${{ matrix.archive_cmd }} "${{ matrix.archive_name }}" cachi/

Copilot uses AI. Check for mistakes.

- name: Upload CLI archive to GitHub Release
shell: bash
run: |
gh release upload "v${{ needs.release.outputs.new_version }}" \
"dist/${{ matrix.archive_name }}" \
--clobber
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# =========================================================================
# 2c. Build mini server binary (Linux only — for Pi / VPS / edge)
# =========================================================================
build-server-mini:
needs: release
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
with:
ref: v${{ needs.release.outputs.new_version }}

- name: Download frontend artifact
uses: actions/download-artifact@v4
with:
name: frontend-dist
path: frontend/dist

- uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: pip

- name: Install CachiBot (server extras) + PyInstaller
run: |
echo "${{ needs.release.outputs.new_version }}" > VERSION
pip install -e ".[server]"
pip install pyinstaller

- name: Clean __pycache__
run: find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true

- name: Build mini server binary
run: pyinstaller cachibot-server-mini.spec --clean

Copilot AI Mar 4, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow references cachibot-server-mini.spec, but this file does not exist in the repository. This job will fail at the PyInstaller step. A spec file for the mini server build must be created and included in this PR.

Suggested change
run: pyinstaller cachibot-server-mini.spec --clean
run: pyinstaller cachibot-server-mini.py --name cachibot-server-mini --clean

Copilot uses AI. Check for mistakes.

- name: Smoke test mini server binary
timeout-minutes: 2
run: |
PORT=15870
./dist/cachibot-server-mini/cachibot-server-mini --port $PORT --host 127.0.0.1 &
SERVER_PID=$!

for i in $(seq 1 60); do
if curl -sf "http://127.0.0.1:$PORT/api/health" > /dev/null 2>&1; then
echo "Server healthy after ${i}s"
break
fi
if ! kill -0 $SERVER_PID 2>/dev/null; then
echo "ERROR: Server exited prematurely"
exit 1
fi
sleep 1
done

HEALTH=$(curl -sf "http://127.0.0.1:$PORT/api/health")
echo "Health: $HEALTH"
Comment on lines +412 to +425

Copilot AI Mar 4, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the health endpoint never becomes healthy within 60 iterations, the for loop exits silently without an explicit failure. The subsequent curl -sf on line 424 will fail (thanks to set -e), but the error message will be confusing — it won't indicate a timeout. Consider adding an explicit failure after the loop, e.g., checking a variable set on success or failing with a clear "Timed out waiting for server" message.

Copilot uses AI. Check for mistakes.

kill $SERVER_PID 2>/dev/null || true
wait $SERVER_PID 2>/dev/null || true
echo "Mini server smoke test passed"

- name: Archive mini server binary
run: |
cd dist
tar -czf cachibot-server-mini-linux-x64.tar.gz cachibot-server-mini/

- name: Upload to GitHub Release
run: |
gh release upload "v${{ needs.release.outputs.new_version }}" \
"dist/cachibot-server-mini-linux-x64.tar.gz" \
--clobber
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# =========================================================================
# 3. Build Electron desktop app (3 platforms)
# =========================================================================
Expand Down Expand Up @@ -355,8 +521,8 @@ jobs:
files-folder: ${{ github.workspace }}/release
files-folder-filter: exe

# Re-upload signed Windows exe to GitHub Release
- name: Upload signed exe to release
# Re-upload signed Windows exe and regenerate latest.yml
- name: Upload signed exe and update latest.yml
if: matrix.platform == 'win'
shell: bash
run: |
Expand All @@ -365,6 +531,12 @@ jobs:
EXE_PATH="${{ github.workspace }}/release/${EXE_NAME}"
if [[ -f "$EXE_PATH" ]]; then
gh release upload "v${VERSION}" "$EXE_PATH" --clobber
SHA512=$(openssl dgst -sha512 -binary "$EXE_PATH" | openssl base64 -A)
SIZE=$(wc -c < "$EXE_PATH" | tr -d ' ')
RELEASE_DATE=$(date -u +"%Y-%m-%dT%H:%M:%S.000Z")
printf 'version: %s\nfiles:\n - url: %s\n sha512: %s\n size: %s\npath: %s\nsha512: %s\nreleaseDate: '\''%s'\''\n' \
"$VERSION" "$EXE_NAME" "$SHA512" "$SIZE" "$EXE_NAME" "$SHA512" "$RELEASE_DATE" > latest.yml
gh release upload "v${VERSION}" latest.yml --clobber
fi
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -422,7 +594,7 @@ jobs:
# 5. Update release body with actual asset sizes
# =========================================================================
update-release:
needs: [release, build-desktop, build-mobile]
needs: [release, build-cli, build-server-mini, build-desktop, build-mobile]
runs-on: ubuntu-latest

steps:
Expand Down
85 changes: 65 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<h1>CachiBot</h1>

<p><strong>The Armored AI Agent</strong></p>
<p><em>Visual. Transparent. Secure.</em></p>
<p><em>Lightweight. Modular. Armored.</em></p>

<p>
<a href="https://cachibot.ai">Website</a> ·
Expand Down Expand Up @@ -49,9 +49,43 @@

## Why CachiBot?

Most AI platforms force you to choose: chatbot UIs with no automation, workflow builders with no conversational AI, or developer frameworks that take weeks to ship.
### Lean by Default

**CachiBot gives you all three.** Build specialized bots, deploy them to any messaging platform, run them in collaborative rooms, and automate workflows — all from a visual dashboard with full transparency into what your agents are doing.
Most AI agent frameworks install the kitchen sink. CachiBot doesn't.

```
pip install cachibot
```

That gives you a fully functional AI agent with tool use, sandboxed code execution, file operations, and 14+ LLM providers. The full install tree is **~36 packages** — mostly small, pure-Python libraries. No FastAPI. No SQLAlchemy. No torch. No numpy. No 200MB embedding models downloading on first run.

Pick exactly what you need — mix and match:

```bash
pip install cachibot # just the agent
pip install cachibot[server] # + web dashboard
pip install cachibot[server,telegram] # + dashboard + Telegram
pip install cachibot[server,knowledge] # + dashboard + RAG
pip install cachibot[server,discord,slack] # + dashboard + Discord + Slack
pip install cachibot[full] # everything
```

| Extra | What It Adds |
|-------|-------------|
| `server` | Web dashboard, database, auth, WebSocket streaming |
| `knowledge` | RAG pipeline — PDF/DOCX ingestion, vector search, embeddings |
| `telegram` | Telegram bot adapter |
| `discord` | Discord bot adapter |
| `slack` | Slack bot adapter |
| `teams` | Microsoft Teams bot adapter |
| `platforms` | All platform adapters |
| `full` | All of the above |

Or skip Python entirely — grab the `cachi` standalone binary from [Releases](https://github.com/jhd3197/CachiBot/releases). One file. No runtime.

### Full Platform When You Need It

CachiBot scales from a terminal command to a multi-agent platform. Build specialized bots, deploy them to any messaging platform, run them in collaborative rooms, and automate workflows — all from a visual dashboard with full transparency into what your agents are doing.


![arepa-war](https://github.com/user-attachments/assets/5996fc02-0c4c-4a61-a998-f007189494fd)
Expand Down Expand Up @@ -87,16 +121,20 @@ irm cachibot.ai/install.ps1 | iex
### pip

```bash
pip install cachibot
pip install cachibot # agent only — see "Lean by Default" above for all extras
cachibot server # start the dashboard (requires cachibot[server])
```

Then start the server:
### Standalone Binaries

```bash
cachibot server
```
Pre-built binaries on every release — no Python required:

| Binary | What It Is | Platforms |
|--------|-----------|-----------|
| `cachi` | Terminal agent (CLI only) | Linux x64, macOS ARM64, Windows x64 |
| `cachibot-server-mini` | Web dashboard + database + auth | Linux x64 |

Open **http://localhost:5870** — the frontend is bundled and served automatically. No separate build step.
The mini server is the full web UI without knowledge base or platform integrations — runs on a Raspberry Pi, a $5/mo VPS, anywhere. Grab them from [GitHub Releases](https://github.com/jhd3197/CachiBot/releases).

### Docker

Expand All @@ -123,17 +161,24 @@ export MOONSHOT_API_KEY="your-key" # Kimi

### CLI Usage

Works with both `cachibot` and the short alias `cachi`:

```bash
cachi "summarize this project" # Run a single task
cachi # Interactive mode
cachi --model claude/sonnet # Override model
cachi --workspace ./my-project # Set workspace
cachi --approve # Require approval for each action
cachi --verbose # Show thinking process
```

With `cachibot[server]` installed:

```bash
cachibot server # Start the dashboard
cachibot "summarize this project" # Run a single task
cachibot # Interactive mode
cachibot --model claude/sonnet # Override model
cachibot --workspace ./my-project # Set workspace
cachibot --approve # Require approval for each action
cachibot --verbose # Show thinking process
cachibot diagnose # Check installation health
cachibot repair # Fix corrupted installation
cachi server # Short alias
cachi server # Start the web dashboard
cachi db migrate # Run database migrations
cachi diagnose # Check installation health
cachi repair # Fix corrupted installation
```

## Features
Expand Down Expand Up @@ -301,7 +346,7 @@ cd CachiBot

# Backend
python -m venv venv && source venv/bin/activate # or .\venv\Scripts\activate on Windows
pip install -e ".[dev]"
pip install -e ".[full,dev]"

# Frontend
cd frontend && npm install && cd ..
Expand Down
Loading
Loading