Skip to content

Commit 764d605

Browse files
fix(auditor): increase max poll duration to 30 minutes and add limit to scrape (#1897)
Co-authored-by: Tofik Hasanov <[email protected]>
1 parent d246ee9 commit 764d605

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

apps/app/src/trigger/tasks/auditor/generate-auditor-content.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ ${TONE_RULES}`,
124124

125125
const sleep = (ms: number): Promise<void> => new Promise((resolve) => setTimeout(resolve, ms));
126126

127-
const MAX_POLL_DURATION_MS = 1000 * 60 * 5; // 5 minutes
127+
const MAX_POLL_DURATION_MS = 1000 * 60 * 30; // 30 minutes
128128
const POLL_INTERVAL_MS = 5000; // 5 seconds
129129

130130
async function scrapeWebsite(website: string): Promise<string> {
@@ -145,6 +145,7 @@ async function scrapeWebsite(website: string): Promise<string> {
145145
urls: [website],
146146
prompt:
147147
'Extract all text content from this website, including company information, services, mission, vision, and any other relevant business information. Return the content as plain text or markdown.',
148+
limit: 10
148149
}),
149150
});
150151

packages/db/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
"check-types": "tsc --noEmit",
3939
"db:generate": "prisma generate",
4040
"db:migrate": "prisma migrate dev",
41+
"db:migrate:reset": "prisma migrate reset",
4142
"db:push": "prisma db push",
4243
"db:seed": "bun prisma/seed/seed.ts",
4344
"db:studio": "prisma studio",

0 commit comments

Comments
 (0)