SPIKE Proposal: Code Suggestion to use Zoekt as RAG
Problem to solve
We want to improve Code Suggestion quality. Enriching the LLM context could be one of the avenues.
Proposal
I believe that by using Zoekt (exact code search) we should be able to improve the code suggestion quality.
Note: The feature is in Beta, but we've already indexed over 80% of paid namespaces on .com.
For example, LLM can generate a regexp or we can use an exact match term to find where the function is used and add this to the code suggestion prompt. We can perform group- or project-level searches.
Also, soon groupglobal search is going to enable ctags for Zoekt, which should add additional opportunities in terms of finding relevant functions/variables.
This is a basic example: https://gitlab.com/search?search=def+model_gateway_headers&nav_source=navbar&project_id=278964&group_id=9970&search_code=true®ex=false
This search took 91ms
cc @maddievn @bvenker @pwietchner @susie.bee @changzhengliu @mnohr @derekferguson
