Skip to main content

startTurn

startTurn(opts?): Turn Start a new Turn. If a Conversation is active, the turn inherits its conversationId; otherwise the turn has no conversation id.

Parameters

NameType
optsTurnInit

Returns

Turn Example
weave.startTurn();
Example
weave.startTurn({
  : 'research-bot-prod',
  : 'research-bot',
  : 'Looks up facts on Wikipedia.',
  : '1.4.2',
  : 'gpt-4o',
  : 'What is the weather in Tokyo?',
  : ['You are a helpful weather bot.'],
  : new ('2026-05-29T10:00:00.000Z'),
});

Defined in

src/genai/api.ts:54