An open framework for factual LLMs: extraction, editing, and tuning
It builds bilingual LLMs that extract structured knowledge, detect hallucinations, and edit their own facts.

What it does
KnowLM is a research framework for training and tuning “knowledgeable” large language models. It bundles data processing, pre-training, fine-tuning, and inference with a focus on knowledge extraction and reasoning. The project also maintains a model zoo—built mostly on LLaMA and LLaMA 2—that includes specialized variants like the information-extraction model OneKE and the ocean-science model OceanGPT.
The interesting bit
Rather than treating knowledge as prompt context, KnowLM bakes it into the lifecycle: it generates prompts from structured knowledge graphs, runs hallucination detection through EasyDetect, and can surgically edit outdated facts with EasyEdit. That makes it less a single model and more a full-stack research pipeline for keeping LLMs factually aligned.
Key highlights
- Bilingual support (Chinese and English) across models and instruction datasets.
- A model zoo with task-specific variants:
ZhiXifor dialogue,OneKEfor information extraction, andOceanGPTfor ocean science. - Tight integration with satellite tools:
EasyInstructfor instruction processing,EasyEditfor knowledge editing, andEasyDetectfor hallucination detection. - Open weights and datasets hosted on HuggingFace, including the 2-million-sample
IEPileextraction dataset. - LoRA-based fine-tuning on top of base models, with merged weights available for download.
Caveats
- The RAG-based knowledge augmentation module is still under development.
- The authors warn that the project is actively evolving and model weights will change regularly.
- Some bundled datasets, like
InstructIE, carry noise from distant supervision.
Verdict
Researchers and practitioners working on Chinese-English knowledge extraction or LLM fact-correction should look here; developers seeking a stable, production-ready API should wait for the paint to dry.
Frequently asked
- What is zjunlp/KnowLM?
- It builds bilingual LLMs that extract structured knowledge, detect hallucinations, and edit their own facts.
- Is KnowLM open source?
- Yes — zjunlp/KnowLM is open source, released under the MIT license.
- What language is KnowLM written in?
- zjunlp/KnowLM is primarily written in Python.
- How popular is KnowLM?
- zjunlp/KnowLM has 1.4k stars on GitHub.
- Where can I find KnowLM?
- zjunlp/KnowLM is on GitHub at https://github.com/zjunlp/KnowLM.