Skip to main content

A modular pipeline for knowledge acquisition

Project description

[!NOTE] This repository is currently under active development. Major updates are planned soon, including changes to APIs, component interfaces, model loading, and datasets. The current implementation should be considered unstable until the update is complete.

KAPipe

KAPipe is a modular framework for building Knowledge Acquisition Systems from unstructured data.

KAPipe decomposes knowledge acquisition into four main stages:

  1. Extraction: extracting knowledge units from unstructured data.
  2. Organization: organizing extracted knowledge units into structured representations such as knowledge graph.
  3. Retrieval: retrieving relevant knowledge for a given query or task.
  4. Utilization: using retrieved structured knowledge for downstream tasks such as question answering.

An overview of knowledge acquisition system

KAPipe is used in the following papers:

An example of graph-based RAG architecture

Installation

python -m pip install -U kapipe

For local development:

git clone https://github.com/norikinishida/kapipe.git
cd kapipe
python -m pip install -e .

Some pretrained models and configuration files are distributed separately.

mkdir -p ~/.kapipe
mv release.YYYYMMDD.tar.gz ~/.kapipe
cd ~/.kapipe
tar -zxvf release.YYYYMMDD.tar.gz

Release files are available here:

KAPipe Release Files

Components

In KAPipe, a component is a modular processing unit that implements a specific approach within one of the four stages: extraction, organization, retrieval, or utilization.

The following table summarizes the components currently supported by KAPipe.

Stage Component Module Docs Example
Extraction Named Entity Recognition kapipe.ner Docs Example
Extraction Entity Disambiguation (Retrieval) kapipe.ed_retrieval Docs Example
Extraction Entity Disambiguation (Reranking) kapipe.ed_reranking Docs Example
Extraction Document-level Relation Extraction kapipe.docre Docs Example
Organization Entity Graph Construction kapipe.entity_graph_construction Docs Example
Organization Community Clustering kapipe.community_clustering Docs Example
Organization Report Generation kapipe.report_generation Docs Example
Organization Chunking kapipe.chunking Docs Example
Retrieval Passage Retrieval kapipe.passage_retrieval Docs Example
Utilization Question Answering kapipe.qa Docs Example

Quickstart

TBA.

Citation / Publication

If KAPipe is helpful for your work, please consider citing the following paper:

Dissecting GraphRAG: A Modular Analysis of Knowledge Structuring for Factoid Question Answering. Noriki Nishida, Rumana Ferdous Munne, Shanshan Liu, Narumi Tokunaga, Yuki Yamagata, Fei Cheng, Kouji Kozaki, and Yuji Matsumoto. Transactions of the Association for Computational Linguistics (TACL), vol. 14, pp. 627-655. 2026. (Presented at ACL 2026)

@article{nishida-etal-2026-dissecting,
    title = "Dissecting {G}raph{RAG}: A Modular Analysis of Knowledge Structuring for Factoid Question Answering",
    author = "Nishida, Noriki  and
      Munne, Rumana Ferdous  and
      Liu, Shanshan  and
      Tokunaga, Narumi  and
      Yamagata, Yuki  and
      Cheng, Fei  and
      Kozaki, Kouji  and
      Matsumoto, Yuji",
    journal = "Transactions of the Association for Computational Linguistics",
    volume = "14",
    year = "2026",
    address = "Cambridge, MA",
    publisher = "MIT Press",
    url = "https://aclanthology.org/2026.tacl-1.29/",
    doi = "10.1162/tacl.a.615",
    pages = "627--655"
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kapipe-0.1.3.tar.gz (152.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kapipe-0.1.3-py3-none-any.whl (194.9 kB view details)

Uploaded Python 3

File details

Details for the file kapipe-0.1.3.tar.gz.

File metadata

  • Download URL: kapipe-0.1.3.tar.gz
  • Upload date:
  • Size: 152.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.14

File hashes

Hashes for kapipe-0.1.3.tar.gz
Algorithm Hash digest
SHA256 ebd59a9476c65f310db2ac46610c18ff782293f4970e060352224270a91b1039
MD5 c4262d1669a6474a4c00bbbc94ffe2de
BLAKE2b-256 e03c57e50981ceb59cd72b490197f7c6b48d9389b21102823b1bc069758f54a9

See more details on using hashes here.

File details

Details for the file kapipe-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: kapipe-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 194.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.14

File hashes

Hashes for kapipe-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 36c96e87e01821bdfce368ad48c90c6c47f73ddf82165d80024895e86be39c20
MD5 cb695675dcf80900d0a2e5bcb2d3e3a3
BLAKE2b-256 3c906cc044f5c2fa84ff3b3ed8cf4ff644aef494ffc1fe8838a815444736c1e9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page