Giter Site home page Giter Site logo

llama2_chat_templater's Introduction

  • ๐Ÿ‘‹ Hi, Iโ€™m @samrawal!
  • ๐Ÿฉบ I'm currently an M.D. student at the Carle Illinois College of Medicine at the University of Illinois, Urbana-Champaign.
  • ๐Ÿค– I'm also working on Natural Language Processing research applied to neurology records:
  • ๐Ÿ’ป More about me at samrawal.com.
  • โœ๏ธ I write at samrawal.substack.com.
  • ๐Ÿฆ I'm on Twitter @samarthrawal.

llama2_chat_templater's People

Contributors

chintan1995 avatar samrawal 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

Watchers

 avatar  avatar

llama2_chat_templater's Issues

When having a long conversation, it does not generate new starting <s> tokens from second user - model message pairs

Using the following code:

pt = PromptTemplate(system_prompt="This is a system message")
pt.add_user_message("Hello, how are you?")
pt.add_model_reply("I am doing good! Hope you are doing well too.")
pt.add_user_message("Who is the PM of India?")
pt.add_model_reply("The Prime Minister of India is Narendra Modi.")
pt.add_user_message("Thank you!")

Currently the output looks like this,

'<s>[INST] <<SYS>>\nThis is a system message\n<</SYS>>Hello, how are you? [/INST] I am doing good! Hope you are doing well too. </s>[INST] Who is the PM of India? [/INST] The Prime Minister of India is Narendra Modi. </s>[INST] Thank you! [/INST]'

The actual prompt should be like this,

'<s> [INST] <<SYS>>\nThis is a system message\n<</SYS>> Hello, how are you? [/INST] I am doing good! Hope you are doing well too. </s> <s> [INST] Who is the PM of India? [/INST] The Prime Minister of India is Narendra Modi. </s> <s> [INST] Thank you! [/INST]'

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.