Giter Club home page Giter Club logo

chatbot_from_transformer's Introduction

ChatBot_From_Transformer

Introduction and Results

This time I am going to use Transformer that I mentioned in my last repository to build a Chinese chatbot.

The model structure will be same as my last impliment, but this time I'm going to use BertTokenizer to encode the sentence to token and add some randomness to the model's output to make sure that the same input can have some different results.

Here is the result:


This result seems fantastic, the model can indeed handle the pattern of daily conversation.
For example, when I say 你今年幾歲? (how old are you this year?) on the first picture the model reply 幼稚園畢業啦 (just graduated from kindergarten).

In this case we can see the model should knew the meaning of 「幾歲」 to generate the sentence, and the things what surprised me was that the model reply a period of time (just graduated from kindergarten) instead of a point in time (8 years old), I think it may be caused by the nature of my dataset.

Finally, I also found something very funny. On the last line of the second picture, I say 你是笨蛋嗎? (Are you stupid?) and the model replys 我們都一樣 (we are the same!) 😄😄

chatbot_from_transformer's People

Contributors

yukino1010 avatar

Watchers

 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.