Giter Club home page Giter Club logo

deep-semantic-similarity-model's Introduction

deep-semantic-similarity-model's People

Contributors

airalcorn2 avatar ofilip avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

deep-semantic-similarity-model's Issues

why neg_l_Ds are derived from pos_l_Ds?

neg_l_Ds = [[] for j in range(J)] for i in range(sample_size): possibilities = list(range(sample_size)) possibilities.remove(i) negatives = np.random.choice(possibilities, J, replace = False) for j in range(J): negative = negatives[j] neg_l_Ds[j].append(pos_l_Ds[negative])
I think negative sample is not the corresponding search result. So why neg_l_Ds are derived from pos_l_Ds?

Example Please?

Hey.. Can an example be provided on how to train the network and then use it for a pair of documents? Thanks!

Shared weights

Hi, I stumbled upon your implementation of dssm and was wondering the following: should the different weights matrices be shared between query and doc?

Does it work for one-hot vector?

Hi! Thank you for making this code! I'm studying CDSSM and trying to import dataset in. I'm new to this so I'm a little confused, so sorry if this question is too easy. If I port data from a dataset, should it be in an array of one-hot vectors?

How to actually view the similarity score in the end?

Hello sir

I have been working on implementing DSSM and CDSSM for a while now. Your code is excellent, easy to understand and the comments help to follow it in perfect sync with the paper.
The entire code is running. However, I wanted to see the value of R_Q_D_p or R_Q_D_ns in the end, and could not to do that. Backend's eval function gives an error, and I am unable to view the actual score inside the tensor.

I would be grateful if you could tell how to view the value/scores.

Once again, I really appreciate your efforts and well-written code!

Datasets

Thanks for this! Your code is readable and properly commented.
Could you recommend any datasets to train this on?

How can the model be trained without sequences being padded?

I have trouble understanding this fitting process:

for i in range(sample_size):
        history = model.fit([l_Qs[i], pos_l_Ds[i]] + [neg_l_Ds[j][i] for j in range(J)], y, epochs = 1, verbose = 0)

where each of the training sample goes through the network only once. I don't think it is applicable.

On the other hand, I don't think using a padded input is applicable, either. It just doesn't match the original method. Could someone give me some advice on how to deal with variable inputs (in the paper)?

Batch of variable length sentence

Hi,

Thank you so much for making this code!

For the variable length input, if I understand you correctly, it just can fit one query by one query instead of fitting all data? So I would like to know, whether there exist some tricks to fit all of the variable length input in one batch?

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.