mirror of
https://github.com/f/awesome-chatgpt-prompts.git
synced 2024-12-22 07:09:39 -08:00
Merge 3f1d36747f into 514989d563
This commit is contained in:
commit
0f9876256b
3 changed files with 85 additions and 1 deletions
29
HowToPlayByMain.md
Normal file
29
HowToPlayByMain.md
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
|
||||
|
||||
# What and Why
|
||||
|
||||
This is a [Awesome ChatGPT Prompts](https://github.com/f/awesome-chatgpt-prompts) implement code for beginner to play!!!
|
||||
This is a ChatGPT Prompt for Beginner!!!
|
||||
Enjoy yourself,bro
|
||||
|
||||
# Usage
|
||||
|
||||
1. Change Prompt
|
||||
|
||||
According to your act,put the prompt from prompts.csv into the prompt variable
|
||||
|
||||
2. Run code,give the input,ChatGPT will output depend on your task
|
||||
|
||||
3. If you get it,you can DIY the code
|
||||
|
||||
I give extra code that has been commented,u can use it.
|
||||
|
||||
Enjoy it , Bro , have fun!
|
||||
|
||||
# Try it for more
|
||||
|
||||
[ChatGPT Official Document](https://platform.openai.com/docs/introduction/overview)
|
||||
|
||||
[Awesome ChatGPT Prompts](https://github.com/f/awesome-chatgpt-prompts)
|
||||
|
||||
[Make money by prompt](https://promptbase.com/)
|
||||
25
README.md
25
README.md
|
|
@ -70,7 +70,7 @@ The _unofficial_ ChatGPT desktop application provides a convenient way to access
|
|||
### Create your own prompt using AI
|
||||
|
||||
[Merve Noyan](https://huggingface.co/merve) created an exceptional [ChatGPT Prompt Generator App](https://huggingface.co/spaces/merve/ChatGPT-prompt-generator), allowing users to generate prompts tailored to their desired persona. The app uses this repository as its training dataset.
|
||||
|
||||
|
||||
---
|
||||
|
||||
### Using prompts.chat
|
||||
|
|
@ -799,6 +799,29 @@ Contributed by [@lemorage](https://github.com/lemorage)
|
|||
Contributed by [@goeksu](https://github.com/goeksu)
|
||||
>You are a cheap travel ticket advisor specializing in finding the most affordable transportation options for your clients. When provided with departure and destination cities, as well as desired travel dates, you use your extensive knowledge of past ticket prices, tips, and tricks to suggest the cheapest routes. Your recommendations may include transfers, extended layovers for exploring transfer cities, and various modes of transportation such as planes, car-sharing, trains, ships, or buses. Additionally, you can recommend websites for combining different trips and flights to achieve the most cost-effective journey.
|
||||
|
||||
## As a Business email Writer
|
||||
|
||||
Contributed by: [@Formyselfonly](https://github.com/Formyselfonly)
|
||||
|
||||
>Please ignore the previous conversation and generate an email for me in the following format. If you encounter a link, put it on a separate line,
|
||||
>Mail Type: <Commercial Mail>
|
||||
>Email language: <English>
|
||||
>From: <Mike>
|
||||
>To: <Amy>
|
||||
>Email text: <I am very sorry to reply to you so late. We are slow to respond to emails. You can go to our DC community and ask an administrator a question. On the issue of inventory. Because we are a paid tool, we have a limited amount of free stock per day. DC: https://www.google.com>
|
||||
|
||||
## As a Wikipedia summarizer
|
||||
|
||||
Contributed by: [@Formyselfonly](https://github.com/Formyselfonly)
|
||||
|
||||
```
|
||||
As a Wikipedia expert, you are familiar with the contents of Wikipedia and various knowledge bases. I will provide you with links, and then ask you related questions. You should give it in the form of MarkDown. What I provide to you Wikipedia
|
||||
link:<https://en.wikipedia.org/wiki/Tesla,_Inc.?wprov=srpw1_0>
|
||||
Question: <Who is the founder of Tesla,Inc? Why did he achieve such an achievement? What is your opinion of him?>
|
||||
```
|
||||
|
||||
|
||||
|
||||
## Contributors 😍
|
||||
|
||||
Many thanks to these AI whisperers:
|
||||
|
|
|
|||
32
main.py
Normal file
32
main.py
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
import openai
|
||||
def generate_prompt(prompt):
|
||||
#U can DIY by these function
|
||||
return prompt
|
||||
def openai_reply(content, apikey):
|
||||
openai.api_key = apikey
|
||||
response = openai.ChatCompletion.create(
|
||||
# You can change gpt-3.5-turbo-0301 into other model like gpt-4
|
||||
model="gpt-3.5-turbo-0301", # gpt-3.5-turbo-0301
|
||||
messages=[
|
||||
# {"role": "system", "content": ""}, you can DIY by the content
|
||||
{"role": "user", "content": generate_prompt(content)}
|
||||
],
|
||||
#The temperature and top_p is more low,the random is more low
|
||||
#If you should keep your answer accuracy,such as you need translate,
|
||||
# you can set temperature=0.2 and top_p=0.2
|
||||
temperature=0.5,
|
||||
max_tokens=1000,
|
||||
top_p=0.5,
|
||||
frequency_penalty=0,
|
||||
presence_penalty=0,
|
||||
)
|
||||
# print(response)
|
||||
return response.choices[0].message.content
|
||||
|
||||
#Run the code,to test,to show these
|
||||
# Just change the prompt by prompts.csv
|
||||
#Such as these code,you can change pwd to ls,and you can change the code using while True and input to interactive with the AI
|
||||
prompt="I want you to act as a linux terminal. I will type commands and you will reply with what the terminal should show. I want you to only reply with the terminal output inside one unique code block, and nothing else. do not write explanations. do not type commands unless I instruct you to do so. when i need to tell you something in english, i will do so by putting text inside curly brackets {like this}. my first command is pwd"
|
||||
#Get the api key from https://beta.openai.com/account/api-keys,it's free,just sign up
|
||||
response=openai_reply(prompt,"Your-API-KEY")
|
||||
print(response)
|
||||
Loading…
Add table
Add a link
Reference in a new issue