Skip to content
View in the app

A better way to browse. Learn more.

Benchmark Six Sigma Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Message added by Mayank Gupta,

Prompt Engineering is the process of crafting and refining input instructions to optimize the performance of AI models, particularly large language models (LLMs) like GPT, to produce accurate and relevant outputs. It involves creating clear, precise, and contextually rich prompts that align with the task at hand, ensuring the AI understands and responds effectively.

 

An application-oriented question on the topic along with responses can be seen below. The best answer was provided by Michael Navin Xavier on 13th Dec 2024.

 

Applause for all the respondents - Jiten Nagar, Michael Navin Xavier.

Featured Replies

Q 728. In what ways can prompt engineering reduce hallucination in generative AI, particularly when working with highly specialized domains? Explain with examples.

 

Note for website visitors -

Solved by Mike

In the audit industry, where accuracy and adherence to standards are crucial, hallucinations can result in serious professional risks, such as providing incorrect interpretations of compliance standards or generating fictitious audit findings. Below is an example of how prompt engineering can help reduce hallucinations for internal audits:

 

Scenario: Drafting an Internal Audit Report

 

Suppose you want the AI to help draft an audit report for compliance with internal financial controls.

 

Generic Prompt:

 

“Generate an internal audit report for financial compliance.”

 

Potential Issue:

The model might fabricate findings, create generic observations, or misrepresent audit standards, leading to inaccuracies in the report.

 

Refined Prompt for Reduced Hallucination:

 

*“Draft an internal audit report for financial compliance based on the following observations:

1. Control over vendor payments was not followed in 20% of sampled transactions.

2. Reconciliations were delayed in three out of five months reviewed.

3. There were no deviations in payroll processing.

Include recommendations for improvement and ensure alignment with Section 134 of the Companies Act, 2013.”

 

Why It Reduces Hallucination:

Context: The specific observations guide the model to focus on known audit findings.

Framework: Referencing Section 134 of the Companies Act, 2013, ensures compliance with the relevant legal standards.

Scope: Explicitly limiting the focus to the given findings avoids fabricated or irrelevant issues.

 

Prompt engineering can help reduce hallucinations in generative AI, basically in specialized domains, by carefully crafting questions to guide the AI towards more accurate and relevant responses.

Listed below are some effective strategies.

  • By using specific context and constraints by providing clear context and constraints that helps the AI focus on relevant information.
  • Applying chain-of-verification prompting which involves breaking down the task into smaller steps and verifying each part.
  • Adding reflective prompting which encourages the AI to reflect on its response can improve accuracy.
  • Using scenario-based prompting which helps with realistic scenarios can help the AI generate more accurate responses.

For instance, in the field of cybersecurity, we can begin questioning with, what are the most common types of cyber-attacks? After that, how do these attacks exploit vulnerabilities in cloud computing environments? This method helps AI and also helps AI provide more detailed and accurate information.

  • Solution

AI Hallucinations occur when LLM’s make up answers that are not factual. This mostly occurs when the model tries to be extra helpful by fabrication information when the model does not have a factual backing for the data presented. This also occurs when the model has not been trained on that topic.

Prompt engineering techniques focus on guiding models to produce truthful or factual data for any query. By refining these prompts, we can minimize the number of hallucinations produced by AI and increase the overall performance of the AI system. Some of the practices we can follow to reduce hallucinations ae listed below.,

 

1)      Give clear and precise prompts avoiding ambiguity that may provide irrelevant output

2)      Explicitly state the context with some additional background information

3)      Break down the tasks into smaller manageable steps ensuring that AI models understand it easily

4)      If need arises specify the output format required for the answer

5)      Incorporate examples to get the desired output

6)      Ask the model to differentiate between factual vs speculative answers

7)      Ask the model to prove the references for the source of the information and prove its limits or in simpler terms ask the model to validate its own responses

8)     Usage of domain specific terminology also helps to align responses reducing nonsensical information

 

When working with highly specialized domains, we can use some of the below mentioned methods to reduce hallucination.,

 

1)      RAG – Retrieval Augmented Generation: This method combines the model’s capability to generate information with reliable information sources like knowledge bases.

Example: Who is called the “Father of the nation” in India? This will make the model look up information in the knowledge base before generating a response. Likewise, if any question is asked pertaining to a specific domain the model will investigate the relevant knowledge bases before responding

2)      ReAct Prompting – Reasoning + Acting: This method is used reduce hallucination by incorporating a step-by-step reasoning and an external tool such as an API to ensure that the responses are grounded in factual data.

Example: In medical diagnosis, instead of asking for symptoms of a disease, we break down the question into smaller steps and narrow down to the specifics based on reliable medical data and then ask it to respond with prognosis

 

There are several other methods to reduce the impact of hallucination in generative AI but there is still a long way to go to build trustworthy intelligence as the knowledge bases are vast and susceptibility to nonfactual information which is a reality today.

 

Michael Navin Xavier has provided the best answer to the question. His answer is well rounded and articulated. Well Done!!

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.