Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release to Production #381

Merged
merged 7 commits into from
Aug 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions __test__/ai.e2e.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import parser from 'node-html-parser';
import { openai } from "@/libs/openai";
import { createOpenAICompletion } from "@/libs/openai";
import { z } from "zod";
import {zodToJsonSchema} from "zod-to-json-schema"
import { ARIARoleDefinitionKey, roles } from "aria-query";
Expand Down Expand Up @@ -113,7 +113,7 @@ test("ai", async ({page}) => {
await page.goto(BASE_URL);
const minimumHtml = purizeHtml(await page.content());
console.log(minimumHtml);
const result = await openai.chat.completions.create({
const result = await createOpenAICompletion({
model: "gpt-4o-2024-05-13",
tools: [
{
Expand Down Expand Up @@ -143,7 +143,7 @@ test("ai", async ({page}) => {
console.log(cases);

const testCaseDetails = await Promise.all(cases.map(async c => {
const result = await openai.chat.completions.create({
const result = await createOpenAICompletion({
model: "gpt-4o-2024-05-13",
tools: [
{
Expand Down Expand Up @@ -213,7 +213,7 @@ test("ai", async ({page}) => {
console.log(testCase.case);
const html = purizeHtml(await page.content());

const result = await openai.chat.completions.create({
const result = await createOpenAICompletion({
model: "gpt-4o-2024-05-13",
temperature: 0,
messages: [
Expand Down
Loading