Skip to content

Commit 7640e9f

Browse files
committed
update the code and script.
1 parent 02ad3aa commit 7640e9f

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,9 +186,11 @@ cp .env.template .env
186186
vim .env
187187
```
188188

189-
**Step 3:** Prepare E2B Sandbox:
189+
**Step 3:** Prepare E2B Sandbox (Optional)
190190

191191
> [!TIP]
192+
> We provide a public E2B sandbox template. Follow this step if you want to reproduce.
193+
>
192194
> For the E2B sandbox service, we recommend setting up a Linux Docker image with a comprehensive set of apt and Python packages pre-installed. Without these pre-installed packages, the agent will need to spend extra steps and context installing them, resulting in reduced token efficiency.
193195
>
194196
> you need to have `npm` install and `docker` running locally.

apps/run-agent/scripts/claude-sonnet-3.7/run_evaluate_multiple_runs_gaia-validation.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ for i in $(seq 1 $NUM_RUNS); do
3535
benchmark.execution.max_concurrent=5 \
3636
benchmark.execution.pass_at_k=1 \
3737
agent=$AGENT_SET \
38-
output_dir=${RESULTS_DIR}/$RUN_ID \
38+
output_dir="$RESULTS_DIR/$RUN_ID" \
3939
> "$RESULTS_DIR/${RUN_ID}_output.log" 2>&1
4040

4141
if [ $? -eq 0 ]; then

libs/miroflow-tool/src/miroflow/tool/mcp_servers/python_server.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
import asyncio
12
import os
23

34
from e2b_code_interpreter import Sandbox
45
from fastmcp import FastMCP
5-
import asyncio
66

77
# Initialize FastMCP server
88
mcp = FastMCP("e2b-python-interpreter")
@@ -11,6 +11,10 @@
1111
E2B_API_KEY = os.environ.get("E2B_API_KEY")
1212
LOGS_DIR = os.environ.get("LOGS_DIR") # Directory where benchmark logs are stored
1313

14+
# DEFAULT TEMPLATE ID
15+
# see README.md on how to build this
16+
DEFAULT_TEMPLATE_ID = "1av7fdjfvcparqo8efq6"
17+
1418
# DEFAULT CONFS
1519
DEFAULT_TIMEOUT = 1200 # seconds
1620

@@ -138,7 +142,9 @@ async def create_sandbox() -> str:
138142
sandbox = None
139143
try:
140144
sandbox = Sandbox(
141-
template="all_pip_apt_pkg", timeout=DEFAULT_TIMEOUT, api_key=E2B_API_KEY
145+
template=DEFAULT_TEMPLATE_ID,
146+
timeout=DEFAULT_TIMEOUT,
147+
api_key=E2B_API_KEY,
142148
)
143149
info = sandbox.get_info()
144150

0 commit comments

Comments
 (0)