verifiers 0.3.2.dev40__py3-none-any.whl → 0.3.2.dev42__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -20,10 +20,48 @@ logger = logging.getLogger(__name__)
20
20
  # OpenClaw and its bundled Node runtime exceed the small /tmp tmpfs in some VMs.
21
21
  OPENCLAW_DIR = "/var/tmp/vf-openclaw-{version}"
22
22
  OPENCLAW_BIN = f"{OPENCLAW_DIR}/bin/openclaw"
23
- INSTALL = r"""
23
+ SETUP = r"""
24
24
  set -e
25
- command -v curl >/dev/null || (apt-get update -qq && apt-get install -y -qq curl ca-certificates >/dev/null)
26
- curl -fsSL --proto '=https' --tlsv1.2 https://openclaw.ai/install-cli.sh | bash -s -- --prefix {dir} --version {version} --no-onboard
25
+ if [ ! -x "$VF_OPENCLAW_BIN" ]; then
26
+ command -v curl >/dev/null || (apt-get update -qq && apt-get install -y -qq curl ca-certificates >/dev/null)
27
+ curl -fsSL --proto '=https' --tlsv1.2 https://openclaw.ai/install-cli.sh \
28
+ | bash -s -- --prefix "$VF_OPENCLAW_DIR" --version "$VF_OPENCLAW_VERSION" --no-onboard
29
+ fi
30
+ set -- $(find "$VF_OPENCLAW_DIR/tools" -type f -path '*/openclaw/dist/session-accessor.sqlite-transcript-store-*.js')
31
+ [ "$#" -eq 1 ] || { echo "could not locate OpenClaw's transcript sanitizer for replay patch" >&2; exit 1; }
32
+ "$VF_OPENCLAW_DIR/tools/node/bin/node" - "$1" <<'NODE'
33
+ const fs = require("node:fs");
34
+ const file = process.argv[2];
35
+ const stat = fs.statSync(file);
36
+ if (stat.size > 1_000_000) {
37
+ throw new Error("OpenClaw's transcript sanitizer exceeds the replay patch size limit");
38
+ }
39
+ const source = fs.readFileSync(file, "utf8");
40
+ const patches = [
41
+ [
42
+ "const OPAQUE_REPLAY_TOKEN_RE = /^[A-Za-z0-9+/_-]+={0,2}$/;",
43
+ "const OPAQUE_REPLAY_TOKEN_RE = /^[A-Za-z0-9+/_-]+={0,2}(?:[.][A-Za-z0-9+/_-]+={0,2})*$/;",
44
+ ],
45
+ ["\t\tsummary: [],", "\t\tsummary: parsed.summary ?? [],"],
46
+ ];
47
+ let patched = source;
48
+ for (const [before, after] of patches) {
49
+ patched = patched.replaceAll(before, after);
50
+ }
51
+ if (!patches.every(([, after]) => patched.includes(after))) {
52
+ throw new Error("OpenClaw's transcript sanitizer does not match the replay patch");
53
+ }
54
+ if (patched !== source) {
55
+ const temporary = `${file}.${process.pid}.tmp`;
56
+ try {
57
+ // Publish complete bytes at once so live and concurrent setups never see a partial bundle.
58
+ fs.writeFileSync(temporary, patched, { mode: stat.mode });
59
+ fs.renameSync(temporary, file);
60
+ } finally {
61
+ fs.rmSync(temporary, { force: true });
62
+ }
63
+ }
64
+ NODE
27
65
  """
28
66
 
29
67
  OPENCLAW_COMMAND = [
@@ -82,7 +120,7 @@ wait "$acp_pid"
82
120
 
83
121
 
84
122
  class OpenClawHarnessConfig(HarnessConfig):
85
- version: str = Field(default="2026.7.1-2", pattern=r"^[A-Za-z0-9._+-]+$")
123
+ version: str = Field(default="2026.8.1", pattern=r"^[A-Za-z0-9._+-]+$")
86
124
  """OpenClaw release to install, pinned for reproducibility."""
87
125
  use_bundled_skill: bool = True
88
126
  """Enable OpenClaw's bundled skill catalog in addition to uploaded harness skills."""
@@ -117,20 +155,27 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
117
155
  await runtime.write(ready_path, b"")
118
156
  directory = OPENCLAW_DIR.format(version=self.config.version)
119
157
  binary = OPENCLAW_BIN.format(version=self.config.version)
120
- script = INSTALL.replace("{version}", self.config.version).replace(
121
- "{dir}", directory
122
- )
123
- ensure = shlex.quote(f"[ -x {binary} ] || ({script})")
158
+ # Borrowed runtimes can share this cache, so one filesystem lock owns both
159
+ # installation and the transcript adjustment.
124
160
  guarded = (
125
- f"mkdir -p {directory} && "
126
- f'"$(command -v flock || command -v lockf)" {directory}/install.lock '
127
- f"bash -o pipefail -c {ensure}"
161
+ f"mkdir -p {shlex.quote(directory)} && "
162
+ f'"$(command -v flock || command -v lockf)" '
163
+ f"{shlex.quote(f'{directory}/install.lock')} "
164
+ f"bash -o pipefail -c {shlex.quote(SETUP)}"
128
165
  )
129
166
  logger.info("openclaw: ensuring OpenClaw %s is installed", self.config.version)
130
- result = await runtime.run(["sh", "-c", guarded], self.config.resolved_env)
167
+ result = await runtime.run(
168
+ ["sh", "-c", guarded],
169
+ {
170
+ **self.config.resolved_env,
171
+ "VF_OPENCLAW_BIN": binary,
172
+ "VF_OPENCLAW_DIR": directory,
173
+ "VF_OPENCLAW_VERSION": self.config.version,
174
+ },
175
+ )
131
176
  if result.exit_code != 0:
132
177
  detail = (result.stderr or result.stdout).strip()[-500:]
133
- raise RuntimeError(f"OpenClaw install failed: {detail}")
178
+ raise RuntimeError(f"OpenClaw setup failed: {detail}")
134
179
  await super().setup(runtime)
135
180
 
136
181
  async def prepare_acp(
@@ -149,8 +194,6 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
149
194
  config_path = f"{state_dir}/openclaw.json"
150
195
  skills_dir = f"{state_dir}/skills"
151
196
  config = {
152
- # Provider state must remain byte-exact within this isolated rollout.
153
- "logging": {"redactSensitive": "off"},
154
197
  "gateway": {
155
198
  "mode": "local",
156
199
  "bind": "loopback",
@@ -180,6 +223,7 @@ class OpenClawHarness(ACPHarness[OpenClawHarnessConfig]):
180
223
  provider: {
181
224
  "baseUrl": endpoint,
182
225
  "apiKey": "${OPENCLAW_INTERCEPT_KEY}",
226
+ "request": {"allowPrivateNetwork": True},
183
227
  }
184
228
  },
185
229
  },
@@ -68,8 +68,8 @@ class RLMHarnessConfig(HarnessConfig):
68
68
  unset defers to nano-rlm's default (on, automatic thresholds, bounded by its
69
69
  default 1M tree-token budget)."""
70
70
  max_concurrent_subagents: PositiveInt | None = None
71
- """Sub-agents running at once per session tree; `None` = nano-rlm's default (4).
72
- nano-rlm requires it to be at least `max_depth`."""
71
+ """Sub-agents running at once per session tree; `None` = nano-rlm's default (4),
72
+ raised to an explicit `max_depth` when needed to keep the policy valid."""
73
73
  max_total_turns: PositiveInt | None = None
74
74
  """Tree-total turn budget (one turn = one work-loop model call, any engine); every
75
75
  engine stops before its next call once spent. `None` = uncapped."""
@@ -152,9 +152,12 @@ class RLMHarness(ACPHarness[RLMHarnessConfig]):
152
152
  system_prompt: str | None,
153
153
  ) -> JsonObject:
154
154
  compaction = self.config.compaction
155
+ max_concurrent_subagents = self.config.max_concurrent_subagents
156
+ if max_concurrent_subagents is None and self.config.max_depth is not None:
157
+ max_concurrent_subagents = max(4, self.config.max_depth)
155
158
  policy_knobs: dict[str, Any] = {
156
159
  "max_depth": self.config.max_depth,
157
- "max_concurrent_subagents": self.config.max_concurrent_subagents,
160
+ "max_concurrent_subagents": max_concurrent_subagents,
158
161
  "max_total_turns": self.config.max_total_turns,
159
162
  "max_total_tokens": self.config.max_total_tokens,
160
163
  "max_tool_output_bytes": self.config.max_tool_output_bytes,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: verifiers
3
- Version: 0.3.2.dev40
3
+ Version: 0.3.2.dev42
4
4
  Summary: Verifiers: Environments for LLM Reinforcement Learning
5
5
  Project-URL: Homepage, https://github.com/primeintellect-ai/verifiers
6
6
  Project-URL: Documentation, https://github.com/primeintellect-ai/verifiers
@@ -101,7 +101,7 @@ verifiers/v1/harnesses/mini_swe_agent/program.py,sha256=Beej-JLIgSqnqIqB746oKU6k
101
101
  verifiers/v1/harnesses/null/__init__.py,sha256=XDeKOPeoXUQi9US9_Z3_yH9YaZ4EiOMKJmUtNNdtD7s,127
102
102
  verifiers/v1/harnesses/null/harness.py,sha256=RWj2I7auxYe4dJ885DhqH1MN15iUS-TKT7-gEWNrgmM,1412
103
103
  verifiers/v1/harnesses/openclaw/__init__.py,sha256=kNyfPB1sGwEf4K3mTfKN0VEyxun3SGvNpvArVKvH-x8,160
104
- verifiers/v1/harnesses/openclaw/harness.py,sha256=LcdfnP_wYvWUQWIt6d4sE0TnXaxt5Ne5r_f7R0lKkAc,9535
104
+ verifiers/v1/harnesses/openclaw/harness.py,sha256=EREEYr3J0Qn8mK_YShnCSHctMtsiIN07rj00kq1Lxoc,11229
105
105
  verifiers/v1/harnesses/pi/__init__.py,sha256=1mSnzOf-RdEchdeg6IHtcdobG5KIpAhuTdUIgsCIn74,117
106
106
  verifiers/v1/harnesses/pi/harness.py,sha256=M0BRsfJxnBNP-KCrp0vT5gHlaJEDnyti5x_3V5Py40M,7024
107
107
  verifiers/v1/harnesses/pool/__init__.py,sha256=HTYsNiWGdiNEsSHj4xhPmshJSNb7SHjQ7d4yZQ4p3HM,127
@@ -109,7 +109,7 @@ verifiers/v1/harnesses/pool/harness.py,sha256=HKAogPbyLK5QpvPQ1teHOh_IyRQX-or2JF
109
109
  verifiers/v1/harnesses/prime_agent/__init__.py,sha256=xfPC4RrlnyYWaf38tPAOZq4YL6M55lMpj5BoRLmaK8I,171
110
110
  verifiers/v1/harnesses/prime_agent/harness.py,sha256=_FJtiYvWOsBpjEBKuJsnmuldYNwJxKK8ONa5e-c_mYM,11205
111
111
  verifiers/v1/harnesses/rlm/__init__.py,sha256=hwx51xTdEWzzYgMj-p4ETNcptoub3IPMDbEdJ4uB8Ns,122
112
- verifiers/v1/harnesses/rlm/harness.py,sha256=1a88tUM8l4BRf-In-dPyhtW9ilyH2GJdbh1ezL2BRcQ,10297
112
+ verifiers/v1/harnesses/rlm/harness.py,sha256=iVdI4dzbuXm5v6Pq28ctLjOmcXWtC2Vmp2aKOniq0ss,10532
113
113
  verifiers/v1/harnesses/terminus_2/__init__.py,sha256=l1pwfg1HyVDEqT9efdnFWcXqaZwtKwe7TrplkyxZSA0,166
114
114
  verifiers/v1/harnesses/terminus_2/harness.py,sha256=kXKhi-aqqsoXGnvet0Tq_v7LYYpRYEzARyQL2MTEGWs,3101
115
115
  verifiers/v1/harnesses/terminus_2/program.py,sha256=X8MZdyItU3gbXGXnGOlJ9LWcUTnqIDaxlhkZvoRiqKY,2703
@@ -185,8 +185,8 @@ verifiers/v1/utils/prime.py,sha256=UTYRjp9cbjNb6CVmBHda-1wWZAIIfxNOmTyNuT7_wL4,9
185
185
  verifiers/v1/utils/retries.py,sha256=Y2ZgrAjn-qNkRKZP_RVNL_7EK0iaRcZeCa404lpGYi4,5417
186
186
  verifiers/v1/utils/score.py,sha256=493yJVMw8teCu9JxapxMFPFzI0hNUqdo0Y2nGW4kckk,6200
187
187
  verifiers/v1/utils/version.py,sha256=-obEo_-l9-D8FLef4hYxncOe-uJpxrM1g2Hig_37Sgs,1607
188
- verifiers-0.3.2.dev40.dist-info/METADATA,sha256=e5bkm_Lm2AKE8KvhdjM6WmekaMIDNsqwuHT0ivu7QF0,4065
189
- verifiers-0.3.2.dev40.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
190
- verifiers-0.3.2.dev40.dist-info/entry_points.txt,sha256=uqQje0TMsr7k6nXlWxlPs13Si0evb3pVCEDF6c-YL80,241
191
- verifiers-0.3.2.dev40.dist-info/licenses/LICENSE,sha256=v0RrUsdV3IDoZhrRce297IXS3xMHNJ-_LdLpFAUWb9k,1072
192
- verifiers-0.3.2.dev40.dist-info/RECORD,,
188
+ verifiers-0.3.2.dev42.dist-info/METADATA,sha256=jUn_EzfMNYKrakZ9wtcpZBjuM5u1gagwHsU0tS_8oow,4065
189
+ verifiers-0.3.2.dev42.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
190
+ verifiers-0.3.2.dev42.dist-info/entry_points.txt,sha256=uqQje0TMsr7k6nXlWxlPs13Si0evb3pVCEDF6c-YL80,241
191
+ verifiers-0.3.2.dev42.dist-info/licenses/LICENSE,sha256=v0RrUsdV3IDoZhrRce297IXS3xMHNJ-_LdLpFAUWb9k,1072
192
+ verifiers-0.3.2.dev42.dist-info/RECORD,,