Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -40,7 +40,7 @@ if prompt := st.chat_input():
|
|
| 40 |
|
| 41 |
try:
|
| 42 |
# Check if user wants a search via Tavily
|
| 43 |
-
if "search " in prompt.lower() or "
|
| 44 |
# Use TavilySearchResults tool
|
| 45 |
tavily_response = tavily_tool.run(prompt)
|
| 46 |
|
|
@@ -62,7 +62,7 @@ if prompt := st.chat_input():
|
|
| 62 |
response = openai.chat.completions.create(
|
| 63 |
model="gpt-4o",
|
| 64 |
messages=[
|
| 65 |
-
{"role": "system", "content": "You are a helpful assistant."},
|
| 66 |
*st.session_state["messages"]
|
| 67 |
],
|
| 68 |
max_tokens=150,
|
|
|
|
| 40 |
|
| 41 |
try:
|
| 42 |
# Check if user wants a search via Tavily
|
| 43 |
+
if "search " in prompt.lower() or "trustifier.ai" in prompt.lower():
|
| 44 |
# Use TavilySearchResults tool
|
| 45 |
tavily_response = tavily_tool.run(prompt)
|
| 46 |
|
|
|
|
| 62 |
response = openai.chat.completions.create(
|
| 63 |
model="gpt-4o",
|
| 64 |
messages=[
|
| 65 |
+
{"role": "system", "content": "You are a helpful assistant. search google always "},
|
| 66 |
*st.session_state["messages"]
|
| 67 |
],
|
| 68 |
max_tokens=150,
|