# Design exercise: Repository Intelligence

> Structure, symbols, history, ownership, conventions, architecture, semantic search, and change-aware retrieval. Implement designOutline() returning non-empty values for: index, retrieval, contextAssembly. Each value must name a concrete mechanism or decision.

Canonical: https://learn.significanthobbies.com/curriculum/drills/practice-repository-intelligence

Structure, symbols, history, ownership, conventions, architecture, semantic search, and change-aware retrieval. Implement designOutline() returning non-empty values for: index, retrieval, contextAssembly. Each value must name a concrete mechanism or decision.

## The mechanism

Repository intelligence answers what exists, why it exists, who depends on it, and what changed. It combines indexed code, graphs, history, and local instructions.

## Expected evidence

A design outline with index, retrieval, contextAssembly plus an explicit failure mode or trade-off.

## Hints

- Name the failure mode before selecting the mechanism.

## Sources and practice

- [GitHub Code Search Syntax](https://docs.github.com/en/search-github/github-code-search/understanding-github-code-search-syntax)
- [Software Engineering at Google — Ch. 17: Code Search](https://abseil.io/resources/swe-book/html/ch17.html)
- [Regular Expression Matching with a Trigram Index (Russ Cox)](https://swtch.com/~rsc/regexp/regexp4.html)
- [The technology behind GitHub's new code search (Blackbird)](https://github.blog/engineering/the-technology-behind-githubs-new-code-search/)
- [CodeSearchNet Challenge: Evaluating Semantic Code Search](https://arxiv.org/abs/1909.09436)
- [Study Repository Intelligence](https://learn.significanthobbies.com/curriculum/concepts/repository-intelligence)
- [Try the interactive drill](https://learn.significanthobbies.com/drills/practice-repository-intelligence)
- [All practice briefs](https://learn.significanthobbies.com/curriculum/drills/)
