Why can I not add a whole code repository to a chat, agent, or Knowledge Hub folder?
Understand why full repositories work poorly and learn best practices for working with code files in Odeus.
Why can I not add a whole code repository to a chat, agent, or Knowledge Hub folder?
Understand why full repositories work poorly and learn best practices for working with code files in Odeus.
AI models are not good at processing a whole repository at once. There are a few reasons for this:
-
Context window. Every model has a context window — the maximum amount of text it can process at once — which is often smaller than a full repository. Chats and agents have a limit on the number of attached files, and a repository typically contains far more files than that.
-
Retrieval is section-based. To handle large document sets, the Knowledge Hub splits documents into chunks and a semantic search retrieves only the most relevant sections, which are then sent to the model. For code, it is often important to consider the entire file rather than selected sections, so this retrieval behaviour can miss context that matters.
-
Quality degrades with a fuller context. Even when a repository would fit, answer quality tends to drop as the context window fills up, so a very large repository still produces weaker results.
In practice, the best approach is to work with individual files, smaller sections, or screenshots of the relevant code rather than an entire repository.