Cody can't find content of embedded repo

Scenario

A Cody user has configured their VsCode extension, they have run their target repository through the embeddings process, and the target repository shows as INDEXED in the VsCode UI. However, when the user asks Cody about the Repo, Cody is unable to answer questions about specific files or file contents. 

 

Troubleshooting Steps

  1. Confirm all setup steps have been completed properly: 
  2.  Check the Cody: Debug Output for errors: 
    • Enable Cody > Debug and Cody > Debug:Verbose in the VsCode Settings
      Screenshot
    • In the command palette, Reload Window
    • In the command palette, turn on the View: Toggle Output  
      Screenshot
    • Set the Output to Cody AI by Sourcegraph
      Screenshot
    • With the Output open, ask Cody about the Repo/file in question and check the output for any clues/errors. 
      ScreenshotNote: This output is a bit difficult to read. To make it easier, copy and paste the output into a JSON file and have VsCode format it for you. 

  3. Check the logs:
    • The embeddings jobs run on worker, so you should be able to find them in the logs for that service. You can search for the finished generating repo embeddings string.

      When this article was written, engineering is actively working on putting embeddings job info into the database and surfacing helpful information on the embeddings jobs in the admin UI.  

 

Possible Explanations

If all the configuration/setup steps have been done properly, and Cody still has trouble finding contents within the repo, this may indicate that some files have been skipped during the embedding process. 

Reasons a file may have been skipped during embedding

  1. The file was larger than 1 MB 
  2. The file matched a specific pattern
  3. The file was, or appears to be, autogenerated 




Was this article helpful?
0 out of 0 found this helpful

Articles in this section