Chandranshu Jain
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from langchain.tools import DuckDuckGoSearchRun
|
| 2 |
+
from crewai_tools import tool
|
| 3 |
+
@tool('DuckDuckGoSearch')
|
| 4 |
+
def search(search_query:str):
|
| 5 |
+
"""Search the web for the topic"""
|
| 6 |
+
return DuckDuckGoSearchRun().run(search_query)
|
| 7 |
+
import os
|
| 8 |
+
from crewai import Agent,Task,Crew,Process
|
| 9 |
+
import google.generativeai as genai
|
| 10 |
+
from langchain_google_genai import ChatGoogleGenerativeAI
|
| 11 |
+
llm=ChatGoogleGenerativeAI(model="gemini-pro",
|
| 12 |
+
verbose = True,
|
| 13 |
+
temperature = 0.2,
|
| 14 |
+
google_api_key=userdata.get('GOOGLE_API_KEY'))
|