Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
LLMB-Austin
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Muhammad
LLMB-Austin
Commits
9269ed4f
Commit
9269ed4f
authored
Nov 03, 2023
by
m0hammadjaan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Root
parent
06a33cc8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
6 deletions
+1
-6
2_Chatbot_Agent.py
pages/2_Chatbot_Agent.py
+1
-6
No files found.
pages/2_Chatbot_Agent.py
View file @
9269ed4f
...
...
@@ -5,6 +5,7 @@ from langchain.chat_models import ChatOpenAI
from
langchain.tools
import
DuckDuckGoSearchRun
from
langchain.agents
import
initialize_agent
,
Tool
from
langchain.callbacks
import
StreamlitCallbackHandler
from
langchain.utilities
import
ArxivAPIWrapper
...
...
@@ -22,17 +23,11 @@ class ChatbotTools:
def
setup_agent
(
self
):
# Define tool
ddg_search
=
DuckDuckGoSearchRun
()
arxiv
=
ArxivAPIWrapper
()
tools
=
[
Tool
(
name
=
"DuckDuckGoSearch"
,
func
=
ddg_search
.
run
,
description
=
"Useful for when you need to answer questions about current events. You should ask targeted questions"
,
),
Tool
(
name
=
"Arxiv"
,
func
=
arxiv
.
run
,
description
=
"Useful for when you need to answer questions about research papers, scientific articles, and preprints etc"
,
)
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment