Coder Social home page Coder Social logo

agaralabs / transformer-drg-style-transfer Goto Github PK

View Code? Open in Web Editor NEW
100.0 5.0 28.0 19.44 MB

This repository have scripts and Jupyter-notebooks to perform all the different steps involved in Transforming Delete, Retrieve, Generate Approach for Controlled Text Style Transfer

Home Page: https://www.aclweb.org/anthology/D19-1322.pdf

License: Apache License 2.0

Jupyter Notebook 98.21% JavaScript 0.24% Python 1.55%
nlp deep-learning style-transfer text-style-transfer nlg text-generation

transformer-drg-style-transfer's People

Contributors

akhisud3195 avatar bhargav5 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

transformer-drg-style-transfer's Issues

link for trained model weights for yelp expired

Hi, thanks for your great work! I was using delete and generative from the old paper, and want to have a test with your model. Unfortunately the link you provide for model trained on yelp seems to be expired. Do you have plans to maintain that link, or release the trained model somewhere else?

where is the bleu package from?

Hi, thanks a lot for sharing the code. I noticed that there is bleu package in the "eval_yelp.ipynb" file, however, I do not know where to find or install it. Could you tell us where it is from? Thanks again!

Two questions.

Hello
I have a couple of questions regarding the paper.
① Firstly, the paper mentions that the fasttext model was used to calculate the accuracy. Can you please provide the parameter settings used for training fasttext on the five datasets (yelp, amazon, imagecaption, gender, and political)?
② Secondly, I noticed that the paper states that the size of the gender test is 534k, but the two xlsx files in the results/gender folder only add up to 1k data. I have the same issue with the political dataset. Could you please explain why this is so?
Thank you.

reference files for OpenAI_GPT_Pred

In the OpenAI_GPT_Pred what is the reference file reference_0.txt and reference_1.txt. Wondering if you could add instructions for obtaining them. Thanks so so much :)

In step 4,”the training file generated in the previous step“ is 0 or 1?

Hi, I have already done the first 3 steps. When I in step 4, I should export DG_TRAIN_DATA and DG_EVAL_DATA. I can't understand it is sentiment_train_0.txt or sentiment_train_1.txt. Because in previous steps, it seems that the total train or eval file was not generated.
I'm not sure what I'm missing, I follow the steps. Please help me.

Where can I find "train.csv, dev.csv" ?

Hi,thank for sharing your code.
Can you tell me where is "train.csv, dev.csv" ,which for bert classifier.
Is it the data what I will use? Just put it together and name this?

Error in preditction_with_beam_search function in OpenAI_GPT_Pred notebook

Hey!
I was trying to run the OpenAI_GPT_Pred and I get this error at one of the steps:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-18-2cd4da19970d> in <module>
----> 1 op=preditction_with_beam_search("<POS> <CON_START> it is not terrible , but it is very good . <START>",4)
      2 op

<ipython-input-16-115b14581f7e> in preditction_with_beam_search(ref_text, beam_width, vocab_length)
     66             temp_lt=[0 for i in range(beam_width)]
     67             for i,x in enumerate(best_scoes_inx):
---> 68                 temp_lt[i] = beam_indexes[x] + [correct_inx[i]]
     69             # Update the Beam indexes
     70             beam_indexes = temp_lt

TypeError: list indices must be integers or slices, not float

I tried printing and x seems to be a float and not an int. I don't get why this is happening any clues?

Bert_classifier_Model not found

Hi, Thank you for sharing your code.
I have difficulty running BERT_DATA_PREPARATION.

After running BERT_Classification_Training, I tried to run BERT_DATA_PREPARATION. However I don't have the bert_classifier_model which is in bert_classifier_model_dir so i got following error :

'Model name './bert_classifier/' was not found in model name list (bert-base-uncased, bert-large-uncased, bert-base-cased, bert-large-cased, bert-base-multilingual-uncased, bert-base-multilingual-cased, bert-base-chinese). We assumed './bert_classifier/' was a path or url but couldn't find any file associated to this path or url.'

I appreciate it If you could help me.
Thanks.

Missing sentiment_test.txt file

While running Delete_Retrieve_Generate_Data_Preparation I notice that there is no such file as sentiment_test.txt in the processed_files_with_bert_with_best_head folder and I'm not sure which step generates it as I tried searching and couldn't find anything. What could be going wrong?

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.