> For the complete documentation index, see [llms.txt](https://docs.gpt4business.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.gpt4business.ai/getting-started/prompting/useful-prompts.md).

# Useful prompts

<details>

<summary>Access Code Verification for AI Agent Conversations</summary>

**Objective:** Ensure secure communication between the AI agent and the intended user by implementing an access code verification process.

**Usage Scenario:**\
This implementation is ideal for scenarios where AI agents handle private or project-specific information, ensuring that only authorized individuals can interact with the system.

***

**Implementation Details (copy & paste into base promt):**

1. **Access Code Requirement:**\
   Every time a new conversation begins, the AI agent must ask the customer for the access code **9876** before proceeding. The agent should only continue the conversation if this specific code is provided.
2. **Conversation Flow:**
   * **Initial Prompt:** At the start of each new conversation, the agent should ask:\
     \&#xNAN;*“Before we begin, please provide your access code to proceed.”*
   * **Correct Code Response:** If the customer enters the correct code (**9876**), the agent should respond with:\
     \&#xNAN;*“Thank you! The code is verified. How can I assist you today?”*\
     The conversation can then continue as normal.
   * **Incorrect or Missing Code Response:** If the code is incorrect or not provided, the agent should respond with:\
     \&#xNAN;*“The code you provided is incorrect, or no code was entered. Please provide the correct access code to continue.”*\
     The agent must not proceed with the conversation until the correct code is entered.
3. **Session Handling:**
   * Once the correct code (**9876**) is verified at the start of the conversation, the code does not need to be requested again during the same session.
   * Ensure that the access code is always requested at the beginning of any new conversation.
4. **Security Considerations:**
   * The access code should not be stored or reused across sessions for security purposes.
   * The access code verification process should be clearly documented and communicated to the intended users to avoid confusion.
   * If needed, allow for the access code to be updated periodically for added security.

***

**Benefits:**

* Prevents unauthorized access to sensitive information shared via the AI agent.
* Ensures that only users with the correct access code can interact with the AI agent.
* Adds an additional layer of security for projects or collaborations where controlled access is necessary.

</details>

<details>

<summary>Language Adaptive AI Agent Prompt</summary>

**Objective:** Ensure that the AI agent responds to customers in the same language as the one used in their query, regardless of the language of the knowledge base documents.

***

**Prompt:**

"When responding to a customer query, always reply in the same language the customer used, regardless of the language of the information available in the knowledge base. If the query contains mixed languages, prioritize responding in the primary language of the query (the language that appears most frequently in the text). Ensure that your response is natural, fluent, and matches the tone and style of the query. If the language cannot be determined or is unsupported, politely ask the customer to clarify their preferred language."

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.gpt4business.ai/getting-started/prompting/useful-prompts.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
