andylokandy / gpt-4-search Goto Github PK
View Code? Open in Web Editor NEWA command line GPT-4 REPL with Google search in 200 lines of code
License: MIT License
A command line GPT-4 REPL with Google search in 200 lines of code
License: MIT License
Hi, I'm trying to use gpt-3.5-turbo-16k to reduce costs, but I receive the following timeout error.
SEARCH("xxxxxxx")
Traceback (most recent call last):
File "/Users/gabriele/Downloads/LLM/gpt-4-search-main/gpt-4-search.py", line 286, in
run(user_input)
File "/Users/gabriele/Downloads/LLM/gpt-4-search-main/gpt-4-search.py", line 260, in run
result = tool"run"
File "/Users/gabriele/Downloads/LLM/gpt-4-search-main/gpt-4-search.py", line 95, in search
results = GoogleSearchAPIWrapper().results(query, 5)
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/langchain/utilities/google_search.py", line 117, in results
results = self._google_search_results(query, num=num_results)
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/langchain/utilities/google_search.py", line 63, in _google_search_results
res = cse.list(q=search_term, cx=self.google_cse_id, **kwargs).execute()
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/googleapiclient/_helpers.py", line 130, in positional_wrapper
return wrapped(*args, **kwargs)
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/googleapiclient/http.py", line 923, in execute
resp, content = _retry_request(
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/googleapiclient/http.py", line 222, in _retry_request
raise exception
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/googleapiclient/http.py", line 191, in _retry_request
resp, content = http.request(uri, method, *args, **kwargs)
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/httplib2/init.py", line 1724, in request
(response, content) = self._request(
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/httplib2/init.py", line 1444, in _request
(response, content) = self._conn_request(conn, request_uri, method, body, headers)
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/httplib2/init.py", line 1366, in _conn_request
conn.connect()
File "/Users/gabriele/miniforge3/envs/perplexity/lib/python3.10/site-packages/httplib2/init.py", line 1156, in connect
sock.connect((self.host, self.port))
TimeoutError: timed out
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.