Skip to main content

VectorCode

codecov Test and Coverage pypi

VectorCode is a code repository indexing tool. It helps you build better prompt for your coding LLMs by indexing and providing information about the code repository you're working on. This repository also contains the corresponding neovim plugin that provides a set of APIs for you to build or enhance AI plugins, and integrations for some of the popular plugins.

[!NOTE] This project is in beta quality and is undergoing rapid iterations. I know there are plenty of rooms for improvements, and any help is welcomed.

Why VectorCode?

LLMs usually have very limited understanding about close-source projects, projects that are not well-known, and cutting edge developments that have not made it into releases. Their capabilities on these projects are quite limited. With VectorCode, you can easily (and programmatically) inject task-relevant context from the project into the prompt. This significantly improves the quality of the model output and reduce hallucination.

asciicast

Documentation

[!NOTE] The documentation on the main branch reflects the code on the latest commit. To check for the documentation for the version you're using, you can check out the corresponding tags.

  • For the setup and usage of the command-line tool, see the CLI documentation;
  • For neovim users, after you've gone through the CLI documentation, please refer to the neovim plugin documentation (and optionally the lua API reference) for further instructions.
  • Additional resources:
    • the wiki for extra tricks and tips that will help you get the most out of VectorCode;
    • the discussions where you can ask general questions and share your cool usages about VectorCode.
    • If you're feeling adanvturous, feel free to check out the pull requests for WIP features.

If you're trying to contribute to this project, take a look at the contribution guide, which contains information about some basic guidelines that you should follow and tips that you may find helpful.

About Versioning

This project follows an adapted semantic versioning:

  • Until 1.0.0 is released, the major version number stays 0 which indicates that this project is still in early stage, and features/interfaces may change from time to time;
  • The minor version number indicates breaking changes. When I decide to remove a feature/config option, the actual removal will happen when I bump the minor version number. Therefore, if you want to avoid breaking a working setup, you may choose to use a version constraint like "vectorcode<0.7.0";
  • The patch version number indicates non-breaking changes. This can include new features and bug fixes. When I decide to deprecate things, I will make a new release with bumped patch version. Until the minor version number is bumped, the deprecated feature will still work but you'll see a warning. It's recommended to update your setup to adapt the new features.

TODOs

  • query by file path excluded paths;
  • chunking support;
    • add metadata for files;
    • chunk-size configuration;
    • smarter chunking (semantics/syntax based), implemented with py-tree-sitter and tree-sitter-language-pack;
    • configurable document selection from query results.
  • NeoVim Lua API with cache to skip the retrieval when a project has not been indexed Returns empty array instead;
  • job pool for async caching;
  • persistent-client;
  • proper remote Chromadb support (with authentication, etc.);
  • respect .gitignore;
  • implement some sort of project-root anchors (such as .git or a custom .vectorcode.json) that enhances automatic project-root detection. Implemented project-level .vectorcode/ and .git as root anchor
  • ability to view and delete files in a collection;
  • joint search (kinda, using codecompanion.nvim/MCP);
  • Nix support (unofficial packages here);
  • Query rewriting (#124).

Credit

Special Thanks

JetBrains logo.

Star History

Star History Chart

Release files for VectorCode 0.7.20

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for VectorCode 0.7.20
File Size Uploaded
vectorcode-0.7.20.tar.gz 71.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for VectorCode 0.7.20
File Interpreter ABI Platform
vectorcode-0.7.20-py3-none-any.whl Python 3 none any Details

Total release size: 121.4 kB

Release files / vectorcode-0.7.20.tar.gz

Download URL vectorcode-0.7.20.tar.gz
Size 71.7 kB
Tags Source
SHA-256 checksum
How to use checksums
476328e5b5a2488dd349281b50b27e3abfdd059f85242f79e418a0fda492f74a
BLAKE2b-256 checksum
How to use checksums
abd2db099b0ae839d9fad386bdc895ff2d0777d67fcd5bd375f9fb9400ede934
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via pdm/2.26.2 CPython/3.13.11 Linux/6.11.0-1018-azure

Release files / vectorcode-0.7.20-py3-none-any.whl

Download URL vectorcode-0.7.20-py3-none-any.whl
Size 49.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f91e20dbe172f5f1b90e6bb050c8f79049ab16ab1d2f65967803b46fa97d93de
BLAKE2b-256 checksum
How to use checksums
213a2085da5ba8c4df99c3686faa9c9714c8b4c8247db7f69932a7ecfab8d9da
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via pdm/2.26.2 CPython/3.13.11 Linux/6.11.0-1018-azure

Release history Release notifications | RSS feed

This release

0.7.20 This release

2 release files

0.7.19

2 release files

0.7.18

2 release files

0.7.17

2 release files

0.7.15

2 release files

0.7.14

2 release files

0.7.13

2 release files

0.7.11

2 release files

0.7.10

2 release files

0.7.9

2 release files

0.7.8

2 release files

0.7.7

2 release files

0.7.6

2 release files

0.7.5

2 release files

0.7.4

2 release files

0.7.3

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.13

2 release files

0.6.12

2 release files

0.6.10

2 release files

0.6.9

2 release files

0.6.8

2 release files

0.6.7

2 release files

0.6.6

2 release files

0.6.5

2 release files

0.6.4

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.9

2 release files

0.5.8

2 release files

0.5.7

2 release files

0.5.6

2 release files

0.5.5

2 release files

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.15

2 release files

0.4.14

2 release files

0.4.13

2 release files

0.4.12

2 release files

0.4.11

2 release files

0.4.10

2 release files

0.4.9

2 release files

0.4.8

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.11

2 release files

0.3.10

2 release files

0.3.9

2 release files

0.3.8

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page