Support skills and project context in the zero-config virtual sandbox #57
Replies: 9 comments
-
|
from the managed-agent angle, this feels like an environment preparation problem, not a session problem.
maybe the primitive is a small prepare step for sandbox/context:
that would keep the default fast virtual sandbox useful while preserving isolation. it also avoids making users choose |
Beta Was this translation helpful? Give feedback.
-
|
I just discovered https://www.strukto.ai/mirage which feels like an even more powerful just-bash, which is what we use today for our built-in sandbox. I'm realizing that this space is going to be changing quickly. Maybe we just want to lean into this:
This way we're not tied to any one sandbox. You can provide just-bash, @cloudflare/shell, or mirage, all would be valid virtual sandboxes. Plus then that solves the "how do I pass files to the virtual sandbox?" problem, because you'd be in control of its initialization, instead of today, where that is hidden from you. |
Beta Was this translation helpful? Give feedback.
-
|
yeah this direction feels very managed-agents-aligned to me. the Anthropic framing is basically: brain / session / hands should be separate. so maybe the split is:
today Flue couples some of these because if default becomes “no sandbox”, i think that fits, but only if “no sandbox” means “no built-in filesystem/bash tools”, not “no project context.” rough shape: await init({
model,
context: projectContext(), // AGENTS.md + skills
sandbox: virtualSandbox(), // optional hands
});or maybe so +1 on explicit sandbox. i’d just keep |
Beta Was this translation helpful? Give feedback.
-
|
I would model this as a prepared context bundle rather than letting the virtual sandbox discover project context opportunistically during A possible flow:
That keeps zero-config behavior while preserving isolation. It also avoids accidentally mounting the whole project or user home just so the agent can discover a few context files. The main design question is policy: which files are allowed into the bundle, and can project code influence that selection? For safety, I would start with a small explicit allowlist and make additional context opt-in. |
Beta Was this translation helpful? Give feedback.
-
|
+1 to the explicit-sandbox direction. Grounded in code: the gap is real. Two small things worth pinning down before the API lands:
Happy to take a small PR once the shape is settled. Changes look contained to |
Beta Was this translation helpful? Give feedback.
-
|
Agree with the capability-declaration point. I would make that part testable rather than only API-shape guidance. A small contract could be enough:
Then the useful fixtures become straightforward: no filesystem but a valid read-only context bundle; missing skills directory; network disabled; context bundle hash mismatch; and a tool that asks for shell when the environment declares That would keep zero-config behavior convenient while making sandbox authority explicit and reviewable. |
Beta Was this translation helpful? Give feedback.
-
|
looked at this again after #109 / #111, and i think the clean first cut is even smaller than a full capability taxonomy. right now the hard coupling is:
so if the default becomes “no sandbox”, Flue accidentally loses project context too. imo those should split before we debate the full environment API. rough v1: interface ContextSource {
cwd: string;
readFile(path: string): Promise<string>;
exists(path: string): Promise<boolean>;
readdir(path: string): Promise<string[]>;
stat(path: string): Promise<FileStat>;
resolvePath(path: string): string;
}then:
one design detail that matters: named skills should probably record their resolved path/source in the registry. if the execution env can read that path, keep today’s “model reads the skill file” behavior. if context is read-only and no sandbox exists, either inline the so maybe the PR sequence is:
this feels like the smallest step toward explicit sandbox ownership without making Flue own every sandbox provider’s initialization story. |
Beta Was this translation helpful? Give feedback.
-
|
opened #114 as the small first cut here. kept it intentionally boring:
if that boundary feels right, the next layer can be actual project-context wiring instead of making every sandbox connector own AGENTS.md / skills loading. |
Beta Was this translation helpful? Give feedback.
-
|
Possibly related contribution from @stainlu — opened #114 which appears to be addressing this. Their summary: Introduces a read-only Implementation: stainlu/flue@context-source-boundary (diff) This comment was posted automatically when #114 was redirected. The implementation is preserved on the branch above so it can inform the work here. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
The default zero-config virtual sandbox should ideally support project context like skills and AGENTS.md without requiring users to switch to
sandbox: "local"or manually configure a custom virtual sandbox.Today this is difficult because the agent discovers skills and context during
init(), but the built-in virtual sandbox does not have an obvious setup phase where those files can be added before initialization. We should explore an API or runtime behavior that makes this work by default while preserving the isolation benefits of the virtual sandbox.Moved from issue #43: #43
Beta Was this translation helpful? Give feedback.
All reactions