import os
import requests
payload = {
"input_prompt": "Create 3 lines only from this paragraph for a small monologue\n",
"messages": [
{"role": "user", "content": "How to do irrigation in a chilli field?"},
{
"role": "assistant",
"content": "Irrigate chilli fields after planting, then based on needs: once a week in hot months and every 10-12 days in cold months. Ensure even water distribution, avoiding excess accumulation, which harms plants. In rainy season, adjust irrigation accordingly. 🌱💧",
},
{
"role": "user",
"content": "Speak about bees and their importance for pollination and therefore existence of humankind",
},
{
"role": "assistant",
"content": "Bees are tiny creatures that play a monumental role in our ecosystem. They are not just producers of honey; they are essential pollinators. Every time a bee visits a flower, it transfers pollen from one bloom to another, facilitating the production of seeds and fruits. This process, known as pollination, is crucial for the growth of many plants and crops that humans rely on for food. Without bees, we would face the loss of a vast array of our favorite foods, such as apples, almonds, and even coffee. 🌼🍯\n\nHowever, the plight of bees is dire. They are facing rapid decline due to pesticides, pollution, and climate change. This decline poses a significant threat not only to biodiversity but also to our food security. If we care about food, nature, and life itself, we must prioritize the protection of bees and their habitats. 🌍💔\n\nIn my work as a forest ecologist in Araku Valley, I see the fragility of these pollinators firsthand. Training communities to safeguard the remaining bee populations is part of my mission to ensure that these vital creatures continue to thrive alongside us. It's a hopeful vision where both real bees and synthetic pollinators, like RoBees, can coexist, ultimately allowing nature to reclaim its throne. 🐝✨",
},
],
}
response = requests.post(
"https://api.gooey.ai/v2/agent?example_id=5j5xrzzcth9h",
headers={
"Authorization": "bearer " + os.environ["GOOEY_API_KEY"],
},
json=payload,
)
assert response.ok, response.content
result = response.json()
print(response.status_code, result)