From b831ee13e863b3bbf2ba0588adabb5f4bced7b7d Mon Sep 17 00:00:00 2001 From: Henry Fontanier Date: Thu, 29 Feb 2024 18:17:58 +0100 Subject: [PATCH] enh(tables query): pass full assistant instructions to app (#4069) Co-authored-by: Henry Fontanier --- front/lib/api/assistant/actions/tables_query.ts | 15 +++++++-------- types/src/front/lib/actions/registry.ts | 2 +- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/front/lib/api/assistant/actions/tables_query.ts b/front/lib/api/assistant/actions/tables_query.ts index c16f0d43b9f5..cebcee0b1671 100644 --- a/front/lib/api/assistant/actions/tables_query.ts +++ b/front/lib/api/assistant/actions/tables_query.ts @@ -62,13 +62,7 @@ function getTablesQueryAppSpecification() { { name: "question", description: - "The plain language question to answer based on the user request and conversation context. The question should include all the context required to be understood without reference to the conversation. If the user has multiple unanswered questions, make sure to include all of them.", - type: "string" as const, - }, - { - name: "guidelines", - description: - "Some additional guidelines that could help generate the right query. This could come from the assistant's instructions or from the conversation history. If the user asked to correct a previous attempt at the same query in a specific way, this information must be included. Return an empty string when not applicable.", + "The plain language question to answer based on the user request and conversation context. The question should include all the context required to be understood without reference to the conversation. If the user has multiple unanswered questions, make sure to include all of them. If the user asked to correct a previous attempt at the same query in a specific way, this information must be included.", type: "string" as const, }, ], @@ -216,7 +210,12 @@ export async function* runTablesQuery({ auth, "assistant-v2-query-tables", config, - [{ question: input.question, guidelines: input.guidelines }] + [ + { + question: input.question, + instructions: configuration.generation?.prompt, + }, + ] ); if (res.isErr()) { diff --git a/types/src/front/lib/actions/registry.ts b/types/src/front/lib/actions/registry.ts index 2a11e47132a9..753f569fef91 100644 --- a/types/src/front/lib/actions/registry.ts +++ b/types/src/front/lib/actions/registry.ts @@ -138,7 +138,7 @@ export const DustProdActionRegistry = createActionRegistry({ workspaceId: PRODUCTION_DUST_APPS_WORKSPACE_ID, appId: "b4f205e453", appHash: - "fee382573c535c4d21d79c3d315b444eda6d6282f44127a2f6a3fb8b544d9f6d", + "cfdf2414c6f61c1a54c8c0527ab6caf2108b32e21da3af7220eaab4ea55f7af8", }, config: { MODEL: {