Searching a Yacy database with AI / ChatGPT

Hi,
I wonder if someone has some information about searching a Yacy database with artificial intelligence AI. It could be ChatGPT or some other model.

I did ask Yacy Support GPT and the answer is in this PrivateBin
It doesn’t look easy to do.

If the data is publicly available, I guess one way would be to build a GPT, like Orbiter did with his Yacy Support GPT . It would be nice though, to have a step by step guide available to do this. ChatGPT has provided me with some steps, but it looks somewhat high level (see the output)

Idealy I would use Open Source Tools and my own hardware, but I know that hardware can be expensive. I don’t know how expensive though or in other words what I could do with hardware for a “reasonable” price. But Open Source and own hardware is only nice to have as I suppose it may be hard to do. So any solution would be great, with or without Open source and own hardware.

1 Like

I think @orbiter was actually into this as well:

There were some attempts with Hugging Face, here in the forum:

1 Like

thanks, I`ll have a look into it.
There is a self-hosted cloud app which has a bunch of open source AI tools like llamaGPT, Ollama, openwebUI, Chatbot,

… and it’s quite easy to install and maybe that could make it earier for a open source related solution. It could even support Yacy for a 1-click installation, if someone creates a package for it.

Great!
“Someone” is usually no one, until it’s you. At least here :wink:

miracles happen sometimes :innocent:.
I can’t create packages, so it will not be me.

there are also some basic clients in the source code (ollama & openai), but i don’t know anything specific about them

I think this can already be done. I haven’t tried it but SearXNG supports YaCy and GitHub - ItzCrazyKns/Perplexica: Perplexica is an AI-powered search engine. It is an Open source alternative to Perplexity AI uses SearXNG for search so :slight_smile:

2 Likes

this looks promising.
I was able to install Ollama and Perplexica locally using Docker. That’s not that hard for me since I know a little bit of docker. A SearXNG container is already installed as well. Now I “only” need to configure SearXNG to use my Yacy server.
However, I don’t quite understand how it works. To me it looks like Perplexica sends web requests to Yacy instead of accessing the Yacy db directly. That doesn’t sound very efficient to me, but maybe I haven’t got the concept right from the Perplexica docs.

Anyways, thanks for your hint!

1 Like

To me it looks like Perplexica sends web requests to Yacy instead of accessing the Yacy db directly

That’s how it’s supposed to work. Other software has no knowledge of YaCy internals and it would be maintenance burden to do that way. So YaCy is just regular search provider as any other.

But what I think could be done is implement ability to specify Yacy node support in SearXNG so it would use yours. You can submit feature request to SearXNG or try to implement it yourself.

EDIT: I think it already can be done with search_mode: local and base_url see Yacy — SearXNG Documentation (2025.4.7+b146b745a)

2 Likes

Two weeks ago, Open Web-UI has the release 0.6.6 with YaCy integration: Release v0.6.6 · open-webui/open-webui · GitHub

I also got his message on mastodon: Sigmoid Social

“That means that we can now have selfhosted AI models that learn from the Web … without relying on Google or any central entity at all !”

4 Likes

I was able to add my own yacy servers to SearXNG after creating a engine definition file for my yacy peers.

To preserve formatting here are the changes I added in SearXNG. It was a post to gihub.

Hope that helps.

3 Likes

Thanks, but unfortunately the link doesn’t work for me.

Hi I have updated the link sorry about that.

1 Like

I am actually experimenting with an in-java integrated transformer in YaCy since some weeks. I have not published that yet. It’s quite slow, about 20 tokens/second on a very fast machine, so it will have the status of a proof-of-concept experiment. However other integrations of AI modules like ollama in YaCy to be able to talk with the search index is feasible -a client implementation for ollama is inside YaCy since last year. But it requires front-end modules which are not ready yet.

1 Like