RUCKBReasoning / SubgraphRetrievalKBQA

The pytorch implementation of Subgraph Retrieval Enhanced Model for Multi-hop Knowledge Base Question Answering
93 stars 14 forks source link

Retrieved subgraphs for CWQ #8

Closed cmavro closed 1 year ago

cmavro commented 1 year ago

Hi, very interesting work.

How do I obtain the subgraphs for CWQ, i.e., the tmp/reader_data/cwq folder? It looks like this is not part of the zipped file uploaded in google drive.

lambdaDove commented 1 year ago

Thanks for your attention. We follow the instruction from https://github.com/RichardHGL/WSDM2021_NSM/tree/main/preprocessing/Freebase.
Then we convert the entity name (relalation) from string to integer id.

cmavro commented 1 year ago

I was referring to the subgraphs after path extraction as in this example: https://github.com/RUCKBReasoning/SubgraphRetrievalKBQA/issues/4#issuecomment-1235215817 I was able to find these subgraphs for Webqsp with the uploaded link in https://github.com/RUCKBReasoning/SubgraphRetrievalKBQA/issues/4#issuecomment-1236075450, but not for CWQ. Have you uploaded these subgraphs for CWQ by any chance?

lambdaDove commented 1 year ago

Try this ? https://drive.google.com/drive/folders/1qNauEQJHuMs4uPQcCtMb-M9Seco5mTUl

lambdaDove commented 1 year ago

Inside which, you can get the cache in npy format from this link https://drive.google.com/drive/folders/1ZHSBxGE-vjcvrfkmJPgcXfme_b2Ni6k6?usp=share_link.

cmavro commented 1 year ago

Actually, I am looking for train_simple.json (and so on) files for CWQ that contain the questions as well as the question-specific subgraphs. I found these for Webqsp in that link https://github.com/RUCKBReasoning/SubgraphRetrievalKBQA/issues/4#issuecomment-1236075450 in tmp/reader_data/webqsp folder, but these are not present in the CWQ uploaded folder.

How can I find them? Btw, I am not looking for subgraphs extracted with PPR as in NSM, but the subgraphs extracted with your SR method. We simply want to test our KGQA model with your subgraphs. Thanks!

lambdaDove commented 1 year ago

I upload a new file named "cwq_retrieved_graph_cache.zip" in that link.
Please note that the entity is converted to an integer~ Hope it can help you

cmavro commented 1 year ago

Great, this is what I'm looking for, thanks a lot!