cpacker / MemGPT

Create LLM agents with long-term memory and custom tools 📚🦙
https://memgpt.readme.io
Apache License 2.0
10.76k stars 1.16k forks source link

Better default web search function #786

Open cpacker opened 6 months ago

cpacker commented 6 months ago

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

We should keep http_request in for API uses, but it should be delegated to APIs and not used for general web browsing.

Can take inspiration from:

agiletechnologist commented 6 months ago

There are some considerations about search engine terms of service. Google and Bing specifically have APIs and associated costs. Accessing Bing or Google with a program requires using the API. This would be Ideal for MemGPT to use.

There are Free Tiers for both Google and Bing. This is good for occasional use, but for serious usage, you can need to pay. You will also need a way to add API Keys for the Search.

Google API Info: https://developers.google.com/custom-search/v1/overview Google API Pricing: https://support.google.com/programmable-search/answer/9069107?hl=en

Bing API Info: https://www.microsoft.com/en-us/bing/apis/bing-web-search-api Bing API Pricing: https://www.microsoft.com/en-us/bing/apis/pricing

TheOnlyWiseJEDI commented 6 months ago

You might build off of my google api function (search_api) in my repository, it is configured for google custom search and can be expanded. I had adjusted things to limit the amount of info returned in the name of context window savings. Also, the free tier for google search allows a lot of free searches per month. Just going off memory I'm thinking I read 100,000? idk it was awhile ago but when I saw it I know I said to myself, no way I'm hitting that limit.