How to use with Vercel AI SDK and sandbox?
how can i use this with the vercel ai sdk and within a vercel sandbox?
use case: i'm building a "chat with a github repo" product in which posts/threads can be done to a different git ref, but will use the same sandbox (we'll clone the repo at that ref and place it in a specific worktree). then i want the agent's edits to live in a specific agentfs database. the database should be persisted to the sandbox itself (that's done automatically by vercel sandbox, or will be done soon). help me build this.
nice! why do we need just-bash with this setup? vs creating our own bash tool?
i'm confused: so the overaly aspect is not an agentfs feature? like if i run agentfs run --session <> -- rm -rf: what will happen? and i mean without just-bash.
nice. yeah aligned that just cli is the best! cool, that's clear. one other thing i'm confused about: can i run many concurrent "sessions" at the same time? which target the same worktree? will they conflict?
brilliant! really noice. ok, outline a simple plan for implementing this myself. assume the whole setup is there (except for the Bash tool (i don't wanna use just-bash btw) and the agentfs setup). in fact, see what's there https://forums.basehub.com/basehub-ai/forums/1
what about Linux OverlayFS? can i just use that if i have the sandbox to myself?
REPLY IN THREAD
the permission is the most compelling thing IMO. agentfs run ensures all mutations go to the db, even if the agent was prompt injected and CDs into another dir
REPLY IN THREAD
if i do agentfs run -- <complex command to go to root and rm -rf>, what protects root from not being deleted?
REPLY IN THREAD
END OF POST