decstionback / aaai_2020_commonsenseqa Goto Github PK
View Code? Open in Web Editor NEWCode for "Graph-Based Reasoning over Heterogeneous External Knowledge for Commonsense Question Answering. (published at AAAI 2020)"
License: Apache License 2.0
Code for "Graph-Based Reasoning over Heterogeneous External Knowledge for Commonsense Question Answering. (published at AAAI 2020)"
License: Apache License 2.0
The last line of this file is not in a complete json format. It seems something were dropped by mistake.
excuse me!when I run code,it have a error:
File "./AAAI_2020_CommonsenseQA/pytorch_transformers/tokenization_xlnet.py", line 85, in init
self.sp_model = spm.SentencePieceProcessor()
UnboundLocalError: local variable 'spm' referenced before assignment
Could you help me?Thank you very much!
run.py中convert_examples_to_features方法内部存在下面代码:
node_size=len(temp)-1 matrix=np.zeros((150,150)) for i,val in enumerate(adj_matrix): for j,v in enumerate(adj_matrix[i]): if v==1 and i<50 and j<50 and i<node_size and j<node_size: matrix[i,j]=1
此处将adj_matrix中值为1的位置赋值给了matrix,从所使用的if语句看,这个地方的node_size大小为问题+选项三跳以内路径的数量,此处对于matrix赋值的时候为什么还要使用问题+选项的三跳路径数量来限制matrix,for循环中adj_matrix是和wiki有关的,node_size是和conceptnet有关的,用conceptnet事实的数量限制wiki事实的数量有些许不理解,望得到回复。
Thank you for uploading the code.
Could you please show how you did your data preparation to generate (train.jsonl.concept, train.jsonl.wikigraphnew, train.jsonl_NL)?
@DecstionBack
您好,对wiki数据进行预处理的阶段我有点看不懂,请问:
1.使用 Elastic 搜索引擎 在检索查询和所有句子之间进行排序 ,这个排序方法是什么呀?
2.对wiki数据进行预处理的代码在开源里好像没找到哇,数据直接就是预处理过了的?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.