Skip to content

Commit

Permalink
fix: remove useless validation
Browse files Browse the repository at this point in the history
  • Loading branch information
henrycunh committed Nov 9, 2023
1 parent 1b185f7 commit 2898108
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion examples/simple-proxy-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const proxy = createCursiveProxy()

const response = await proxy.handle({
messages: [{ 'role': 'user', 'content': 'Return a person called John, aged 43.' }],
model: 'gpt-3.5-turbo-16k',
model: 'gpt-3.5-turbo-16k',
schema: person
})

Expand Down
1 change: 0 additions & 1 deletion examples/simple-script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import { useCursive } from '../src/index'

const cursive = useCursive({ countUsage: true })

debugger
const { answer, usage } = await cursive.ask({ prompt: 'Tell me a short short joke' })

console.log({
Expand Down
1 change: 0 additions & 1 deletion src/cursive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -688,7 +688,6 @@ async function buildAnswer<T extends TSchema | undefined = undefined>(
if (options.schema) {
const output = result.data.answer.functionResult
// Validate the output against the schema
const isValid = Value.Check(options.schema, output)
resolvedAnswer = output
}

Expand Down

0 comments on commit 2898108

Please sign in to comment.