GithubHelp home page GithubHelp logo

cindycandy / qa-deep-learning Goto Github PK

View Code? Open in Web Editor NEW

This project forked from white127/qa-deep-learning

0.0 0.0 0.0 14.11 MB

tensorflow and theano cnn code for insurance QA(question Answer matching)

Python 100.00%

qa-deep-learning's Introduction

Insurance-QA deeplearning model

This is a repo for Q&A Mathing, includes some deep learning models, such as CNN、RNN.

  1. CNN. Basic CNN model from 《Applying Deep Learning To Answer Selection: A Study And An Open Task》
  2. RNN. RNN seems the best model on Insurance-QA dataset.
  3. SWEM. SWEM is the fastest, and has good effect on other datasets, such as WikiQA ..., but is seems not so good on Insurance-QA dataset. I think that, SWEM is more suitable for Q&Q matching, not Q&A matching.

It's hard to say which model is the best in other datasets, you have to choose the most suitable model for you.

More models are on the way, pay attention to the updates.

Requirements

  1. tensorflow 1.4.0
  2. python3.5

Performance

margin loss version

Model/Score Ins_qa_top1_precision quora_best_prec
CNN 62% None
LSTM+CNN 68% None
SWEM <55% None

logloss version

Model/Score Insqa_top1_precision quora_best_prec
CNN None 79.60%
LSTM+CNN None None
SWEM <40% 82.69%

Running

Change configuration to your own environment, just like data pathes

vim config.py

Data processing

python3 gen.py

Run CNN model

cd ./cnn/tensorflow && python3 insqa_train.py

It will take few hours(thousands of epoches) to train this model on a single GPU.

Downloads

  1. You can get Insurance-QA data from here https://github.com/shuzi/insuranceQA
  2. You can get Quora data from here http://qim.ec.quoracdn.net/quora_duplicate_questions.tsv

Links

  1. CNN and RNN textual classification repo https://github.com/white127/TextClassification_CNN_RNN
  2. 《Applying Deep Learning To Answer Selection: A Study And An Open Task》

qa-deep-learning's People

Contributors

white127 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.