Tangential question. What do people use for search? What search engines provide the best quality to cost ratios?
Also are there good solutions for searching through a local collection of documents?
replies(2):
Which model(s) are you running (e.g., Ollama, LM Studio, or others) and which open-source coding assistant/integration (for example, a VS Code plugin) you’re using?
What laptop hardware do you have (CPU, GPU/NPU, memory, whether discrete GPU or integrated, OS) and how it performs for your workflow?
What kinds of tasks you use it for (code completion, refactoring, debugging, code review) and how reliable it is (what works well / where it falls short).
I'm conducting my own investigation, which I will be happy to share as well when over.
Thanks! Andrea.
There's also google, which gives you 100 requests a day or something.
Here's the search.py I use
import os
import json
from req import get
# https://programmablesearchengine.google.com/controlpanel/create
GOOGLE_SEARCH_API_KEY = os.getenv('GOOGLE_SEARCH_API_KEY')
GOOGLE_SEARCH_API_ID = os.getenv('GOOGLE_SEARCH_API_ID')
url = "https://customsearch.googleapis.com/customsearch/v1"
def search(query):
data = {
"q": query,
"cx": GOOGLE_SEARCH_API_ID,
"key": GOOGLE_SEARCH_API_KEY,
}
results_json = get(url, data)
results = json.loads(results_json)
results = results["items"]
return results
if __name__ == "__main__":
while True:
query = input('query: ')
results = search(query)
print(results)
and the ddg version from duckduckgo_search import DDGS
def search(query, max_results=8):
results = DDGS().text(query, max_results=max_results)
return results