Skip to content

Compress tool outputs, logs, files, and RAG chunks before they reach the LLM. 20% fewer tokens for coding agents, 60-95% fewer tokens for JSON, same answers. Library, proxy, MCP server.

Fix learn CLI worker expectation in CI

Tejas Chopra22e750c78f48
diff --git a/tests/test_cli_learn.py b/tests/test_cli_learn.py
index 846385145..c1a5e499f 100644
--- a/tests/test_cli_learn.py
+++ b/tests/test_cli_learn.py
@@ -1,5 +1,6 @@
from __future__ import annotations
+import os
from pathlib import Path
from types import SimpleNamespace
@@ -246,7 +247,8 @@ def test_learn_analyze_all_continues_when_one_project_write_fails(
assert str(blocked.project_path) in result.output
assert "[WROTE]" in result.output
assert str(ok.project_path / "AGENTS.md") in result.output
- assert plugin.scan_calls == [(blocked, 8), (ok, 8)]
+ expected_workers = min(os.cpu_count() or 4, 8)
+ assert plugin.scan_calls == [(blocked, expected_workers), (ok, expected_workers)]
def test_learn_handles_empty_sessions_and_no_pattern_outputs(