|
|
|
@ -1,4 +1,6 @@
|
|
|
|
|
draftPrompt = """# MISSION
|
|
|
|
|
from swarms import OpenAIChat
|
|
|
|
|
|
|
|
|
|
DRAFT_PROMPT = """# MISSION
|
|
|
|
|
Write a 100% unique, creative and in human-like style article of a minimum of 2000 words using headings and sub-headings.
|
|
|
|
|
Ensure your tone is Professional and casual while focusing on presenting information and analysis without excessive embellishment.
|
|
|
|
|
|
|
|
|
@ -19,7 +21,7 @@ Write content that can easily pass the AI detection tools test.
|
|
|
|
|
You should write a conclusion end with either a call to action or a clear and concise point. What is the key takeaway?"""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
reviewPrompt = """# MISSION
|
|
|
|
|
REVIEW_PROMPT = """# MISSION
|
|
|
|
|
You are responsible for refining an article to meet PositiveMed’s stringent publication standards.
|
|
|
|
|
Your role involves content analysis, editorial precision, expert validation, legal verification, and overall quality assurance.
|
|
|
|
|
|
|
|
|
@ -55,10 +57,18 @@ Your role involves content analysis, editorial precision, expert validation, leg
|
|
|
|
|
Re-Write the article, taking into account all review instructions and standards
|
|
|
|
|
"""
|
|
|
|
|
|
|
|
|
|
def getDraftPrompt(topic, theme):
|
|
|
|
|
prompt = draftPrompt.replace("{{TOPIC}}", topic).replace("{{THEME}}", theme)
|
|
|
|
|
def get_draft_prompt(topic, theme):
|
|
|
|
|
prompt = DRAFT_PROMPT.replace("{{TOPIC}}", topic).replace("{{THEME}}", theme)
|
|
|
|
|
return prompt
|
|
|
|
|
|
|
|
|
|
def getReviewPrompt(article):
|
|
|
|
|
prompt = reviewPrompt.replace("{{ARTICLE}}", article)
|
|
|
|
|
def get_review_prompt(article):
|
|
|
|
|
prompt = REVIEW_PROMPT.replace("{{ARTICLE}}", article)
|
|
|
|
|
return prompt
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
openai = OpenAIChat(openai_api_key="sk-S4xHnFJu7juD33jxjJZfZU1cZYi")
|
|
|
|
|
|
|
|
|
|
draft = openai(get_draft_prompt("AI in healthcare", "Pyschology"))
|
|
|
|
|
review = openai(get_draft_prompt(draft))
|
|
|
|
|
|
|
|
|
|
print(review)
|