Skip to content

Commit

Permalink
fix: correct response type
Browse files Browse the repository at this point in the history
  • Loading branch information
lucgagan committed Jun 21, 2023
1 parent 2720d2b commit 0ef71a5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/createChat.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ test("calls user defined function", async () => {
assert.equal(response.function_call?.name, 'get_current_weather');
});

test("calls user defined function", async () => {
test("overrides function call", async () => {
const chat = createChat({
apiKey: OPENAI_API_KEY,
model: "gpt-3.5-turbo-0613",
Expand Down
2 changes: 1 addition & 1 deletion src/createCompletions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ export type CompletionsOptions = z.infer<typeof CompletionsOptionsZodSchema>;
const ChoiceZodSchema = z
.object({
role: RoleZodSchema,
content: z.string().optional(),
content: z.string(),
finishReason: z.string(),
function_call: z
.object({
Expand Down

0 comments on commit 0ef71a5

Please sign in to comment.