Skip to content

Supercharge your AI agents with data from the web and beyond. Building the library for superintelligence. 🔥

feat(engpicker): add env DISABLE_ENGPICKER

Gergő Móricz46df33e3b2f8
diff --git a/apps/api/src/config.ts b/apps/api/src/config.ts
index 943f2662a..c33785556 100644
--- a/apps/api/src/config.ts
+++ b/apps/api/src/config.ts
@@ -187,6 +187,7 @@ const configSchema = z.object({
GITHUB_RUN_NUMBER: z.string().optional(),
GITHUB_REF_NAME: z.string().optional(),
RESTRICTED_COUNTRIES: delimitedList(",").optional(),
+ DISABLE_ENGPICKER: z.stringbool().optional(),
});
export const config = configSchema.parse(process.env);
diff --git a/apps/api/src/services/indexing/index-worker.ts b/apps/api/src/services/indexing/index-worker.ts
index cdb39998b..f8ffaee1e 100644
--- a/apps/api/src/services/indexing/index-worker.ts
+++ b/apps/api/src/services/indexing/index-worker.ts
@@ -770,6 +770,11 @@ const DOMAIN_FREQUENCY_INTERVAL = 10000;
);
const engpickerPromise = (async () => {
+ if (config.DISABLE_ENGPICKER) {
+ logger.info("Engpicker is disabled, skipping");
+ return;
+ }
+
while (!isShuttingDown) {
await new Promise(resolve => setTimeout(resolve, 1000));
try {