Skip to content

Commit c272342

Browse files
authored
commenting out flakey test that we dont need + adding changeset (#157)
1 parent 48b1e7e commit c272342

File tree

2 files changed

+5
-26
lines changed

2 files changed

+5
-26
lines changed

.changeset/wet-mice-warn.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@instructor-ai/instructor": patch
3+
---
4+
5+
updates zod-stream dep to get control charachter filtering on teh raw stream

tests/validator.test.ts

-26
Original file line numberDiff line numberDiff line change
@@ -81,30 +81,4 @@ describe("Validator", async () => {
8181

8282
expect(type(output).is<z.infer<typeof QA>>(true)).toBe(true)
8383
}, 100000)
84-
85-
// test("Self Correction", async () => {
86-
// const question = "What is the meaning of life?"
87-
88-
// const invalidContext =
89-
// "According to the devil the meaning of live is to live a life of sin and debauchery."
90-
91-
// const output = await instructor.chat.completions.create({
92-
// model: "gpt-4",
93-
// max_retries: 2,
94-
// response_model: { schema: QA, name: "Question and Answer" },
95-
// messages: [
96-
// {
97-
// role: "system",
98-
// content:
99-
// "You are a system that answers questions based on the context. answer exactly what the question asks using the context."
100-
// },
101-
// {
102-
// role: "user",
103-
// content: `using the context: ${invalidContext}\n\nAnswer the following question: ${question}`
104-
// }
105-
// ]
106-
// })
107-
108-
// expect(type(output).is<z.infer<typeof QA>>(true)).toBe(true)
109-
// }, 100000)
11084
})

0 commit comments

Comments
 (0)