Skip to content

armgit / orca

Public Imported from GitHub
0

Orca is the place for working with a fleet of agents (e.g. Grok Bot, Claude Code). Run any coding agent with your own subscription. Available on desktop, mobile and remote runtime.

611 B
Raw Blame
export const ORCHESTRATION_ASK_DEFAULT_TIMEOUT_MS = 600_000
export const ORCHESTRATION_ASK_MAX_TIMEOUT_MS = 1_800_000
export const ORCHESTRATION_ASK_CLIENT_GRACE_MS = 5_000

export function clampOrchestrationAskTimeoutMs(timeoutMs: number | undefined): number {
  if (timeoutMs === undefined) {
    return ORCHESTRATION_ASK_DEFAULT_TIMEOUT_MS
  }
  return Math.min(Math.max(0, timeoutMs), ORCHESTRATION_ASK_MAX_TIMEOUT_MS)
}

export function resolveOrchestrationAskClientTimeoutMs(timeoutMs: number | undefined): number {
  return clampOrchestrationAskTimeoutMs(timeoutMs) + ORCHESTRATION_ASK_CLIENT_GRACE_MS
}