agentskit.js

cohere

Auto-generated API reference for cohere.

Function: cohere()

cohere(config): AdapterFactory

Defined in: cohere.ts:23

Cohere Command models via Cohere's OpenAI-compatibility endpoint.

  • Streams tokens via SSE (OpenAI-compatible chunks).
  • Supports tool calls in the OpenAI tools shape.
  • Reports usage on the final stream chunk when the upstream model returns it (Cohere's compatibility layer mirrors OpenAI's stream_options: \{ include_usage: true \} semantics).
  • Inherits auto-retry from the shared OpenAI core (retry).

Default model: command-r-plus. Override via model.

#Parameters

#config

Partial<CohereConfig> & object

#Returns

AdapterFactory

Explore nearby

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

On this page