starGeneral Hints and Guidance for Prompting

A prompt is the input or instruction you provide to a Large Language Model (LLM) to receive a desired response or action. It is the primary method of communicating with the LLM. The quality and precision of the answers you obtain from an LLM greatly depend on how well you formulate your prompt.

Building a Successful Prompt ("the LLI Prompt Recipe")

To create a successful prompt, consider the following elements and principles:

  1. Clarity and Precision:

    1. A successful prompt should be clearly and precisely formulated.

    2. Avoid vague or ambiguous instructions.

    3. A lean prompt helps the LLM better understand the requirements and deliver more relevant responses.

  2. Context and Details:

    1. Provide the LLM with sufficient context so it can understand the question or task in the correct framework. Detailed information can help produce more specific and accurate responses.

    2. Use clear and direct language. Humor, sarcasm, or cynicism are often misinterpreted. A certain level of directive tone can be helpful with current LLMs.

  3. Structure:

    1. Add Structure your prompt into easily understandable parts, especially for complex or multi-step questions. Bullet points or numbered lists can be useful here.

    2. Include instructions at the beginning of the prompt.

    3. Use ### or “”” to separate instructions from context.

  4. Examples and Format:

    1. Provide examples or a desired format to give the LLM a clearer idea of the expected response (e.g., in the system prompt).

    2. Act in the role of (role) to create this (task) in (format).

    3. For instance, instruct the LLM to generate additional questions to gain a clearer understanding of a legal issue or topic (cognitive verification pattern).

  5. Relevance and Focus:

    1. Ensure your prompt is directly focused on the relevant question or task.

    2. Avoid unnecessary information that might distract the LLM.

  6. Accuracy and Fairness in Prompts:

    1. The language used in prompts plays a crucial role in the generated results. Generative AI models may amplify stereotypes and biases present in training data. For more diverse and fair results, consider the following:

      1. English as Preferred Language Most LLMs are based on training data with a significant proportion of English texts. Whenever possible, formulate prompts in English and explicitly mention diversity.

      2. Neutrality vs. Diversity Use neutral language when no specific identity should be highlighted, to avoid stereotypes. At the same time, consider consciously including diversity in your prompts when appropriate.

By following these principles when creating your prompts, you can significantly improve the efficiency and accuracy of the responses you receive from LLMs. This not only saves you time but also enhances the quality of the results you use in your legal work.

Important Notes and Useful Information

Temperature Setting in LLMs

The temperature is a floating value between 0 and controls the creativity and randomness of generated texts, influencing the likelihood of the next words in the text. A higher temperature (close to 1) results in more original and unpredictable responses, while a lower temperature produces more predictable and precise results. Most LLMs (or platforms allowing to access LLMs) offer a possibility to set the temperature according to the users specification, just have a look or ask the provider.

Data Protection

We recommend ensuring that no or as few personal data as possible are entered when using prompts and processing through LLMs (data minimization) to protect privacy and comply with data protection regulations.

Information Security

We recommend handling confidential and protected information carefully and ensuring it is not unintentionally disclosed or disseminated. Users should always ensure that all inputs and generated outputs comply with internal information protection policies and do not reveal sensitive data.

Hallucinations

We recommend thoroughly reviewing and validating all content generated by LLMs before using it for legal or compliance-related purposes. LLMs can occasionally produce so-called hallucinations, where they generate plausible but false or fabricated information.

1 Prompt Patterns for Lawyers by Liz Chase

2 Faires KI-Prompting Ein Leitfaden für Unternehmen by Mittelstand-Digital Zentrum Zukunftskultur

Last updated