From fb0f69c010161c4de1bbc2c0aeb339a255f5db37 Mon Sep 17 00:00:00 2001 From: Eric Date: Mon, 21 Oct 2024 10:26:41 -0500 Subject: [PATCH] Website: Fix lint errors in script (#23049) Changes: - Fixed the lint errors in the `test-llm-generated-sql` script --- website/scripts/test-llm-generated-sql.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/website/scripts/test-llm-generated-sql.js b/website/scripts/test-llm-generated-sql.js index d1a45662f9cc..dc83e7ac2a11 100644 --- a/website/scripts/test-llm-generated-sql.js +++ b/website/scripts/test-llm-generated-sql.js @@ -13,7 +13,7 @@ module.exports = { fn: async function ({naturalLanguageQuestion}) { - let assert = require('assert'); + // let assert = require('assert'); let completeTables = await sails.helpers.getExtendedOsquerySchema(); let prunedTables = completeTables.map((table)=>{ @@ -33,13 +33,13 @@ module.exports = { Provided context: \`\`\` ${JSON.stringify(prunedTables.map((table)=>{ - let lighterTable = _.pick(table, ['name','description','platforms']); - lighterTable.columns = table.columns.map((column)=>{ - let lighterColumn = _.pick(column, ['name', 'description', 'platforms']); - return lighterColumn; - }); - return lighterTable; - }))} + let lighterTable = _.pick(table, ['name','description','platforms']); + lighterTable.columns = table.columns.map((column)=>{ + let lighterColumn = _.pick(column, ['name', 'description', 'platforms']); + return lighterColumn; + }); + return lighterTable; + }))} \`\`\` Please respond in JSON, with the same data shape as the provided context, but with the array filtered to include only relevant tables.`;