AI Engineering Workspace
PartialChat, files, terminal and preview in one place. Chat sessions run on a durable Postgres-backed queue (chat only: no tools or shell). Live models need an API key; the terminal is unavailable.
Project files
read-only- ..
- _clean.mjs
- acceptance.mjs
- ai-adapters.mjs
- ai-enqueue.mjs
- central.mjs
- deploy-flow.mjs
- external-vps.mjs
- fake-opencode.mjs
- gates.mjs
- immersive.mjs
- nexus.mjs
- oidc-core.mjs
- oidc-flow.mjs
- opencode-engine.mjs
- owner-auth.mjs
- proxy.mjs
- retake-landing.mjs
- rls.mjs
- run.mjs
- shot-central.mjs
- tenant-isolation.mjs
- trusted-https.mjs
- web-shots.mjs
- with-derived.mjs
app/qa/fake-opencode.mjs
1#!/usr/bin/env node2// Test double for the OpenCode CLI: emits the same JSON event shapes as `opencode run --format json`.3import fs from "node:fs";4const a = process.argv.slice(2); const prompt = a[a.indexOf("--") + 1] ?? ""; const sleep = ms => new Promise(r => setTimeout(r, ms));5const ev = (type, part) => console.log(JSON.stringify({ type, timestamp: Date.now(), sessionID: "ses_fake1", part: { sessionID: "ses_fake1", ...part } }));6ev("step_start", { type: "step-start" });7if (/\[write\]/.test(prompt)) { fs.writeFileSync("agent.txt", "written by fake agent\n"); ev("tool_use", { type: "tool", tool: "write", state: { status: "completed" } }); }8if (/\[shell\]/.test(prompt)) ev("tool_use", { type: "tool", tool: "shell", state: { status: "error", error: "Permission denied: shell" } });9if (/\[slow\]/.test(prompt)) { ev("text", { type: "text", text: "working " }); await sleep(8000); }10if (/\[fail\]/.test(prompt)) { console.error("boom"); process.exit(3); }11ev("text", { type: "text", text: "done " + (a.includes("--session") ? "(continued)" : "(new)") });12ev("step_finish", { type: "step-finish", reason: "stop", cost: 0, tokens: { input: 10, output: 4, reasoning: 1, cache: { read: 0, write: 0 } } });13
Conversation
PartialSign in to start AI sessions.
Task checklist
- Application shell deployed
- Persistent projects
- Agent runtime
- Sandboxed terminal
Execution activity
No agent sessions. Git HEAD 1c27633 on master.
Approval requests
None pending.