79 Commits

Author SHA1 Message Date
cynarAI
0a3ce24797 fix(api): pass actor identity when purging memory after thread clear (#62)
threads/clear called memoryProviders.resolve with a bare spaceId string.
The resolver destructures { spaceId, userId }, so both were undefined and
purgeHistory was silently skipped after every clear.

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 10:57:40 +02:00
cynarAI
db39fe7752 fix(api): scope routine remove to acting user in shared Spaces (#61)
* fix(api): scope routine remove to acting user in shared Spaces

routines/remove only filtered by spaceId, so any member of a shared Space
could delete another member's routine by ID. Match update/testRun by also
requiring userId in the lookup.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>

* test: drop unused ownerActor in routine remove authz case

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 10:57:35 +02:00
cynarAI
492e0f0965 fix(messaging): deliver delegated tool-only replies before mirroring (#60)
deliverDelegatedReplies used allowSilence and marked teamChatMirroredAt
even when no Slack/Teams message was sent, leaving tool-only delegated
runs silently dropped with no retry path.

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 10:57:30 +02:00
ec597a5c68 fix(api): scope Team Computer export to exporting bot workspace
- Add teamBotWorkspaceDirectory import to router.ts
- Add exportOptions to scope team exports to one bot workspace
- Add authorization test: member export only sees their workspace files
- Add LocalAgentHomeStore and computerHomeKey imports to testkit
2026-09-22 07:15:22 +00:00
Cursor Agent
c8ea27c239 chore(api): drop unused db imports after follow-up extract
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:10:48 +00:00
Cursor Agent
f5265924ba fix(api): route group follow-ups to the waiting member bot
Group threads/followUp always steered to members[0], so a follow-up
while a later member had waiting_input went to the wrong bot or started
a fresh run on the first member instead of continuing the ask.

Resolve the target bot like group sends: prefer waiting ask/takeover on
any member, then the newest steerable active run, then @mentions, then
the default first member. Extract followUpGroupThreadMessage and add
regression tests.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:10:48 +00:00
Cursor Agent
44d1bc7277 fix(api): redact memory provider details in aiConsent/status for members
Non-owner shared-space members could read the space memory provider id
and internal endpoint origin via aiConsent/status, bypassing the owner-only
policy that draft PR #46 applies to memory/providerConfig.

Owners still see full provider disclosure; members get a generic Space
memory recipient when a provider is configured, without loading settings.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:10:42 +00:00
2f8368a9ce fix(api): gate memory providerConfig reads to Space owners
- Replace findSpaceMemoryConfig inline call with getMemoryProviderConfig(deps, actor)
- Add owner gate: space members get 403, owners get config
- Add authorization tests for providerConfig/connectProvider/setDefaultScope/disconnectProvider
- Add wiring test to ensure router.ts uses the owner-gated handler
2026-09-22 07:10:07 +00:00
Cursor Agent
101c908cdc style: format introPostedAt test expectation
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:06:21 +00:00
Cursor Agent
2ee72af28b fix(messaging): set introPostedAt only after intro delivery succeeds
Group intros were stamped as posted before the outbox drain ran. When
delivery enqueue failed or the intro row exhausted retries, the channel
stayed marked and no retry path existed — unlinked participants never saw
the onboarding message.

Stamp introPostedAt in the drain path after a successful provider send,
matching the messagingMirroredAt pattern from #42.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:06:21 +00:00
31a6438145 fix(api): block cross-member Team Computer takeover hijack in shared Spaces 2026-09-22 07:05:29 +00:00
928d9ad950 fix(api): redact memory provider details in aiConsent/status for members 2026-09-22 07:05:26 +00:00
Cursor Agent
ca292d2cc0 chore(api): drop unused db imports after follow-up extract
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:04:42 +00:00
Cursor Agent
57f3ee4958 fix(api): route group follow-ups to the waiting member bot
Group threads/followUp always steered to members[0], so a follow-up
while a later member had waiting_input went to the wrong bot or started
a fresh run on the first member instead of continuing the ask.

Resolve the target bot like group sends: prefer waiting ask/takeover on
any member, then the newest steerable active run, then @mentions, then
the default first member. Extract followUpGroupThreadMessage and add
regression tests.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:04:42 +00:00
Cursor Agent
33ce657201 fix: sort adapter imports for biome
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:04:29 +00:00
Cursor Agent
0b5cd4ed43 fix(api): scope Team Computer export to exporting bot workspace
Team mode shares one disk per Space. export/bot walked the entire
team home, so a member exporting their own bot received every other
member's workspace files too.

Scope exportHome with the exporting bot's bots/<id>/ prefix and add
regression coverage for the shared-Space case.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 07:04:29 +00:00
9c87398f53 fix(api): scope routines/remove to owner in shared Spaces 2026-09-22 06:21:53 +00:00
Cursor Agent
18934e03c9 fix(api): skip group membership sweep on partial participant rosters
Group inbound webhooks often report only the sender in participants,
not the full roster. Sweeping on any non-empty list incorrectly marked
approved members as left, silently dropping them from channel fan-out.

Gate the sweep on participantsAuthoritative so adapters opt in only when
the provider supplies a complete roster.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:56 +00:00
Cursor Agent
c8b06ec7a8 fix(api): gate memory/providerConfig read behind Space owner authz
Non-owner Space members could read provider settings (mode, baseUrl,
endpoint metadata) while connect/disconnect/setDefaultScope already
required owner role. Align the read path with write authz.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:54 +00:00
Cursor Agent
8ae36763a7 fix(api): scope Team Computer bot homes per member in shared Spaces
Team mode shares one disk per Space. RPC and executor paths under
bots/<otherBotId>/ were reachable with any member-owned entry bot,
leaking another member's workspace files while same-user cross-bot
access stays intentional.

Add path guards, filter bot listings, regression tests.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:49 +00:00
Cursor Agent
4defccae95 chore(api): sort imports for clear-thread error mapping
Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:47 +00:00
Cursor Agent
32af2398d6 fix(adapters): retry delegated bot returns when wake message is gone
When a delegated bot finishes but its wake message was deleted (e.g.
thread clear), returnBotMessageOutcome used to mark botOutcomeReturnedAt
and drop the coordinator reply silently. Retry instead, and block
clearThread while completed bot_message runs still owe a return.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:47 +00:00
Cursor Agent
016fd0c628 fix(adapters): gate memory provider runtime resolve to Space owners
Cloud/public memory providers are owner-managed infrastructure. The RPC
read path is owner-gated separately; this aligns executor, history
compaction, and thread-clear purge with the same boundary so non-owner
members cannot load credentials or reach external endpoints at runtime.

Deployment-owner local/private providers remain available to all Space
members when the deployment owner configured them.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-22 06:20:43 +00:00
a3eac211bd fix: clean up remaining pre-existing TypeScript errors
- dictation.ts: Uint8Array cast for getByteTimeDomainData
- user-help-vibe.test.ts + user-profile-harvest.test.ts: computerHost 'evo' → null
- executor-utils.ts: import AgentRunRequest from adapter-kit, MessageBlock from contracts
- pi-model-config.ts: import AgentToolExecutionResult from adapter-kit

Results: apps/web 0 TS errors (was 4), packages/adapters 15→6 errors
2026-09-22 04:37:18 +00:00
Cursor Agent
57c968dc8b fix(web): keep project create in shell, not onboarding
Projekte + shared the new-space post-create path and always sent users
to /onboarding. Route project variant to /app with the new space selected;
keep /onboarding for global New space when a first bot is still needed.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-21 23:41:58 +00:00
Cursor Agent
cc59fce7bd fix(web): Projekte + opens project create, not group form
Wire the Projekte sidebar + and empty-state action to NewSpaceDialog
with project labels instead of the group creation panel. Keep space
wording for the global create menu. Add de locale strings and an e2e
regression test.

Co-authored-by: cynarAI <cynarAI@users.noreply.github.com>
2026-09-21 23:30:57 +00:00
9aeb2c01f8 feat: emoji-first onboarding flow with accessory/pose customization, language step
- Rewrite Onboarding.tsx: 5-step flow (emoji → preferences → language → integrations → bot)
- Remove model selection from onboarding entirely
- Add shape selector (8 GrokShapes), color picker (12 colors), accessory (9 options), pose (8 poses)
- Add user preference form (name, timezone, hobbies, work style, communication style)
- Add language selection step with 9 locales persisting to localStorage
- Persist avatarValue ({color}::shape_{index}) on bot creation
- Persist user preferences to bot instructions
- Update onboarding-discovery: 3 items (profile, tools, crew), no model
- Update OnboardingDiscoveryShell: remove model-ready source label
- Export GROK_COLOR_LIST, GROK_SHAPES, GrokColorDef, SHIPPED_SHAPE_KEYS from ui-web
- Update onboarding-discovery.test.ts with proper mock types
2026-09-21 23:18:34 +00:00
a570e9e71b feat: complete onboarding redesign + major file splits
Onboarding: emoji-first flow with shape/color selection, user preferences,
language setup (9 locales), and bot creation with avatarValue persistence.

executor.ts: split 4928→4159 lines into 8 modules (completion, computer,
effects, model, utils, tools, attachments, types).

pi-runtime.ts: split 1726→561 lines into 2 modules (model-config, tool-utils).

E2E: new onboarding-emoji-first tests + updated completeOnboarding helper.
2026-09-21 22:52:04 +00:00
cynarAI
6c7eed7580 Initial clean evOo-local from f00577b
Fresh history cut from cynarAI/evoo antigravity-handoff/project-timeline
(Voice First + project timeline). Brand docs/titles as evOo; keep @rakazo/*
packages as tech debt. Excludes node_modules, caches, secrets, voice blobs.
2026-09-20 17:15:16 +02:00