From 82e4dc59538d64a8a0d40c123bc57dda4c407166 Mon Sep 17 00:00:00 2001 From: Deepak Tammali <91271578+tdeepak-presidio@users.noreply.github.com> Date: Fri, 21 Feb 2025 18:22:22 +0530 Subject: [PATCH] Update business process add and update prompts (#35) --- .changeset/sour-parrots-vanish.md | 5 +++++ backend/llm/prompts/09_add_business_process.jinja2 | 13 +++++++++++++ .../llm/prompts/10_update_business_process.jinja2 | 13 +++++++++++++ 3 files changed, 31 insertions(+) create mode 100644 .changeset/sour-parrots-vanish.md diff --git a/.changeset/sour-parrots-vanish.md b/.changeset/sour-parrots-vanish.md new file mode 100644 index 0000000..dd56cd8 --- /dev/null +++ b/.changeset/sour-parrots-vanish.md @@ -0,0 +1,5 @@ +--- +"specif-ai": patch +--- + +add guidelines to add and update business process prompts diff --git a/backend/llm/prompts/09_add_business_process.jinja2 b/backend/llm/prompts/09_add_business_process.jinja2 index 1627387..02adf86 100644 --- a/backend/llm/prompts/09_add_business_process.jinja2 +++ b/backend/llm/prompts/09_add_business_process.jinja2 @@ -27,6 +27,19 @@ Provide the Business Process Flow that effectively addresses both the client's r final_business_process_flow must be a single paragraph, not a list or json format. Generate an apt title for final_business_process_flow. Title should be a one-liner not more than 5 words. +STRICT: +(!) The business process flow MUST be based primarily on the client request description. +(!) Every sentence in the response MUST describe a distinct STEP/ ACTION within the business process flow. +(!) Response for final_business_process_flow should not contain: + - Marketing speak + - Phrases that are promotional or that summarize the overall purpose of the application + - Introductory phrases like "The business process starts with..." or "The process begins with.." + - Concluding statements about process effectiveness. + - Benefit-oriented language describing user advantages or positive outcomes (e.g., "for easier exploration," "efficiently manage," "seamlessly connect"). Focus on objective actions and data flow only. +(!) Do not include any other flows that are not part of the client request description. +(!) Ensure each step in the generated business process is directly and demonstrably related to fulfilling the actions described in the Client Request. Eliminate any steps that are generic, implied from the app description, product requirements, business requirements or not directly contributing to the Client Request's objective. +(!) Focus description ONLY on PROCESS FLOW: actions and data. EXCLUDE application properties. + Output Structure should be a valid JSON: Here is the sample Structure. Follow this exactly. Don't add or change the response JSON: { diff --git a/backend/llm/prompts/10_update_business_process.jinja2 b/backend/llm/prompts/10_update_business_process.jinja2 index 068f93a..cf85a07 100644 --- a/backend/llm/prompts/10_update_business_process.jinja2 +++ b/backend/llm/prompts/10_update_business_process.jinja2 @@ -30,6 +30,19 @@ Update the existing Business Process Flow that effectively addresses both the cl final_business_process_flow must be a single paragraph, not a list or json format. Generate an apt title for final_business_process_flow. Title should be an one-liner not more than 5 words. +STRICT: +(!) The business process flow MUST be based primarily on the client request description. +(!) Every sentence in the response MUST describe a distinct STEP/ ACTION within the business process flow. +(!) Response for final_business_process_flow should not contain: + - Marketing speak + - Phrases that are promotional or that summarize the overall purpose of the application + - Introductory phrases like "The updated business process starts with..." or "The updated process begins with.." + - Concluding statements about process effectiveness. + - Benefit-oriented language describing user advantages or positive outcomes (e.g., "for easier exploration," "efficiently manage," "seamlessly connect"). Focus on objective actions and data flow only. +(!) Do not include any other flows that are not part of the client request description. +(!) Ensure each step in the generated business process is directly and demonstrably related to fulfilling the actions described in the Client Request. Eliminate any steps that are generic, implied from the app description, or not directly contributing to the Client Request's objective. +(!) Focus description ONLY on PROCESS FLOW: actions and data. EXCLUDE application properties. + Output Structure should be a valid JSON: Here is the sample Structure: {