In a previous posted I introduced you to Continue in combination with Ollama, as a way to run a fully local AI Code Assistant.
Remark: This post is part of a bigger series. Here are the other related posts:
- Part 1 – Introduction
- Part 2 - Configuration
- Part 3 – Editing and Actions
- Part 4 - Learning from your codebase
- Part 5 (this post) – Read your documentation
Today I want to continue by having a look at how Continue can scrape your documentation website and make the content accessible inside your IDE
The @docs context provider
To use this feature you need to use the @docs
context provider:
Once you type @docs
you already get a long list of available documentation:
If you now ask a question, the indexed documentation is used to answer your question:
You can see the context used by expanding the context items section:
Index your own documentation site
The nice thing is that you are not limited to the pre-indexed documentation sites but that you can add your own documentation sources. The easiest way to do this is by typing @docs
again and choose the + Add docs option at the bottom of the list:
Now we need to choose a title, specify the main url of the documentation site and an optional Favicon url:
Hit submit to start the indexing process. This can take some time depending on the amount of data on the website.
Remark: I noticed a few times that the first indexing attempt failed, but that a second try does succeed. So certainly give it a second try. If it still fails, I’ll give you some troubleshooting tips in my next post.
Now we can use this indexed site in the same way as the pre-indexed sites:
Although this looks promising, the usage in a business context is rather limited. This is because of documentation sites in enterprises are typically stored in a secured source where a login is required. The web crawler used can only index content that doesn’t require a login.
Maybe that is something that will change in the future?