Dependencies are not in context

Question: Using pycharm and pipenv I cannot add dependencies to the context, so the context is useless and suggestions random. Pycharm knows which files belong to the project and indexes them correctly

We’ve taken a look at supporting adding dependencies to context and at a high level, there are three options:

  1. Use the dependency context that PyCharm has. Unfortunately, this is easy in theory, but in practice, the PyCharm editor API lacks an officially supported way of retrieving this for plugins, even though it is available through the UI.
  2. Connect Cody to Sourcegraph and enable users to tag repositories, including repositories that contain the source code of dependencies, as context. We already support this for enterprise Sourcegraph instances.
  3. Index PyPI in Sourcegraph and allow users to tag PyPI packages directly (rather than tagging the git repository which contains the source code)

Currently, 2 seems the likeliest path and I think we’ll be shipping this in the next couple of months for Pro users.

And this clearly requires a (fuzzy or not) text search on the repo. And it seems to have done semantic search over the files/file names.

Yep, fuzzy search is part of Cody’s code context engine. We’re actively investing in improving this to better handle specific use cases. If you see an example where the context falls short, please let us know!

via @beyang