<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Aseem Srivastava on Medium]]></title>
        <description><![CDATA[Stories by Aseem Srivastava on Medium]]></description>
        <link>https://medium.com/@as3eem?source=rss-892b27730f23------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*-42tCx-90PM2cBKrie3U0A.png</url>
            <title>Stories by Aseem Srivastava on Medium</title>
            <link>https://medium.com/@as3eem?source=rss-892b27730f23------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 18:32:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@as3eem/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[5 Must-Know Mental Health Datasets for AI Research | August 2023]]></title>
            <link>https://as3eem.medium.com/5-must-know-mental-health-counseling-datasets-for-ai-research-dd1a1b9f30b4?source=rss-892b27730f23------2</link>
            <guid isPermaLink="false">https://medium.com/p/dd1a1b9f30b4</guid>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[mental-health]]></category>
            <dc:creator><![CDATA[Aseem Srivastava]]></dc:creator>
            <pubDate>Tue, 06 Jun 2023 14:55:31 GMT</pubDate>
            <atom:updated>2023-08-12T08:30:24.280Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*6oTGzVpwOc_Re3yB" /><figcaption>(Photo by <a href="https://unsplash.com/@benwhitephotography?utm_source=medium&amp;utm_medium=referral">Ben White</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a>)</figcaption></figure><p>I am a research scholar, and my research has revolved around <em>AI for Mental Health Counseling</em> for the last three years. I have published some papers at notable AI/NLP conferences. During my research engagement, I encountered the profound challenge of finding suitable datasets to advance my work. However, within this scarcity lies an opportunity to inspire change and collaborate toward constructing a brighter future for mental health support. <strong>In this blog, we embark on a quest to shed light on available datasets, both public and obtainable through request, paving the way for pioneering advancements in AI-powered mental health care.</strong></p><h4><strong>HOPE Dataset</strong></h4><p>HOPE contains 202 dyadic counseling conversation transcripts. Each utterance is tagged with a dialogue-act. This dataset is best suited to design many NLP tasks (apart from dialogue-act classification) for mental health care. (<a href="https://dl.acm.org/doi/10.1145/3488560.3498509">read more</a>)<br><strong>[ Access is available on request </strong><a href="https://github.com/LCS2-IIITD/SPARTA_WSDM2022/tree/main#hope-dataset-access-request"><strong>here</strong></a><strong> ]</strong></p><p><a href="https://github.com/LCS2-IIITD/SPARTA_WSDM2022/tree/main#hope-dataset-access-request">GitHub - LCS2-IIITD/SPARTA_WSDM2022: This repository contains the code and dataset for our paper titled Speaker and Time-aware Joint Contextual Learning for Dialogue-act Classification in Counselling Conversations accepted at WSDM Conference, 2022.</a></p><h4><strong>MEMO Dataset</strong></h4><p>MEMO contains counseling session transcripts and their counseling notes (summaries). This dataset is best suited for dialogue summarization tasks in the counseling therapy space. (<a href="https://dl.acm.org/doi/abs/10.1145/3534678.3539187">read more</a>)<br><strong>[ Access is available on request </strong><a href="https://github.com/LCS2-IIITD/MEMO#memo-dataset-access-request"><strong>here</strong></a><strong> ]</strong></p><p><a href="https://github.com/LCS2-IIITD/MEMO#memo-dataset-access-request">GitHub - LCS2-IIITD/MEMO: A novel counseling summarization dataset. The work has been published at KDD 2022.</a></p><h4>DAIC-WoZ Dataset</h4><p>The DAIC-WOZ dataset comprises voice and text samples from 189 interviewed healthy and control persons and their PHQ-8 depression detection questionnaire. It is commonly used in research works for text-based depression detection and in multi-modal architecture. (<a href="https://dcapswoz.ict.usc.edu/wp-content/uploads/2022/02/DAICWOZDepression_Documentation.pdf">read more</a>)<br><strong>[ Access is available on request </strong><a href="https://dcapswoz.ict.usc.edu/"><strong>here</strong></a><strong> ]</strong></p><h4><strong>ALONE Dataset</strong></h4><p>A multimodal dataset of toxic social media interactions between confirmed high school students, called ALONE (AdoLescents ON twittEr), along with a descriptive explanation. Each instance of interaction includes tweets, images, emoji, and related metadata.<br><strong>[ Email the </strong><a href="https://link.springer.com/chapter/10.1007/978-3-030-60975-7_31"><strong>authors</strong></a><strong> to gain access for research purposes ]</strong></p><h4><strong>Counsel-Chat Dataset</strong></h4><p>Counselchat.com is an example of an expert community. It is a platform to help counselors build their reputation and make meaningful contact with potential clients. On the site, therapists respond to questions posed by clients, and users can like responses that they find most helpful.<br><strong>[ Access is publicly available </strong><a href="https://github.com/nbertagnolli/counsel-chat"><strong>here</strong></a><strong> ]</strong></p><h4>PAIR Dataset</h4><p>A dataset consisting of brief interactions between counselors and clients portraying different levels of reflective listening skills. Each interaction is in English and includes a client prompt, i.e., a client’s statement that is usually given to the counseling trainee, paired with counseling responses portraying different levels of reflections skill, i.e., low quality, medium quality, and high quality.<br><strong>[ Access is publicly available </strong><a href="https://lit.eecs.umich.edu/downloads.html#PAIR"><strong>here</strong></a><strong> ]</strong></p><p>There is a whole other category of dataset in this space, scraped from Reddit. There are many many such datasets easily accessible on the Internet, but only a handful of them contains rich annotations. I am adding such annotated datasets here.</p><h4>Reddit Based Datasets</h4><ul><li><strong>Suicide Severity:</strong> Dataset for labeling suicidality posts with longitudinal information, using CSSRS questionnaire.<br>[ Public access — <a href="https://zenodo.org/record/4543776/export/csl">here</a> ]</li><li><strong>Primate2022:</strong> Dataset for labeling depression-related posts using the PHQ-9 questionnaire.<br>[ Public access — <a href="https://github.com/primate-mh/Primate2022">here</a> ]</li></ul><p>Other resources related to the datasets in this space. You may find the following links relevant.</p><ul><li><a href="https://ieeexplore.ieee.org/abstract/document/9533924">A Large-Scale Dataset for Motivational Dialogue System: An Application of Natural Language Generation to Mental Health</a></li><li><a href="https://data.world/datasets/mental-health">There are 344 mental health datasets available on data.world.</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dd1a1b9f30b4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dialogue Summarization]]></title>
            <link>https://as3eem.medium.com/dialogue-summarization-46fd945497?source=rss-892b27730f23------2</link>
            <guid isPermaLink="false">https://medium.com/p/46fd945497</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[conversational-ai]]></category>
            <category><![CDATA[dialogue-systems]]></category>
            <category><![CDATA[summarization]]></category>
            <category><![CDATA[nlp]]></category>
            <dc:creator><![CDATA[Aseem Srivastava]]></dc:creator>
            <pubDate>Sun, 02 Apr 2023 10:31:25 GMT</pubDate>
            <atom:updated>2023-04-11T22:19:51.430Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="Space science and current advancements in AI / NLP for Dialogue System are equally fascinating. Endless opportunities." src="https://cdn-images-1.medium.com/max/1024/0*V6v0KSLRlJiW7Z5p" /><figcaption>Space science and current advancements in AI / NLP for Dialogue System are equally fascinating.</figcaption></figure><p>Here is a <strong>developing blog</strong> on the latest papers on dialogue summarization that I found relevant during my research on Dialogue Systems as a research scholar at LCS2. I understand this is not a complete list, but these are relevant to me, at least. I also published a paper on dialogue summarization at KDD 2022 titled <em>“</em><a href="https://dl.acm.org/doi/abs/10.1145/3534678.3539187"><em>Counseling Summarization Using Mental Health Knowledge Guided Utterance Filtering</em></a><em>”.</em></p><h4>KDD 2022</h4><ul><li><a href="https://dl.acm.org/doi/abs/10.1145/3534678.3539187">Counseling Summarization Using Mental Health Knowledge Guided Utterance Filtering</a></li></ul><h4>ACL 2022</h4><ul><li><a href="https://aclanthology.org/2022.acl-long.302.pdf">Towards Abstractive Grounded Summarization of Podcast Transcripts</a></li><li><a href="https://aclanthology.org/2022.acl-long.112.pdf">SummN: A Multi-Stage Summarization Framework for Long Input Dialogues and Documents</a></li></ul><h4><strong>EMNLP 2022</strong></h4><ul><li><a href="https://aclanthology.org/2022.emnlp-main.72.pdf">Curriculum Prompt Learning with Self-Training for Abstractive Dialogue Summarization</a></li></ul><h4>AAAI 2022</h4><ul><li><a href="https://github.com/microsoft/DialogLM">DialogLM: Pre-trained Model for Long Dialogue Understanding and Summarization</a></li></ul><h4>ACL 2021</h4><ul><li><a href="https://aclanthology.org/2021.acl-long.535/">ConvoSumm: Conversation Summarization Benchmark and Improved Abstractive Summarization with Argument Mining</a></li></ul><h4>EMNLP 2021</h4><ul><li><a href="https://aclanthology.org/2021.emnlp-main.631/">A Bag of Tricks for Dialogue Summarization</a></li></ul><h4>COLING 2020</h4><ul><li><a href="https://aclanthology.org/2020.coling-main.39/">Improving Abstractive Dialogue Summarization with Graph Structures and Topic Words</a></li></ul><p>Some addition resources</p><ul><li>A nice presentation on Dialogue Summarization: <a href="https://nlp-yang.github.io/Dialogue_Summarization.pdf">PDF</a></li></ul><p>If you are checking this, then you might also be interested in checking some people who are working in this area. Again, this is not a complete list, but I like their work and follow them closely.</p><p><a href="https://nlp-yang.github.io/">Yang Liu (刘洋)</a> | <a href="https://github.com/xcfcode">Xiachong Feng</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=46fd945497" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[All of the [ PyTorch | Transformers ]]]></title>
            <link>https://as3eem.medium.com/all-of-the-pytorch-transformers-86609267825c?source=rss-892b27730f23------2</link>
            <guid isPermaLink="false">https://medium.com/p/86609267825c</guid>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[pytorch]]></category>
            <category><![CDATA[hugging-face]]></category>
            <dc:creator><![CDATA[Aseem Srivastava]]></dc:creator>
            <pubDate>Thu, 02 Jun 2022 09:45:46 GMT</pubDate>
            <atom:updated>2023-07-06T09:17:08.653Z</atom:updated>
            <content:encoded><![CDATA[<h4>Recurring Blog | Last Updated: June 09, 2023</h4><p>I am a Ph.D. Candidate at <a href="https://lcs2.iiitd.edu.in/">LCS2</a> Lab. I work primarily in the area of conversational systems for mental health. My day-to-day tasks involve complex PyTorch coding and making sophisticated use of deep learning models for the NLP use cases.</p><p>There are plenty of resources on the internet to learn <strong>applied</strong> deep learning for NLP use cases using PyTorch. Here, I am just collating all relevant resources which I have found helpful during my learning course.</p><p>Initially, this blog may look scattered, but I will keep organizing it. This will be a continuously updating blog for many years. All your suggestions really matter. Do comment!!!</p><p><strong>Pytorch:</strong></p><ul><li>This <strong>one single video is enough to cover</strong> <strong>all of the basic PyTorch<br></strong><a href="https://www.youtube.com/watch?v=c36lUUr864M">https://www.youtube.com/watch?v=c36lUUr864M</a><br><em>Credit: </em><a href="https://twitter.com/python_engineer"><em>Patrick Lober</em></a></li></ul><p><strong>Pytorch x Transformer:</strong></p><ul><li>The best of the best <a href="https://nlp.seas.harvard.edu/2018/04/03/attention.html">https://nlp.seas.harvard.edu/2018/04/03/attention.html</a></li></ul><p><strong>Transformer Theory:</strong></p><ul><li><strong>Attention:</strong> <br>(1) [Undoubtedly the best] Transformer blog by Jay Alammar<br><a href="https://jalammar.github.io/illustrated-transformer/">https://jalammar.github.io/illustrated-transformer/</a><br>(2) (a better source) <a href="https://sebastianraschka.com/blog/2023/self-attention-from-scratch.html">https://sebastianraschka.com/blog/2023/self-attention-from-scratch.html</a><br>(3) (second best maybe) <a href="https://theaisummer.com/self-attention/">https://theaisummer.com/self-attention/</a></li><li><strong>BERT Inner Working: </strong><br>(1) <a href="https://www.topbots.com/bert-inner-workings/">https://www.topbots.com/bert-inner-workings/</a> <br>(2) <a href="https://gmihaila.medium.com/%EF%B8%8F-bert-inner-workings-1c3054cd1591">https://gmihaila.medium.com/%EF%B8%8F-bert-inner-workings-1c3054cd1591</a></li></ul><p><strong>Transformer Pretraining &amp; Finetuning:</strong></p><ul><li>Don&#39;t miss out on the Hugging Face course. It is reallllly good.</li><li><strong>Pretrain:</strong> <a href="https://www.topbots.com/pretrain-transformers-models-in-pytorch/">https://www.topbots.com/pretrain-transformers-models-in-pytorch/</a></li><li><strong>BERT Finetune:</strong> <a href="https://www.topbots.com/fine-tune-transformers-in-pytorch/">https://www.topbots.com/fine-tune-transformers-in-pytorch/</a></li><li><strong>BERT Finetune: </strong><a href="https://medium.com/grabngoinfo/transfer-learning-for-text-classification-using-pytorch-5e52045d55f8">https://medium.com/grabngoinfo/transfer-learning-for-text-classification-using-pytorch-5e52045d55f8</a></li><li><strong>GPT2 Classification:</strong> <a href="https://www.topbots.com/gpt2-text-classification-using-hugging-face-transformers/">https://www.topbots.com/gpt2-text-classification-using-hugging-face-transformers/</a></li></ul><p><strong>Some Extra Tips and Tricks:</strong></p><ul><li><a href="https://theaisummer.com/best-practices-deep-learning-code/">https://theaisummer.com/best-practices-deep-learning-code/</a></li><li><a href="https://towardsdatascience.com/pytorch-training-tricks-and-tips-a8808ebf746c">https://towardsdatascience.com/pytorch-training-tricks-and-tips-a8808ebf746c</a></li><li><a href="https://www.linkedin.com/posts/francesco-saverio-zuppichini-94659a150_ai-ml-ds-activity-7077656941790912512-_RJn/?utm_source=share&amp;utm_medium=member_ios">https://www.linkedin.com/posts/francesco-saverio-zuppichini-94659a150_ai-ml-ds-activity-7077656941790912512-_RJn/?utm_source=share&amp;utm_medium=member_ios</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=86609267825c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dialog Augmentation and Intent Detection]]></title>
            <link>https://medium.com/analytics-vidhya/dialog-augmentation-and-intent-detection-5d76bdf0fcb8?source=rss-892b27730f23------2</link>
            <guid isPermaLink="false">https://medium.com/p/5d76bdf0fcb8</guid>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[conversational-ai]]></category>
            <category><![CDATA[intent-classification]]></category>
            <category><![CDATA[chatbots]]></category>
            <dc:creator><![CDATA[Aseem Srivastava]]></dc:creator>
            <pubDate>Sat, 19 Dec 2020 21:13:32 GMT</pubDate>
            <atom:updated>2021-11-24T20:42:29.215Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RMALA1RXElL7La5lhjHroQ.png" /><figcaption>Photo by Miguel Á. Padriñán and Aseem Srivastava from Pexels</figcaption></figure><p>Intent Detection in Dialog System is a decisive step to drive the conversation in dialog system in the right direction. Often, the language understanding part is paid less attention to while building a dialog system leading to ambiguous response generation. We will try to reconstruct the well-known problem statement of Intent Detection for minority intents and augment dialog with similar intent in order to create a better understanding of minority intents. The proposed architecture and mechanism shows good results on dialog and can the particular augmentation mechanism could also be extended to other dialog related classification problems. In this research it work will generate a better understanding with an even lesser number of intent classifiers using cutting edge machine learning models and state of the art deep learning techniques on goal-oriented dialog systems. <strong>In the era of deep learning, intent detection in conversational systems is no more a classical machine learning problem.</strong></p><p><em>Google Colab notebooks, GitHub code and Dataset links are attached below for your reference.</em></p><h3>INTUITION</h3><p>Intent Detection(ID) in Conversational Dialog is a very crucial phase while revolutionizing dialog systems with Machine Learning. Leveraging the Natural Language Understanding(LU), Intent Detection helps in improvising the language generation and advancement in Dialog Management. Previously, the task of intent detection has been done many times with different datasets. Here we will try to detect the indents precisely where the number of training examples is very less in number and encounter the phase where chatbots are unable to figure out the intent of the user.</p><p>For dialog systems, especially for goal-oriented dialog systems, a chatbot should be robust enough to detect the intent of the user without taking any particular accent into the assumption. And that is where we are dealing even with a lesser number of intents classified in the dataset and bring them to correct identification of indents while in the test phase. For this purpose, we will be using the ATIS dataset released by <em>Sonos in June 2017</em>. We will see more about the data in the dataset section.</p><blockquote>Paraphrase generation techniques to leverage dialog with the minority intent and augmenting similar dialog results in having better understanding of the dialog in a dialog system.</blockquote><h3>Why is it Even Important?</h3><p>Dialog Systems are built with the focus to complete the task or domain on which they are trained on. Generally, researchers pay less attention to the LU with Intents part to diagnose the intents with very little occurrence in the conversation. The ID with the help of various machine learning techniques would help us to create a better understanding of human intents and flow of conversation.</p><p>At the same time, our output would also create a positive impact on the dialog management system to reproduce better language generation models.</p><p>According to the information extracted, the system can then decide on the appropriate actions to be taken, to help the users achieve their demands. LU applications are becoming increasingly significant in our everyday lives. Numerous devices, such as smartphones, have personal assistants that are built with LU technologies. <br>Multiple product support systems like help centres use the ID to reduce the need for a large number of employees that copy-and-paste boring responses to frequently asked questions. Chatbots, automated email responders, answer recommenders from a knowledge base with questions and answers.</p><h3>ATIS Dataset</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/515/1*tw3GnqpU0u3H5vvkP1qxpA.png" /><figcaption>Table 1: Above table shows example dialog from user to the bot and corresponding annotated intents in the ATIS dataset.</figcaption></figure><p>The dataset used for the ID task is <strong>ATIS — Airline Travel Information System which is a benchmark dataset originally released by Microsoft. </strong>In the dataset, we are dealing with 8 different intents related to airline travel and flight scheduling protocols.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/558/1*mC-6SC004Y6OWrqz_cusEA.png" /><figcaption>Figure 1: Intents used from the ATIS dataset in the project and their corresponding frequency chart.</figcaption></figure><p>Also, the ATIS dataset contains 4,978 training samples along with a vocabulary size of 943. The benchmark dataset is commonly used for slot filing problem statements too providing 129 slot counts. The part in which we are interested in the intent count which is 26 in total. For our experiment, we are dealing with 5 different intents.</p><h3>Modelling</h3><p>Our Approach is a mix of two different components where at first dialog with minority intent are leveraged by augmenting paraphrases of the dialog utterances. Since these utterances belong to the same intent as that of the parent dialog, the ATIS dataset can be augmented three times. In our work, we augmented data for dialog from 4 minor intent classes. For paraphrase generation, we used a pre-trained T5 model. Secondly, along with these dialog, a neural network is trained from scratch on top of the BERT embedding.</p><p>In our approach, we used the BERT based encoder part of transformer architecture combined with our implementation of a feed-forward neural network. The whole architecture is shown in Figure2.</p><p>As an input, we used BERT embedding pretrained on an unsupervised corpus. Those inputs were fed to a feed-forward neural network (Figure2). This module consisted of a single drop layer followed by two feed-forward layers with hidden dimension of 512.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-Zknj1_Mj7Ht0YXGFwkwMA.png" /><figcaption>Figure 2: Architecture of the proposed model which is further divided into two components: (i) The paraphrase generation component. (ii) The classifier feed-forward neural network. Output received is the softmax probability distribution of intent classes</figcaption></figure><h4>1. Paraphrase Generation</h4><p>To deal with limited data problem, we introduced novel data augmentation integration with intent detection problem for the first time. Our paraphrase generation model uses a T5 model which is robust to many NLP tasks. T5 is a transformer model from Google that is trained in an end-to-end manner with text as input and modified text as output.<br>T5 model achieves state-of-the-art results on many NLP problem statements like summarization, sentence extraction, machine translation, etc using the same text-to-text transformer trained on a huge text corpus.</p><p>In this project, we trained T5 with the original sentence as input and paraphrased (duplicate sentence for ATIS dataset) sentence as output.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SADnVbuMuBwwWtqql7KfFg.png" /><figcaption>Figure 3: Dialog augmentation using Google’s T5 Model has leveraged the dialog in minority by generating paraphrases of dialog keeping the majority class the same.</figcaption></figure><h4>2. Intent Classifier Neural Network</h4><p>We used BERT embedding to pass from a 3 layer feed-forward neural network giving 5 outputs which are at last passed through a softmax layer.</p><p>Our feedforward neural network contains a drop layer at the start with a dropout value of 0.5 on top of which the ReLU activation function is applied. The output from this activation function is passed through the first linear layer taking 768 dimensions as input and producing 512-dimensional output to the next hidden layer. Now the second linear layer produces 5 outputs for the classification of intents which is further passed through a softmax function in order to get probability distribution. <br>The training of the model on regular 8GB RAM of the i5 processor for 30 epochs and 32 batch size took 2 hours for data augmentation and ~12 hours to train the model on the classification architecture.</p><h3>Results</h3><p>We used a regular accuracy metric to compare results with a baseline and other models. We also evaluated the F1 Score for our model but since other models have not been used so it becomes irrelevant to compare. However, precision, recall, f1 score are all calculated and presented in the code files.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/569/1*1oXCBbRayQO8fPsDuS7BdA.png" /><figcaption>Table 2: Results obtained in our ablation study and result from final architecture.</figcaption></figure><p>Code/Data for the above project can be found at my GitHub link (Do give some stars!): <a href="https://github.com/as3eem/Dialog-Intent-Augmentation-and-Detection">https://github.com/as3eem/Dialog-Intent-Augmentation-and-Detection</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5d76bdf0fcb8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/analytics-vidhya/dialog-augmentation-and-intent-detection-5d76bdf0fcb8">Dialog Augmentation and Intent Detection</a> was originally published in <a href="https://medium.com/analytics-vidhya">Analytics Vidhya</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Sequence to Sequence Learning — Paper Explained]]></title>
            <link>https://medium.com/analytics-vidhya/sequence-to-sequence-learning-paper-explained-ce346158e0a6?source=rss-892b27730f23------2</link>
            <guid isPermaLink="false">https://medium.com/p/ce346158e0a6</guid>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[seq2seq]]></category>
            <dc:creator><![CDATA[Aseem Srivastava]]></dc:creator>
            <pubDate>Tue, 08 Sep 2020 21:53:12 GMT</pubDate>
            <atom:updated>2022-09-03T17:19:49.951Z</atom:updated>
            <content:encoded><![CDATA[<h3>Sequence to Sequence Learning — Paper Explained</h3><h4>What the heck is Encoder &amp; Decoder in a seq2seq model?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6KSJoc7JEOeUU5G3X_ooPA.png" /></figure><p><em>This blog gives a high-level intuition of the Seq2Seq model, so you don’t need to be “the deep learning guy” to understand all of it, basic neural network knowledge would be sufficient to understand this blog.</em></p><p>The research paper, <a href="https://papers.nips.cc/paper/5346-sequence-to-sequence-learning-with-neural-networks.pdf"><em>Sequence to Sequence Learning with Neural Network</em></a> is considered a breakthrough in the field of Natural Language Processing after Google released the paper at the <em>Conference on Neural Information Processing Systems (NIPS)</em>. After understanding the Seq2Seq, one can move ahead to read about Transformers, Attention Concepts, and other latest breakthroughs in the field of NLP.</p><p>Starting right from the start already had the following RNNs earlier:</p><ol><li><strong>Vector to Vector(Vec2Vec) RNN</strong></li></ol><p>This model takes a single vector as input and produces a single vector as output.</p><p>An example could be word-to-word translation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/72/1*x4_OHnfVl2oBjJ4mREXAww.png" /><figcaption>Vec2Vec model</figcaption></figure><p><strong>2. Sequence to Vector(Seq2Vec) RNN</strong></p><p>In the RNN model, where we give the input, a sequence at output comes out to be a single vector. <br>An example of this could be language predictor,</p><p><em>我爱计算机科学</em> (input sequence) gives <em>Chinese</em>(output vector)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/414/1*EpxbcNRWdtEHhxzxcMV1-A.png" /><figcaption>Seq2Vec model</figcaption></figure><p><strong>3. Vector to Sequence(Vec2Sec) RNN</strong></p><p>The RNN model where input is a single vector and outputs a sequence.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/376/1*vHQ3O5guCMqla7oMYVvVVw.png" /><figcaption>Vec2Seq model</figcaption></figure><p><strong>4. Sequence to Sequence (Seq2Seq) RNN</strong></p><p>Yes! We had Sequence to Sequence model earlier too which takes input as a sequence and provides output in sequence too.<br><em>Note: It completely differs from the Encoder-Decoder architecture represented in the paper which is explained a little later in this blog</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/573/1*pkcvvNv26vogdU0ZYEf3cw.png" /><figcaption>Traditional Seq2Seq RNN model.</figcaption></figure><p>Despite having this traditional seq2seq RNN model. How could this paper be a breakthrough? <br>Here, <strong>in the above figure, we can see the length of output sequence is same as the input sequence. </strong>A Language-translation model is in the same case. If we are trying to convert English to Hindi language, this doesn’t necessarily mean that length of English sequence is same as that of the Hindi sequence. This is where Encoder and Decoder are useful.</p><h3>Encoder and Decoder</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/894/1*TD1pHfYgXU5xaBXrN-jNTA.png" /><figcaption>Encoder Decoder Architecture of Seq2Seq</figcaption></figure><p>Above shown is the same architecture proposed in the Seq2Seq - encoder decoder research paper. It composes of 2 basic components-<br>1. Encoder<br>2. Decoder<br>Shown below is a well differentiated diagrammatic representation of the encoder and decoder. <strong>The key advantage of using an encoder decoder model is length of input and length of output can be different.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*13CteA43Soi6dZFp7vYI2Q.png" /></figure><ul><li>Each cell in this architecture is an RNN network <em>(can be either LSTM network or GRU network).</em></li><li>Encoder receives input<em>(A, B, C, &lt;eos&gt;) </em>and each cell receives a feedback from the <strong>hidden state</strong><em>(links between each cell).</em></li><li><em>W </em>is the <strong>context vector</strong>.</li><li>Decoder is the part where output is generated<em>(X,Y,Z,&lt;eos&gt;).</em></li></ul><p>Let’s try to understand the each component in detail so that we can understand the whole functioning of the encoder, decoder and how information is passed from encoder to decoder.</p><h4>Encoder</h4><p>Encoder is a recurrent RNN network in each cell. Each cell receives single vector followed by an end-of-statement token, &lt;EOS&gt; which marks the end of input sequence and generates <strong>context vector,</strong> <strong>W</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/894/1*mvYUaNkDwHKB1t-PZlN1LQ.png" /><figcaption>A typical encoder inside a encoder-decoder model showing relationship between RNN blocks, inputs as well as context vector, W.</figcaption></figure><p>It is responsible for taking input and pass-on the information to the next cell. This information being passed on is known as the <strong>feedback (hidden state) </strong>and is shown via the links between successive cells.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/622/1*3bMt1jxpB7Gdh79T6JhcRQ.png" /><figcaption>Hidden State (feedback) Calculation Formula</figcaption></figure><p>The formula mentioned here is used to calculate the hidden state’s feedback value which contains all the information till the last cell’s input. Here, <em>Wʰʰ</em> is the weight given to the previous hidden state at time stamp <em>(t-1)</em> and <em>Wʰˣ </em>is the weight given to the current input at time stamp <em>t.</em></p><h4><strong>Context Vector — the linkage between Encoder and Decoder</strong></h4><p>Context vector <strong>contains all the information</strong> from all the hidden states inside Encoder and it plays the role of only input for the decoder part.</p><h4>Decoder</h4><p>Decoder is responsible for generating the output. Each cell receives the output generated from the previous cell at time stamp <em>(t-1) </em>as the input of the current cell at time stamp<em> t. <br> W, </em>the context vector generated by the last cell of encoder acts as the initial input for the RNN cells in decoder.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/973/1*f1HywyX6etAULoKu3578EA.png" /><figcaption>A typical decoder inside a encoder-decoder model showing relationship between RNN blocks, inputs, and outputs</figcaption></figure><p>The key point to notice is that the output generated from the cell at time stamp <em>t</em> is used as the input for the cell at time stamp <em>t+1.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*tCxkRlnO6LKybJHXBta4Ng.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/387/1*KnO0NsONpQvzigm1i9AeMg.png" /></figure><p>These two formulae are used to calculate the hidden state feedback and the output from each cell.</p><p>That’s all the basics one need to know about the functioning of Encoder and Decoder. <strong>This paper became a breakthrough in the research and applied field of Natural Language Processing (NLP) as now the length of the sequence of output can be different from the length of the input </strong>making it robust and very useful in the case of machine translation, question-answering system, dialogue generation models, and many other fields.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ce346158e0a6" width="1" height="1" alt=""><hr><p><a href="https://medium.com/analytics-vidhya/sequence-to-sequence-learning-paper-explained-ce346158e0a6">Sequence to Sequence Learning — Paper Explained</a> was originally published in <a href="https://medium.com/analytics-vidhya">Analytics Vidhya</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>