Skip to main content

Prompts

A bot's prompt (persona and reply logic) is a natural language instruction used to tell the artificial intelligence what task to perform. The first step in building a bot is to write prompts to set the bot's identity. A good prompt can clearly tell AI your needs, allowing AI to provide the information you need or perform tasks more accurately and efficiently.

Therefore, the clearer and more specific the prompt writing, the more the bot's reply will meet your expectations.

  • Writing Suggestions: Before you start writing prompts, please refer to the following content.

  • Simple Task Scenarios: To get the expected results from the bot, it's recommended to include the following content when writing prompts:

  • Role Setting: Clearly articulate the bot's role and responsibilities, as well as its reply style. This helps the bot more precisely define its service approach.

  • For example: You are a master storyteller capable of generating stories in a very vivid and interesting style.

  • Specific Function + Workflow: Describe the bot's capabilities and workflow, specifying how to respond to user questions in different scenarios.

  • For example: When a user wants to know about the nutritional information of a specific food, please call the “GoogleSearch” skill to collect data. Although the bot will choose tools based on the prompt content, we still recommend reinforcing her tool selection in specific scenarios with specific instructions to ensure accuracy.

Although the bot will choose tools based on the prompt content, we still recommend reinforcing her tool selection in specific scenarios with specific instructions to ensure accuracy.

  • For example: When a user asks about the nutritional value of apples, use “GoogleSearch” to collect data, then summarize and provide the main nutritional components of apples.

Additionally, you can set a reply template for the bot, which she will use to format her answers.

  • For example:
1. Please reply in the following format:
2. **Name of Food**
3. - Nutritional Components: Briefly list the main nutrients
4. - Health Benefits: Briefly describe the benefits of the food to health
  • Setting Answer Range: If you wish to limit the range of the bot's answers, please specify which questions should be answered and which should not.

  • For example: "Only answer questions related to nutritional information; if no relevant information is found, inform the user that it cannot be found, instead of making up content."

  • Complex Task Scenarios: For complex task scenarios, it's recommended to use a structured format for writing prompts, which not only improves readability but also more effectively constrains the bot's behavior. Here is an example of a structured prompt:

# Role
You are a news broadcaster, focused on collecting, processing, and presenting news information. Skilled at using the `newsAnalysis` tool for filtering, verifying, and arranging news content to ensure that the reported news is both accurate and timely. Additionally, you are capable of presenting news stories in an engaging manner, allowing the audience to easily understand complex information.

## Skills
### Skill One: News Material Collection
1. Use the `collectData`function of the `newsAnalysis` tool when needing to obtain information from specific news sources.
2. If the provided news source does not support direct extraction, use Python or R to write scripts for data retrieval.

### If the provided news source does not support direct extraction, use Python or R to write scripts for data retrieval.
1. Cleanse news content using the `contentCleaning` function of the `newsAnalysis` tool, addressing inaccurate or biased information.
2. Process news using content editing and language optimization techniques for further reporting.

### Skill Three: News Arrangement and Presentation
1. Arrange news based on its importance and urgency.
2. Utilize media technology (such as image processing) to help present news stories.

## Constraints
- Topic Limitation: Only report news related to the public interest, avoiding the spread of baseless rumors or false information.
- Output Format: The report content must follow a specified format, maintaining structural consistency.
- Result Interpretation: For reported news, provide background information and analysis, rather than just presenting facts.
- Method Transparency: When collecting news using a specific programming language, the logic and methods adopted should be explained in detail.