agentskit.js

ApplyCarbonOptions

Auto-generated API reference for ApplyCarbonOptions.

Interface: ApplyCarbonOptions

Defined in: adapters/src/carbon.ts:67

#Properties

#fallback?

optional fallback?: number

Defined in: adapters/src/carbon.ts:77

Fallback gCO2eq per 1k tokens when no table entry is found.


#keyFor?

optional keyFor?: (candidate) => `$\{string\}:$\{string\}` | undefined

Defined in: adapters/src/carbon.ts:75

How to derive the lookup key for a candidate. Defaults to $\{provider\}:$\{region\} where provider is the candidate id before the first - and region is candidate.region.

#Parameters

candidate

RouterCandidate

#Returns

`$\{string\}:$\{string\}` | undefined


#table?

optional table?: CarbonTable

Defined in: adapters/src/carbon.ts:69

Override the default table.

Explore nearby

✎ Edit this page on GitHubΒ·Found a problem? Open an issue β†’Β·How to contribute β†’

On this page