# Architecture

## Pages

- [Build vs. Buy in AI: Your Own Model or an API?](https://www.fernandoux.com/en/wiki/ai/build-vs-buy-models/)
  Build vs. buy in AI is the choice between using a model through an API or hosting it yourself. The API usually wins, unless volume is huge or data is regulated.
- [RAG (Retrieval-Augmented Generation): Answers Grounded in Your Documents](https://www.fernandoux.com/en/wiki/ai/rag/)
  RAG retrieves relevant fragments of your documents and passes them to the model so it answers from them. How it works, when to use it and what can fail.


---

Source: https://www.fernandoux.com/tags/architecture/
