| --- |
| task_categories: |
| - question-answering |
| language: |
| - en |
| tags: |
| - wikidata |
| - freebase |
| - KBQA |
| - LLM |
| - agent |
| pretty_name: KG Subgraph |
| size_categories: |
| - 10K<n<100K |
| --- |
| # Subgraph Dataset |
|
|
| ## Overview |
|
|
| This repository contains a subgraph dataset associated with the subgraphs used in the paper [ODA: Observation-Driven Agent for integrating LLMs and Knowledge Graphs](https://arxiv.org/abs/2404.07677). |
|
|
| For specific codes and the KBQA dataset, please refer to [KGdata repository](https://github.com/lanjiuqing64/KGdata.git). |
|
|
| ## Description |
|
|
| The dataset comprises four folders, each containing subgraphs related to different KBQA datasets based on Wikidata or Freebase: |
| - Wikidata-based datasets: |
| - QALD10-en |
| - T-REx |
| - Zero-Shot RE |
| - Creak |
| |
| - Freebase-based datasets: |
| - GrailQA |
| - WebQSP |
| - Simple Questions |
|
|
| - `hop_2_FreeBase/`: Contains 2-hop subgraphs based on Freebase. |
| - `hop_3_FreeBase/`: Contains 3-hop subgraphs based on Freebase. |
| - `hop_2_Wikidata/`: Contains 2-hop subgraphs based on Wikidata. |
| - `hop_3rd_Wikidata/`: Contains the third hop subgraphs based on Wikidata. |
|
|
|
|
| |
| ### The format of the subgraph files |
| 1. FreeBase subgraph file |
| ``` |
| { |
| Topic Entity : [[EntityID,Relation,EntityID],....], |
| Topic Entity : [[EntityID,Relation,EntityID],....], |
| ... |
| } |
| ``` |
| 2. FreeBase label file |
| ``` |
| { |
| EntityID : Entity name |
| EntityID : Entity name |
| ... |
| } |
| ``` |
|
|
| 3. Wikidata subgraph file |
| ``` |
| { |
| Topic Entity : [[EntityID,RelationID,EntityID],....], |
| Topic Entity : [[EntityID,RelationID,EntityID],....], |
| ... |
| } |
| ``` |
| 2. Wikidata label file |
|
|
| ``` |
| { |
| EntityID : Entity name |
| RelationID : Relation name |
| EntityID : Entity name |
| ... |
| } |
| ``` |
|
|
|
|
|
|
|
|