mirror of
https://github.com/agentscope-ai/ReMe.git
synced 2026-11-08 08:07:27 +00:00
Enhance the Docker benchmark sandbox so one container can process multiple cases sequentially and export only analysis-relevant artifacts: - Add reset_case() to discard the active case while keeping the installed candidate, venv, and worker for the next case. - Add export(profile="analysis") (default) and export_full() to choose between a selective analysis archive and the complete disposable case tree; analysis export omits rebuildable indexes, caches, temp files, and source resources. - Introduce runtime-layout.json written by the worker with validated, non-secret, case-relative paths so the host can build safe tar excludes. - Serialize job, export, and reset operations with a per-case lock. - Pin a sandbox-runtime extra in pyproject.toml that omits cookbook-only tushare, dingtalk-stream, pypdf, and polars, and install it in Dockerfile.base. - Set TMPDIR to a case-local directory so subprocess temp files stay inside the disposable case root. - Add unit tests for the new behaviors and a real-Docker LongMemEval integration smoke test.
28 lines
1.1 KiB
Text
28 lines
1.1 KiB
Text
# Build from the repository root:
|
|
# docker build -f sandbox/Dockerfile.base \
|
|
# -t reme-sandbox-base:agentscope-2.0.4-post1 .
|
|
FROM python:3.11-slim
|
|
|
|
ENV PIP_DISABLE_PIP_VERSION_CHECK=1 \
|
|
PYTHONDONTWRITEBYTECODE=1 \
|
|
PYTHONUNBUFFERED=1
|
|
|
|
RUN apt-get update \
|
|
&& apt-get install -y --no-install-recommends build-essential git tar \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Install the benchmark sandbox dependency contract, then remove the dummy
|
|
# ReMe package. The sandbox-runtime extra deliberately omits cookbook-only
|
|
# tushare, dingtalk-stream, pypdf, and polars. Source candidates are installed
|
|
# later with --no-deps, so no fixed ReMe implementation can leak into an
|
|
# experiment.
|
|
WORKDIR /tmp/reme-dependencies
|
|
COPY pyproject.toml README.md ./
|
|
RUN mkdir reme \
|
|
&& printf '__version__ = "0.0.0"\n' > reme/__init__.py \
|
|
&& python -m pip install '.[sandbox-runtime]' \
|
|
&& python -m pip uninstall -y reme-ai \
|
|
&& test "$(python -c 'import agentscope; print(agentscope.__version__)')" = "2.0.4.post1" \
|
|
&& rm -rf /tmp/reme-dependencies
|
|
|
|
WORKDIR /workspace
|