Collaborative Adversarial Networks
This library provides a framework for creating a topological knowledge graph to assess and improve the confidence of Large Language Model (LLM) responses. It uses a smaller LLM (like Phi-3) with Retrieval-Augmented Generation (RAG) connected to a search engine to build a knowledge graph, and then grades a larger LLM's knowledge to model its understanding and predict potential hallucinations.
- Create a dynamic knowledge graph based on topics and their relationships
- Utilize a smaller LLM with RAG for building the knowledge graph
- Grade a larger LLM's knowledge on specific topics
- Predict hallucination risks in LLM responses
- Provide confidence scores and hallucination risk assessments for queries
- Python 3.7+
- NetworkX
- PyTorch
- Transformers
- Requests
...