Incorporating an Organization's Knowledge into an AI

Exploring two options to integrate an organization's knowledge into an AI: Botpress and a RAG system with Milvus and Gradio.

Incorporating an organization's knowledge into an AI

Incorporating an organization's knowledge into an AINot long ago, I came across an interesting challenge: incorporating an organization's knowledge into an AI to improve processes and optimize information access. One of those tasks that, at first glance, seems straightforward, but actually hides quite a few complexities.

On this journey, I've explored two different approaches:

1. Using Botpress

Botpress (https://botpress.com/) is an open-source platform for creating chatbots. It has powerful orchestration tools and a visual interface that makes development easier. It also allows you to connect to different data sources and integrate with external services.

Advantages:

  • Easy to deploy and configure
  • Good graphical interface
  • Native integrations with various platforms

Disadvantages:

  • Knowledge management is limited and heavily depends on predefined rules
  • No advanced information retrieval based on embeddings
  • Can be restrictive if you want a more flexible solution

2. Building a RAG with Milvus and Gradio

The other option was to build a Retrieval-Augmented Generation (RAG) system. For those who are not familiar with the concept, a RAG combines two phases:

1. Information retrieval using a vector database (in this case, Milvus) to find the most relevant documents.

2. Answer generation using a language model, enriching them with the retrieved knowledge.

For the user interface, I used Gradio, which allows you to create quick and functional interaction prototypes.

Advantages:

  • Much more flexible: the AI can adapt to new data easily
  • Semantic retrieval of information, avoiding the rigidity of conventional bots
  • Scalability: you can expand the knowledge base without major difficulties

Disadvantages:

  • Requires more work for deployment and configuration
  • Needs constant maintenance to adjust embeddings and responses

The final decision

After trying both options, I opted for the second one. The flexibility and power of a RAG surpass the limitations of a rule-based solution like Botpress. In the long run, the adaptability of the AI is key, especially when it comes to integrating an organization's dynamic knowledge.

Still, I'm sure there are other interesting approaches out there. Has anyone tried different alternatives? Which tools have worked best for you? I'm open to hearing experiences and suggestions!

Oleguer Serra - March 2025