# checkCostLimit

**Kind:** Function

**Source:** [`atloria-monorepo/libs/agent-core/src/benchmark/agent-hardening.ts`](https://github.com/sherkety/atloria/blob/main/atloria-monorepo/libs/agent-core/src/benchmark/agent-hardening.ts#L141)

Check if a task has exceeded its cost budget.

Pattern from SWE-agent: $3/task default limit.
When exceeded, autosubmit whatever patch exists.

## Signature

```ts
function checkCostLimit(currentCost: number, limit: number | undefined): boolean
```

## Parameters

| Name | Type |
|---|---|
| `currentCost` | `number` |
| `limit` | `number | undefined` |

**Returns:** `boolean`
