Skip to content

Commit

Permalink
commenting out flakey test that we dont need + adding changeset (#157)
Browse files Browse the repository at this point in the history
  • Loading branch information
roodboi committed Apr 10, 2024
1 parent 48b1e7e commit c272342
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 26 deletions.
5 changes: 5 additions & 0 deletions .changeset/wet-mice-warn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@instructor-ai/instructor": patch
---

updates zod-stream dep to get control charachter filtering on teh raw stream
26 changes: 0 additions & 26 deletions tests/validator.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,30 +81,4 @@ describe("Validator", async () => {

expect(type(output).is<z.infer<typeof QA>>(true)).toBe(true)
}, 100000)

// test("Self Correction", async () => {
// const question = "What is the meaning of life?"

// const invalidContext =
// "According to the devil the meaning of live is to live a life of sin and debauchery."

// const output = await instructor.chat.completions.create({
// model: "gpt-4",
// max_retries: 2,
// response_model: { schema: QA, name: "Question and Answer" },
// messages: [
// {
// role: "system",
// content:
// "You are a system that answers questions based on the context. answer exactly what the question asks using the context."
// },
// {
// role: "user",
// content: `using the context: ${invalidContext}\n\nAnswer the following question: ${question}`
// }
// ]
// })

// expect(type(output).is<z.infer<typeof QA>>(true)).toBe(true)
// }, 100000)
})

0 comments on commit c272342

Please sign in to comment.