Skip to content

Commit 6169da5

Browse files
committed
tweaks
1 parent 4908418 commit 6169da5

File tree

3 files changed

+9
-15
lines changed

3 files changed

+9
-15
lines changed

.agents/base2/base2.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,11 @@ import {
66
type SecretAgentDefinition,
77
} from '../types/secret-agent-definition'
88

9-
export const createBase2: (mode: 'normal' | 'max') => SecretAgentDefinition = (
10-
mode,
11-
) => {
9+
export const createBase2: (
10+
mode: 'normal' | 'max',
11+
) => Omit<SecretAgentDefinition, 'id'> = (mode) => {
1212
const isMax = mode === 'max'
1313
return {
14-
id: 'base2',
1514
publisher,
1615
model: 'anthropic/claude-sonnet-4.5',
1716
displayName: 'Buffy the Orchestrator',
@@ -139,5 +138,5 @@ The user asks you to implement a new feature. You respond in multiple steps:
139138
}
140139
}
141140

142-
const definition = createBase2('normal')
141+
const definition = { ...createBase2('normal'), id: 'base2' }
143142
export default definition

evals/buffbench/main.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,14 @@
11
import path from 'path'
2-
import fs from 'fs'
32

43
import { runBuffBench } from './run-buffbench'
54

65
async function main() {
7-
const results = await runBuffBench({
6+
await runBuffBench({
87
evalDataPath: path.join(__dirname, 'eval-codebuff.json'),
98
agents: ['base2-simple', 'base2'],
10-
commitConcurrency: 20,
9+
taskConcurrency: 20,
1110
})
1211

13-
const outputPath = path.join(__dirname, 'results.json')
14-
fs.writeFileSync(outputPath, JSON.stringify(results, null, 2))
15-
console.log(`\nResults written to ${outputPath}`)
16-
1712
process.exit(0)
1813
}
1914

evals/buffbench/run-buffbench.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -155,10 +155,10 @@ async function runTask(options: {
155155
export async function runBuffBench(options: {
156156
evalDataPath: string
157157
agents: string[]
158-
commitConcurrency?: number
158+
taskConcurrency?: number
159159
client?: CodebuffClient
160160
}) {
161-
const { evalDataPath, agents, commitConcurrency = 1 } = options
161+
const { evalDataPath, agents, taskConcurrency = 1 } = options
162162

163163
const evalData: EvalDataV2 = JSON.parse(
164164
fs.readFileSync(evalDataPath, 'utf-8'),
@@ -191,7 +191,7 @@ export async function runBuffBench(options: {
191191
}
192192
}
193193

194-
const commitLimit = pLimit(commitConcurrency)
194+
const commitLimit = pLimit(taskConcurrency)
195195

196196
const commitPromises = commitsToRun.map((commit, index) =>
197197
commitLimit(() =>

0 commit comments

Comments
 (0)