Skip to content

Commit 0afcef9

Browse files
committed
Update max agent steps
1 parent eb5a4dc commit 0afcef9

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

cli/src/utils/create-run-config.ts

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ import {
44
RETRY_BACKOFF_MAX_DELAY_MS,
55
} from '@codebuff/sdk'
66

7-
import { createEventHandler, createStreamChunkHandler } from './sdk-event-handlers'
7+
import {
8+
createEventHandler,
9+
createStreamChunkHandler,
10+
} from './sdk-event-handlers'
811

912
import type { EventHandlerState } from './sdk-event-handlers'
1013
import type { AgentDefinition, MessageContent, RunState } from '@codebuff/sdk'
@@ -68,15 +71,15 @@ export const createRunConfig = (params: CreateRunConfigParams) => {
6871
setIsRetrying(true)
6972
setStreamStatus('waiting')
7073
},
71-
onRetryExhausted: async ({ totalAttempts, errorCode }: RetryExhaustedArgs) => {
72-
logger.warn(
73-
{ totalAttempts, errorCode },
74-
'SDK exhausted all retries',
75-
)
74+
onRetryExhausted: async ({
75+
totalAttempts,
76+
errorCode,
77+
}: RetryExhaustedArgs) => {
78+
logger.warn({ totalAttempts, errorCode }, 'SDK exhausted all retries')
7679
},
7780
},
7881
agentDefinitions,
79-
maxAgentSteps: 40,
82+
maxAgentSteps: 100,
8083
handleStreamChunk: createStreamChunkHandler(eventHandlerState),
8184
handleEvent: createEventHandler(eventHandlerState),
8285
}

common/src/constants/agents.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,4 +92,4 @@ export const AGENT_NAME_TO_TYPES = Object.entries(AGENT_NAMES).reduce(
9292
{} as Record<string, string[]>,
9393
)
9494

95-
export const MAX_AGENT_STEPS_DEFAULT = 25
95+
export const MAX_AGENT_STEPS_DEFAULT = 100

0 commit comments

Comments
 (0)