Commit Graph
997 Commits
Author SHA1 Message Date
ZacharyZhang-NY 44f31b49fb Wake agents on @mention in chat messages
Agents were deaf to @mentions — only /agent slash commands triggered a
task_run. Now ChatService.sendMessage auto-wakes every mentioned agent
(skipping self-mentions and /agent which already handles it) by creating
a queued task_run through ChatAgentWakeService.wakeFromMention.
2026-06-07 17:20:58 -04:00
ZacharyZhang-NY abe578b1a0 Harden provider security and build dependencies 2026-06-07 14:04:32 -04:00
ZacharyZhang-NY 67d2cf5649 Split oversized renderer components 2026-06-07 13:52:42 -04:00
ZacharyZhang-NY 91d9b76281 Enable thread file attachments 2026-06-07 13:45:45 -04:00
ZacharyZhang-NY d5a7665893 Create project collaboration surface 2026-06-07 13:41:53 -04:00
ZacharyZhang-NY 3f34d1cf65 Create runnable agents from hire form 2026-06-07 13:37:36 -04:00
ZacharyZhang-NY 8eec454927 Queue agent runs from chat mentions 2026-06-07 13:34:27 -04:00
ZacharyZhang-NY ab546f822d Enable autonomous file handoffs 2026-06-07 13:25:28 -04:00
ZacharyZhang-NY 87dfa9345b Add zoom controls and Ctrl/Cmd-wheel zoom to the org chart 2026-05-30 16:27:22 -04:00
ZacharyZhang-NY afd96fe42c Rebuild the org chart with a real tidy-tree layout and centered connectors 2026-05-30 15:52:49 -04:00
ZacharyZhang-NY 6f23ac2877 Route agent messages to department channels and thread hand-offs between agents 2026-05-30 10:50:36 -04:00
ZacharyZhang-NY dd0bb5dc58 Render the team org chart as a hierarchical reporting tree 2026-05-30 10:42:37 -04:00
ZacharyZhang-NY 7dfe652eda Always show the model id field for custom providers 2026-05-30 02:12:58 -04:00
ZacharyZhang-NY 35e1097041 Let custom OpenAI/Anthropic-compatible providers take a hand-entered model id 2026-05-30 02:06:04 -04:00
ZacharyZhang-NY 1b0d766c0c Add GPT-5.5 to the curated lists and show curated providers as a dropdown 2026-05-30 01:42:07 -04:00
ZacharyZhang-NY 2dbab2c1fe Use a free-text model id for providers without an enumerable model list 2026-05-30 01:27:38 -04:00
ZacharyZhang-NY d4ace283d1 Gate the model picker behind credentials: fetch on Get models or after OAuth login 2026-05-30 01:05:14 -04:00
ZacharyZhang-NY ddd8663ecc Add live model refresh to the settings provider model picker 2026-05-30 00:53:50 -04:00
ZacharyZhang-NY cc876e6e16 Fetch live provider model lists instead of the hardcoded catalog 2026-05-30 00:51:42 -04:00
ZacharyZhang-NY 5737f76d6b Stop clipping the top provider card and drop the inline-form accent bar 2026-05-30 00:30:17 -04:00
ZacharyZhang-NY 5388165016 Show the provider credential form inline under the selected provider 2026-05-30 00:27:00 -04:00
ZacharyZhang-NY b9fa049494 Redesign the organization delete confirmation card 2026-05-30 00:13:25 -04:00
ZacharyZhang-NY c6e29d7fbe Make organization deletion cascade through credentials and immutable audit logs 2026-05-30 00:13:24 -04:00
ZacharyZhang-NY e14a4bfce8 Let agents post coordination messages so company channels are populated 2026-05-29 23:35:33 -04:00
ZacharyZhang-NY 54ad9d1909 Register agent deliverables as file objects so they appear on the Files page 2026-05-29 23:31:53 -04:00
ZacharyZhang-NY e7fa60d6b6 Auto-approve agent work in AI CEO mode instead of gating on the operator 2026-05-29 23:27:37 -04:00
ZacharyZhang-NY 9996b89f72 Show custom OpenAI/Anthropic-compatible providers in onboarding and settings 2026-05-29 22:56:01 -04:00
ZacharyZhang-NY 4d2425dde0 Run the agent loop on Azure, Bedrock and Vertex too
Every catalog provider can now drive agent execution:
- Azure OpenAI -> Chat Completions at the deployment URL with api-key
- AWS Bedrock -> Converse API signed natively with SigV4 (node:crypto)
- Vertex AI -> Gemini generateContent with a service-account JWT (RS256)
  exchanged for a cached access token

The credential resolver maps each cloud profile to the turn's needs; the router
covers all 16 providers. Pure encoders, the SigV4 signer and the GCP auth are
unit-tested; no AWS/GCP SDK dependency.
2026-05-29 22:43:42 -04:00
ZacharyZhang-NY 6c68836455 Add custom OpenAI- and Anthropic-compatible providers
New 'Custom OpenAI-compatible' and 'Custom Anthropic-compatible' providers let
an agent run against any compatible endpoint by base URL + key: the turn posts
Chat Completions (/chat/completions) or Anthropic Messages (/v1/messages) at the
configured base URL. Backfilled into existing orgs by migration 037.
2026-05-29 22:36:56 -04:00
ZacharyZhang-NY 937fdfa23f Run the agent loop on every provider, not just API keys
The loop was gated to API-key providers, so a GPT-account (Codex) CEO failed
with 'requires an API-key provider'. Port Pi's actual request handlers natively
so every agent-capable provider runs:
- chat-completions turn for xAI, Groq, Mistral, Cerebras, OpenRouter
- Codex SSE Responses for GPT account
- Anthropic-OAuth (Claude Code system + beta headers) for Claude Pro/Max
- Copilot proxy (baseUrl from the token) for GitHub Copilot
- Gemini Code Assist for Google Antigravity

A credential resolver refreshes expired OAuth access tokens at request time and
persists the rotation; the runner routes by provider key and passes the resolved
credential. The heartbeat now retries failed tasks (bounded to 3 attempts) so a
run that failed on the old gate recovers automatically. Cloud providers
(Azure/Bedrock/Vertex) still report a clear unsupported message.
2026-05-29 22:22:24 -04:00
ZacharyZhang-NY 61f2162236 Wake CEO-hired agents via heartbeat so delegated tasks run autonomously
The queue worker now also enqueues one run per actionable assigned task of a
heartbeat-enabled agent with an enabled provider and no run yet, so after the
CEO hires and delegates, its reports start their tasks on their own. Each task
is enqueued at most once. The team-building prompt is now scoped to managers
(no manager) with an empty team, so reports execute their task instead.
2026-05-29 21:12:09 -04:00
ZacharyZhang-NY 0575712e02 Run the CEO agent autonomously with a real tool-use loop
The new app reached a real LLM but never ran an agent: the kickoff task_run
sat queued forever and runTask was a single text completion with no tools.

This adds the missing runtime:
- provider-tool-turn: OpenAI Responses + Anthropic Messages tool-use turns
- agent-tools + deliverable-writer: hire_agent, create_task,
  update_task_status, write_deliverable (workspace-scoped, traversal-safe)
- agent-run-loop: real tool-use loop, capped iterations
- task-queue-worker: claims queued runs in a transaction and executes them

task-execution now drives the loop; a background worker auto-runs the
bootstrap CEO run so it hires its team, delegates tasks, and writes the first
deliverable into the bound workspace. Autonomy is gated by AGENTCOMPANY_NEW_AUTORUN
(tests run with it off to stay hermetic).
2026-05-29 21:08:04 -04:00
ZacharyZhang-NY 1c7b81830e Declutter the task card and show all hired agents in the org chart 2026-05-29 20:42:49 -04:00
ZacharyZhang-NY 9ce1281054 Add Claude Pro/Max, Mistral, Cerebras and OpenRouter connectors
Closes the Anthropic OAuth gap with a native Claude Pro/Max device sign-in
(reusing the OAuth engine) and adds three OpenAI-compatible API-key
providers. Model lists are sourced from the provider registry. A backfill
migration seeds the new providers into existing organizations idempotently.
2026-05-29 20:19:01 -04:00
ZacharyZhang-NY 49a9f16221 Replace token-paste with native device-code/PKCE provider sign-in
Implement the official OAuth login flows natively (ported from pi-ai's
reference): GitHub Copilot device-code, GPT account (ChatGPT Codex) and
Google Antigravity authorization-code + PKCE via a loopback callback server.
Obtained credentials are stored as JSON through the existing secret vault.
Onboarding and Settings now run the real sign-in instead of pasting an
access token.
2026-05-29 20:08:55 -04:00
ZacharyZhang-NY d5bf6c6b5f Scroll only the onboarding provider panel, not the hero 2026-05-29 19:15:30 -04:00
ZacharyZhang-NY 6f1ef18b25 Give the onboarding window minimize/maximize/close controls 2026-05-29 19:09:33 -04:00
ZacharyZhang-NY 350333b284 Allow deleting the active and last organization 2026-05-29 19:04:18 -04:00
ZacharyZhang-NY bb4d0979d3 Provide the open-file handler to chat panels 2026-05-28 23:15:29 -04:00
ZacharyZhang-NY c3c00d5d2e Edit agent role, seniority, and model from the roster 2026-05-28 23:11:22 -04:00
ZacharyZhang-NY 452fe07f4e Add a maximize control and clear the macOS title bar 2026-05-28 23:05:31 -04:00
ZacharyZhang-NY 6f182d1347 Open chat attachments and use a proper edit icon 2026-05-28 23:03:02 -04:00
ZacharyZhang-NY 207e108ae5 Remove the inert social post menu and fix author avatars 2026-05-28 22:59:11 -04:00
ZacharyZhang-NY 987892913d Move chat records into their own domain module 2026-05-28 22:56:40 -04:00
ZacharyZhang-NY 6282ad9792 Extract provider response execution into its own runner 2026-05-28 22:52:49 -04:00
ZacharyZhang-NY bfee7b22ef Split component styles into their own stylesheet 2026-05-28 22:47:32 -04:00
ZacharyZhang-NY b54e73de37 Drop the silent org-initial fallback 2026-05-28 22:44:32 -04:00
ZacharyZhang-NY 1cda873cb5 Render audit events as readable labels instead of raw codes 2026-05-28 22:43:33 -04:00
ZacharyZhang-NY da14be3443 Add approval detail review and fix the declined-row icon 2026-05-28 22:41:09 -04:00
ZacharyZhang-NY a9300682ee Make the Files scan-status filter functional 2026-05-28 22:37:58 -04:00