@@ -140,9 +140,9 @@ export async function AiLocateElement(options: {
140140 const targetElementDescriptionText = extraTextFromUserPrompt (
141141 targetElementDescription ,
142142 ) ;
143- const userInstructionPrompt = await findElementPrompt . format ( {
144- targetElementDescription : targetElementDescriptionText ,
145- } ) ;
143+ const userInstructionPrompt = findElementPrompt (
144+ targetElementDescriptionText ,
145+ ) ;
146146 const systemPrompt = systemPromptToLocateElement ( vlMode ) ;
147147
148148 let imagePayload = screenshotBase64 ;
@@ -282,9 +282,9 @@ export async function AiLocateSection(options: {
282282 const { screenshotBase64 } = context ;
283283
284284 const systemPrompt = systemPromptToLocateSection ( vlMode ) ;
285- const sectionLocatorInstructionText = await sectionLocatorInstruction . format ( {
286- sectionDescription : extraTextFromUserPrompt ( sectionDescription ) ,
287- } ) ;
285+ const sectionLocatorInstructionText = sectionLocatorInstruction (
286+ extraTextFromUserPrompt ( sectionDescription ) ,
287+ ) ;
288288 const msgs : AIArgs = [
289289 { role : 'system' , content : systemPrompt } ,
290290 {
@@ -396,7 +396,7 @@ export async function AiExtractElementInfo<T>(options: {
396396 const systemPrompt = systemPromptToExtract ( ) ;
397397 const { screenshotBase64 } = context ;
398398
399- const extractDataPromptText = await extractDataQueryPrompt (
399+ const extractDataPromptText = extractDataQueryPrompt (
400400 options . pageDescription || '' ,
401401 dataQuery ,
402402 ) ;
0 commit comments