KO
|
EN
gitlite — search
Search
#typescript
#ai-agents
#deepseek-harness
#dsh-plugin
#open-source
#ai
#cli
#dsh
#claude-code
#codex
#developer-tools
#react
pychatml
★ 55
Open GitHub ↗
Chat Markup Language conversation library
Download README (.md)
Explore Similar Repositories
arcade-nl2code
:
No description available.
CVE-2023-27350
:
Proof of Concept Exploit for PaperCut CVE-2023-27350
myla
:
a local implementation of OpenAI Assistants API: myla stands for MY Local Assistant
AcademyCraft
:
A Minecraft mod about superability
Tutorbot-Spock
:
An Education Tutoring Chatbot based on Learning Science Principles powered by Large Language Models
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
pychatml
?
Download (.md)
# pychatml The `pychatml` package allows you to convert chat interfaces from and to the ChatML format. ## Installation You can install the `pychatml` package using pip: ```shell pip install pychatml ``` ## What Makes it easy to integrate between different chat formats and models. ```python from pychatml.llama2_converter import Llama2 PROMPT = """[INST] Hi, how are you? [/INST] Good thanks! [INST] Can you help me with this math program? [/INST]""" converter = Llama2() converter.to_chatml(PROMPT) ``` ```json [ {"role": "user", "content": "Hi, how are you?"}, {"role": "assistant", "content": "Good thanks!"}, {"role": "user", "content": "Can you help me with this math program?"}, ] ``` #### Supported formats - [x] Llama 2 - [x] Anthropic - [x] Alpaca - [x] Vicuna/ShareGPT (from https://github.com/lm-sys/FastChat/blob/e67b21dcbde91a5ad9740b081c59c433093f54da/fastchat/conversation.py#L394C1-L404C2) ## Why?  https://github.com/OpenAccess-AI-Collective/axolotl/pull/982 ## Questions? Create an issue or discussion in this repository. Or, reach out to our team! [@jakob_frick](https://twitter.com/frick_jakob/), [@__anjor](https://twitter.com/__anjor), [@maxnajork](https://twitter.com/maxnajork) on X or [team@radiantai.com](mailto:team@radiantai.com). ## How to create a new release A new release will automatically be published to pypi. For this to happen you need to - update the version specificed in `setup.py` - create a `git tag` with the version you want to release and push it via `git push --tags` - create a new release in Github A Github action will automatically publish the new version to pypi. ## Contributing Guidelines Thank you for your interest in contributing to our project! Before you begin writing code, it would be helpful if you read these [contributing guidelines](CONTRIBUTING.md). Following them will make the contribution process easier and more efficient for everyone involved. Please note that the project is released with an [MIT License](https://opensource.org/licenses/MIT).