Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
d00e50c
feat: implement opencto mobile app mvp v1 ios foundation
Mar 3, 2026
b59c5b4
feat(landing): redesign opencto landing for conversion and trust
Mar 3, 2026
20a3134
chore: downgrade mobile app to expo sdk 54
Mar 3, 2026
a8e8c02
feat: rebrand mobile app with opencto assets and theme
Mar 3, 2026
c50a96a
feat(sdk): scaffold @heysalad/opencto client package
Mar 3, 2026
1526006
feat(sdk): add mqtt transport and protocol v1 foundation
Mar 3, 2026
4cdfd62
feat(sdk): add oauth device flow and token store adapters
Mar 3, 2026
ad94660
feat(sdk): add mqtt inbound dedupe controls
Mar 3, 2026
4138c2e
feat(sdk): add mqtt publish retry delivery policy
Mar 3, 2026
7735310
feat(cli): scaffold opencto sdk-powered commands
Mar 3, 2026
2e53317
feat(cli): add workflow directory commands
Mar 3, 2026
e81acfe
feat(cli): load workflow directory from json or yaml files
Mar 3, 2026
79afb49
fix(sdk,cli): harden esm runtime imports and add workflow starter file
Mar 3, 2026
ed87899
chore(release): bump sdk and cli to v0.1.1
Mar 3, 2026
ac13ba0
feat(api): add encrypted BYOK keys and llm endpoint rate limits
Mar 3, 2026
4b42c6c
feat: add byok workspace wiring and endpoint hardening tests
Mar 3, 2026
1881338
fix(api): enforce workspace access for byok keys
Mar 3, 2026
cec9316
docs: add opencto sdk-cli release runbook and script
Mar 3, 2026
2b04638
docs: fix markdownlint formatting in opencto runbooks
Mar 3, 2026
37d8eee
docs: add sdk-cli quickstart and e2e demo script
Mar 3, 2026
5bb4572
feat: add opencto cto-playbook skills pack and installer
Mar 3, 2026
34afcc1
fix: clarify ios device vs simulator build profiles
Mar 4, 2026
2368c51
feat: launchpad mobile voice runs
Mar 4, 2026
7e48259
fix: redact exposed cloudflare token and remove local settings file
Mar 4, 2026
e40d826
fix: harden mobile realtime connection and typecheck gates
Mar 4, 2026
e0c4076
fix: disable ios simulator build profiles
Mar 4, 2026
358f4aa
feat: add github oauth login flow for mobile
Mar 4, 2026
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
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,6 @@ Thumbs.db
.env
.env.*
\!.env.example

# Agent local settings (may contain local tokens/permissions)
**/.claude/settings.local.json
6 changes: 6 additions & 0 deletions docs/opencto/HF_CHERI_OPENVINO_EVALUATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ On the server:
- Hugging Face token with access to the model (`HF_TOKEN`)

Set token:

```bash
export HF_TOKEN='hf_...'
```
Expand Down Expand Up @@ -53,6 +54,7 @@ pip install "torch>=2.3" "transformers>=4.50" "accelerate>=0.34" "huggingface_hu
```

Quick latency check:

```bash
python3 - <<'PY'
import os, time
Expand All @@ -74,12 +76,14 @@ PY
## 5) OpenVINO Export + Runtime

Install:

```bash
source .venv-cheri/bin/activate
pip install -U "optimum-intel[openvino]" "openvino>=2024.4"
```

Export (try int8 first, then int4 if supported):

```bash
optimum-cli export openvino \
--model HeySalad/Cheri-ML-1.3B \
Expand All @@ -89,6 +93,7 @@ optimum-cli export openvino \
```

If int8 fails or is too slow, try:

```bash
optimum-cli export openvino \
--model HeySalad/Cheri-ML-1.3B \
Expand All @@ -98,6 +103,7 @@ optimum-cli export openvino \
```

Run OpenVINO inference benchmark:

```bash
python3 - <<'PY'
import time
Expand Down
4 changes: 3 additions & 1 deletion docs/opencto/NEXT_STEPS_RPI.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ Move from scaffolded frontend/mocks to production-ready backend-backed auth, bil
## 3. RPi Execution Plan (Ordered)

### Step A: Sync and branch from latest main

```bash
cd /home/admin/CTO-AI
# or: cd /home/peter/CTO-AI-phase2-clean
Expand All @@ -36,6 +37,7 @@ git checkout -b feat/opencto-phase7-backend-auth-billing-compliance
```

### Step B: Validate local baseline before edits

```bash
cd opencto/opencto-dashboard
npm install
Expand Down Expand Up @@ -98,6 +100,7 @@ Frontend already has `signInWithProvider(provider)` contract. Next:
- CI green on lint/build/test.

## 5. Recommended First RPi Prompt (Copy/Paste)

```text
Implement Phase 7 backend-live integration for OpenCTO.

Expand Down Expand Up @@ -125,4 +128,3 @@ Rules:
- Workstream 1: Backend auth/session.
- Workstream 2: Billing + Stripe webhook pipeline.
- Workstream 3: Jobs/compliance live data + websocket stream.

9 changes: 7 additions & 2 deletions docs/opencto/REALTIME_AGENT_CODEX_TASK.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ interface AudioConfig {
The Cloudflare Worker backend. Relevant endpoints:

**Token endpoint** (already working):

```
POST /api/v1/realtime/token
Authorization: Bearer demo-token
Expand All @@ -171,6 +172,7 @@ Body: { "model": "gpt-4o-realtime-preview" }
```

**Tool proxy endpoints** (already wired, need VERCEL_TOKEN / CF_API_TOKEN / CF_ACCOUNT_ID secrets set):

```
GET /api/v1/cto/vercel/projects
GET /api/v1/cto/vercel/projects/:id/deployments
Expand Down Expand Up @@ -318,6 +320,7 @@ getUserMedia({ audio: true })
```

The worklet code (inline Blob) converts Float32 mic samples → Int16 PCM16:

```js
class PcmCaptureProcessor extends AudioWorkletProcessor {
process(inputs) {
Expand Down Expand Up @@ -368,7 +371,7 @@ Browser → sends { type: "response.create", response: {} }
### Server events to handle

| Event type | What to do |
|---|---|
| --- | --- |
| `session.created` | Log it; optionally send session.update here instead of on ws.onopen |
| `session.updated` | Log it |
| `conversation.item.input_audio_transcription.completed` | Emit `user_transcript` event with `event.transcript` |
Expand All @@ -385,7 +388,7 @@ Browser → sends { type: "response.create", response: {} }
When `response.function_call_arguments.done` fires with `name`, dispatch to:

| `name` | Worker endpoint | How to call |
|---|---|---|
| --- | --- | --- |
| `list_vercel_projects` | `GET /api/v1/cto/vercel/projects` | no args |
| `list_vercel_deployments` | `GET /api/v1/cto/vercel/projects/{projectId}/deployments` | args.projectId |
| `get_vercel_deployment` | `GET /api/v1/cto/vercel/deployments/{deploymentId}` | args.deploymentId |
Expand Down Expand Up @@ -477,11 +480,13 @@ All must pass with 0 errors.
## Environment Variables

`.env.local` (already set, do not change):

```
VITE_API_BASE_URL=https://opencto-api-worker.heysalad-o.workers.dev
```

Cloudflare Worker secrets (set separately with `wrangler secret put`):

```
OPENAI_API_KEY ← already set on the deployed worker
VERCEL_TOKEN ← set this for Vercel tool calls to work
Expand Down
79 changes: 79 additions & 0 deletions docs/opencto/SDK_CLI_QUICKSTART.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
# OpenCTO SDK + CLI Quickstart

## Install

SDK:

```bash
npm install @heysalad/opencto@0.1.1
```

CLI:

```bash
npm install -g @heysalad/opencto-cli@0.1.1
```

## SDK Quickstart

```ts
import { createOpenCtoClient } from '@heysalad/opencto'

const client = createOpenCtoClient({
baseUrl: process.env.OPENCTO_API_BASE_URL ?? 'https://api.opencto.works',
getToken: () => process.env.OPENCTO_TOKEN ?? null,
})

const session = await client.auth.getSession()
console.log(session.user?.email)
```

## CLI Quickstart

Set baseline environment:

```bash
export OPENCTO_API_BASE_URL="https://api.opencto.works"
export OPENCTO_WORKSPACE="ws_demo"
```

Authenticate:

```bash
opencto login --workspace "$OPENCTO_WORKSPACE"
```

List workflow directory:

```bash
opencto workflow list --workspace "$OPENCTO_WORKSPACE"
```

Run a workflow:

```bash
opencto workflow run engineering-ci \
--workspace "$OPENCTO_WORKSPACE" \
--repo-url https://github.com/org/repo \
--wait
```

## Scripted Demo

Use:

```bash
./opencto/scripts/demo-opencto-e2e.sh --repo-url https://github.com/org/repo
```

The script runs:

1. optional `opencto login`
2. `opencto workflow list`
3. `opencto workflow run custom ... --wait`

## Package Links

- npm SDK: https://www.npmjs.com/package/@heysalad/opencto
- npm CLI: https://www.npmjs.com/package/@heysalad/opencto-cli
- GitHub release: https://github.com/Hey-Salad/CTO-AI/releases/tag/v0.1.1
10 changes: 10 additions & 0 deletions docs/opencto/VOICE_BACKEND_RUNBOOK.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,48 +64,56 @@ Expected ingress:
## 6) Operations Commands

Service status:

```bash
sudo systemctl status opencto-voice-backend --no-pager -n 50
sudo systemctl status cloudflared --no-pager -n 50
```

Restart services:

```bash
sudo systemctl restart opencto-voice-backend
sudo systemctl restart cloudflared
```

Tail logs:

```bash
journalctl -u opencto-voice-backend -f
journalctl -u cloudflared -f
```

Port checks:

```bash
ss -ltnp | rg '8090|cloudflared|uvicorn'
```

## 7) Smoke Tests

Local app health:

```bash
curl -sS http://127.0.0.1:8090/health
```

Public health:

```bash
curl -sS https://cloud-services-api.opencto.works/health
```

Local response:

```bash
curl -sS -X POST http://127.0.0.1:8090/v1/respond \
-H 'Content-Type: application/json' \
-d '{"text":"Say hello in one line"}'
```

Public response:

```bash
curl -sS -X POST https://cloud-services-api.opencto.works/v1/respond \
-H 'Content-Type: application/json' \
Expand All @@ -132,10 +140,12 @@ curl -sS -X POST https://cloud-services-api.opencto.works/v1/respond \
## 10) Migration to Repo-Managed Deployment (Recommended)

1. Clone repo:

```bash
cd /home/hs-chilu/heysalad-ai-projects
git clone git@github.com:Hey-Salad/CTO-AI.git
```

2. Create backend runtime dir from repo source (or update service `WorkingDirectory`).
3. Validate with local health check.
4. Switch systemd `WorkingDirectory` + `ExecStart` to repo-managed path.
Expand Down
73 changes: 73 additions & 0 deletions opencto.workflows.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"workflows": [
{
"id": "engineering-ci",
"name": "Engineering CI",
"description": "Install, lint, test, and build with pnpm defaults.",
"commandTemplates": [
"pnpm install --frozen-lockfile",
"pnpm lint",
"pnpm test",
"pnpm build"
]
},
{
"id": "founder-landing-launch",
"name": "Founder Landing Launch",
"description": "Validate and build landing page plus dashboard for deployment.",
"commandTemplates": [
"cd opencto/opencto-landing && npm ci",
"cd opencto/opencto-landing && npm run build",
"cd opencto/opencto-dashboard && npm ci",
"cd opencto/opencto-dashboard && npm run lint",
"cd opencto/opencto-dashboard && npm run build"
]
},
{
"id": "founder-content-seo",
"name": "Founder Content SEO",
"description": "Generate SEO assets and validate output artifacts.",
"commandTemplates": [
"npm run content:plan -- --topic \"{{topic}}\"",
"npm run content:draft -- --topic \"{{topic}}\" --persona \"{{persona}}\"",
"npm run content:publish -- --topic \"{{topic}}\""
]
},
{
"id": "founder-sales-outreach",
"name": "Founder Sales Outreach",
"description": "Generate lead list and outbound sequence assets.",
"commandTemplates": [
"npm run sales:leads -- --segment \"{{segment}}\"",
"npm run sales:sequence -- --segment \"{{segment}}\" --offer \"{{offer}}\"",
"npm run sales:send -- --segment \"{{segment}}\""
]
},
{
"id": "founder-demo-pack",
"name": "Founder Demo Pack",
"description": "Assemble product + GTM demo artifacts for judges or customers.",
"commandTemplates": [
"npm run demo:product",
"npm run demo:marketing",
"npm run demo:ops",
"npm run demo:bundle"
]
},
{
"id": "sdk-release-check",
"name": "SDK Release Check",
"description": "Quality gates for sdk and cli packages before publish.",
"commandTemplates": [
"cd opencto/opencto-sdk-js && npm ci",
"cd opencto/opencto-sdk-js && npm run lint",
"cd opencto/opencto-sdk-js && npm run test",
"cd opencto/opencto-sdk-js && npm run build",
"cd opencto/opencto-cli && npm ci",
"cd opencto/opencto-cli && npm run lint",
"cd opencto/opencto-cli && npm run test",
"cd opencto/opencto-cli && npm run build"
]
}
]
}
Loading
Loading