Skip to content

Commit

Permalink
Hotfix for new API format (#67)
Browse files Browse the repository at this point in the history
Co-authored-by: aoife cassidy <[email protected]>
  • Loading branch information
bcherry and nbsp authored Sep 26, 2024
1 parent 08b9a32 commit 4e6baba
Show file tree
Hide file tree
Showing 4 changed files with 667 additions and 364 deletions.
5 changes: 5 additions & 0 deletions .changeset/dirty-cycles-suffer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@livekit/agents-plugin-openai": minor
---

Hotfix for new API format
8 changes: 4 additions & 4 deletions examples/src/minimal_assistant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//
// SPDX-License-Identifier: Apache-2.0
import { type JobContext, WorkerOptions, cli, defineAgent } from '@livekit/agents';
import { OmniAssistant, defaultConversationConfig } from '@livekit/agents-plugin-openai';
import { OmniAssistant, defaultSessionConfig } from '@livekit/agents-plugin-openai';
import { fileURLToPath } from 'node:url';
import { z } from 'zod';

Expand All @@ -13,9 +13,9 @@ export default defineAgent({
console.log('starting assistant example agent');

const assistant = new OmniAssistant({
conversationConfig: {
...defaultConversationConfig,
system_message: 'You are a helpful assistant.',
sessionConfig: {
...defaultSessionConfig,
instructions: 'You are a helpful assistant.',
},
functions: {
weather: {
Expand Down
Loading

0 comments on commit 4e6baba

Please sign in to comment.