Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,5 @@ jobs:
- name: Install JavaScript dependencies
run: pnpm install --frozen-lockfile

- name: Install official Python optimizers
run: |
python -m venv .venv-official
.venv-official/bin/python -m pip install --upgrade pip
RPC_VERSION=$(node -e "const v=require('./package.json').dependencies['@tangle-network/agent-eval']; if (!/^\\d+\\.\\d+\\.\\d+$/.test(v)) throw new Error('agent-eval dependency must be exact'); console.log(v)")
.venv-official/bin/python -m pip install \
"agent-eval-rpc==$RPC_VERSION" \
"gepa[full] @ git+https://github.com/gepa-ai/gepa.git@f919db0a622e2e9f9204779b81fe00cc1b2d808f" \
"skillopt @ git+https://github.com/microsoft/SkillOpt.git@61735e3922efc2b90c6d6cab561e62e98452ca90"

- name: Run packed package through official GEPA and SkillOpt
run: pnpm verify:official-optimizers
env:
AGENT_EVAL_TEST_PYTHON: ${{ github.workspace }}/.venv-official/bin/python
12 changes: 0 additions & 12 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,20 +42,8 @@ jobs:
- name: Verify packed package lifecycle
run: pnpm run verify:package

- name: Install official Python optimizers
run: |
python -m venv .venv-official
.venv-official/bin/python -m pip install --upgrade pip
RPC_VERSION=$(node -e "const v=require('./package.json').dependencies['@tangle-network/agent-eval']; if (!/^\\d+\\.\\d+\\.\\d+$/.test(v)) throw new Error('agent-eval dependency must be exact'); console.log(v)")
.venv-official/bin/python -m pip install \
"agent-eval-rpc==$RPC_VERSION" \
"gepa[full] @ git+https://github.com/gepa-ai/gepa.git@f919db0a622e2e9f9204779b81fe00cc1b2d808f" \
"skillopt @ git+https://github.com/microsoft/SkillOpt.git@61735e3922efc2b90c6d6cab561e62e98452ca90"

- name: Run packed package through official GEPA and SkillOpt
run: pnpm run verify:official-optimizers
env:
AGENT_EVAL_TEST_PYTHON: ${{ github.workspace }}/.venv-official/bin/python

- name: Verify tag/version lock
run: |
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

### Changed

- Updated `@tangle-network/agent-eval` to `0.126.3` and `@tangle-network/agent-interface` to `0.32.0`.
- Updated `@tangle-network/agent-eval` to `0.126.5` and `@tangle-network/agent-interface` to `0.32.0`.
- Kept memory provider evaluations resumable and branch-isolated while moving search ownership to the supplied method.
- Restricted immutable references to lowercase SHA-256 and full Git commit identities.

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Supply application callbacks for those decisions, or use `@tangle-network/agent-
## Install

```bash
pnpm add @tangle-network/agent-knowledge @tangle-network/agent-eval@0.126.3
pnpm add @tangle-network/agent-knowledge @tangle-network/agent-eval@0.126.5
```

Requires Node.js 20.19 or later.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"verify:official-optimizers": "node scripts/verify-official-optimizers.mjs"
},
"dependencies": {
"@tangle-network/agent-eval": "0.126.3",
"@tangle-network/agent-eval": "0.126.5",
"@tangle-network/agent-interface": "^0.32.0",
"proper-lockfile": "4.1.2",
"zod": "^4.4.3"
Expand Down
10 changes: 5 additions & 5 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

55 changes: 40 additions & 15 deletions scripts/verify-official-optimizers.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,30 +11,28 @@ import { tmpdir } from 'node:os'
import { dirname, join, resolve } from 'node:path'
import { fileURLToPath, pathToFileURL } from 'node:url'

const python = process.env.AGENT_EVAL_TEST_PYTHON
if (!python) {
throw new Error('AGENT_EVAL_TEST_PYTHON must point to Python with GEPA and SkillOpt installed')
}

const repoRoot = resolve(dirname(fileURLToPath(import.meta.url)), '..')
const sourcePackage = JSON.parse(readFileSync(join(repoRoot, 'package.json'), 'utf8'))
const agentEvalVersion = sourcePackage.dependencies?.['@tangle-network/agent-eval']
if (!/^\d+\.\d+\.\d+$/.test(agentEvalVersion)) {
throw new Error('@tangle-network/agent-eval must be pinned to one exact version')
}
const pythonRpcVersion = run(
python,
['-c', "from importlib.metadata import version; print(version('agent-eval-rpc'))"],
repoRoot,
).trim()
if (pythonRpcVersion !== agentEvalVersion) {
throw new Error(
`official optimizer Python bridge ${pythonRpcVersion} does not match agent-eval ${agentEvalVersion}`,
)
}
const tempRoot = mkdtempSync(join(tmpdir(), 'agent-knowledge-official-'))

try {
const python =
process.env.AGENT_EVAL_TEST_PYTHON ?? installOfficialOptimizers(tempRoot, agentEvalVersion)
const pythonRpcVersion = run(
python,
['-c', "from importlib.metadata import version; print(version('agent-eval-rpc'))"],
repoRoot,
).trim()
if (pythonRpcVersion !== agentEvalVersion) {
throw new Error(
`official optimizer Python bridge ${pythonRpcVersion} does not match agent-eval ${agentEvalVersion}`,
)
}

const packDir = join(tempRoot, 'pack')
const appDir = join(tempRoot, 'app')
mkdirSync(packDir, { recursive: true })
Expand Down Expand Up @@ -100,6 +98,33 @@ try {
rmSync(tempRoot, { recursive: true, force: true })
}

function installOfficialOptimizers(root, rpcVersion) {
const venvDir = join(root, 'python')
const basePython = process.env.PYTHON ?? 'python'
run(basePython, ['-m', 'venv', venvDir], repoRoot, { PYTHONNOUSERSITE: '1' })
const python =
process.platform === 'win32'
? join(venvDir, 'Scripts', 'python.exe')
: join(venvDir, 'bin', 'python')
run(
python,
[
'-m',
'pip',
'install',
'--disable-pip-version-check',
'--index-url=https://pypi.org/simple',
'--no-cache-dir',
'--only-binary=agent-eval-rpc,gepa',
`agent-eval-rpc==${rpcVersion}`,
'gepa[full]==0.1.4',
'skillopt @ git+https://github.com/microsoft/SkillOpt.git@61735e3922efc2b90c6d6cab561e62e98452ca90',
],
repoRoot,
)
return python
}

function run(command, args, cwd, env = {}) {
const result = spawnSync(command, args, {
cwd,
Expand Down
Loading