Natural language interface to regular search/query?

Hi @Dmitriy_Kruglyak , Thank you for your question. I can provide general guidance on how to go about doing this - You will want to use an LLM like OpenAI GPT-4 or Anthropic Claude and perform Prompt engineering where you will provide sample schema of your db and instruct the model to convert your natural language query to MQL. This will work reasonably well for basic queries and schemas.

To further improve the performance you can leverage RAG using Vector Search could be leverage to provide a few specific examples to the LLM on how to perform the task, but will require you to have a dataset of sample natural language prompts to MQL. (Same requirement of a labeled dataset for fine-tuning one of these models). You can progressively improve the accuracy but this will increase the effort required as well