Manasa1 commited on
Commit
342d630
·
verified ·
1 Parent(s): e3c00cd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -11,13 +11,13 @@ load_dotenv()
11
 
12
  # Create the Agent with enhanced instructions for more natural writing
13
  agent = Agent(
14
- model=Groq(id="llama3-70b-8192", api_key=os.getenv("GROQ_API_KEY")),
15
  tools=[DuckDuckGo(), Newspaper4k()],
16
  description="You are an experienced writer who's spent years developing your unique voice. You write like a close friend sharing fascinating discoveries - someone who's deeply curious, occasionally funny, and always authentic. Your writing feels like a personal letter, not a formal article.",
17
  instructions=[
18
  "For the provided topic, run 10 different searches. Read the results carefully and you need to prepare an article for Medium",
19
 
20
- " You need to write this article in depth . The Article should contain at least 1500 words"
21
 
22
  "Write like you're telling a story to a friend. Be messy, be human. Let your personality shine through. Break writing rules when it serves the story.",
23
 
@@ -62,7 +62,8 @@ def main():
62
  response = agent.run(
63
  f"Write a naturally flowing article about: {topic}\n\n"
64
  "Remember:\n"
65
- "- Write like you're sharing fascinating discoveries with a friend\n"
 
66
  "- Include why you found it interesting\n"
67
  "- Add natural digressions and personality quirks\n"
68
  "- Share genuine reactions and thoughts\n"
 
11
 
12
  # Create the Agent with enhanced instructions for more natural writing
13
  agent = Agent(
14
+ model=Groq(id="llama-3.1-8b-instant", api_key=os.getenv("GROQ_API_KEY")),
15
  tools=[DuckDuckGo(), Newspaper4k()],
16
  description="You are an experienced writer who's spent years developing your unique voice. You write like a close friend sharing fascinating discoveries - someone who's deeply curious, occasionally funny, and always authentic. Your writing feels like a personal letter, not a formal article.",
17
  instructions=[
18
  "For the provided topic, run 10 different searches. Read the results carefully and you need to prepare an article for Medium",
19
 
20
+ " You need to write this article in depth. The Article should contain at least 1500 words; if you add more words, do it. The longer the article better it is. but don't repeat the same thing",
21
 
22
  "Write like you're telling a story to a friend. Be messy, be human. Let your personality shine through. Break writing rules when it serves the story.",
23
 
 
62
  response = agent.run(
63
  f"Write a naturally flowing article about: {topic}\n\n"
64
  "Remember:\n"
65
+ "- Write like you're sharing fascinating discoveries with a 5 year old child\n"
66
+ " - The article should be at least 1500 words long"
67
  "- Include why you found it interesting\n"
68
  "- Add natural digressions and personality quirks\n"
69
  "- Share genuine reactions and thoughts\n"