# Welcome to Chainlit π
**Build Python LLM apps in minutes β‘οΈ**
Chainlit lets you create ChatGPT-like UIs on top of any Python code in minutes! Some of the key features include intermediary steps visualisation, element management & display (images, text, carousel, etc.) as well as cloud deployment.
[![](https://dcbadge.vercel.app/api/server/ZThrUxbAYw?style=flat)](https://discord.gg/k73SQ3FyUh)
[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/chainlit_io.svg?style=social&label=Follow%20%40chainlit_io)](https://twitter.com/chainlit_io)
[![CI](https://github.com/Chainlit/chainlit/actions/workflows/ci.yaml/badge.svg)](https://github.com/Chainlit/chainlit/actions/workflows/ci.yaml)
https://github.com/Chainlit/chainlit/assets/13104895/e347e52c-35b2-4c35-8a88-f8ac02dd198e
## Installation
Open a terminal and run:
```bash
$ pip install chainlit
$ chainlit hello
```
If this opens the `hello app` in your browser, you're all set!
## π Documentation
Please see [here](https://docs.chainlit.io) for full documentation on:
- Getting started (installation, simple examples)
- Examples
- Reference (full API docs)
## π Quickstart
### π Pure Python
Create a new file `demo.py` with the following code:
```python
import chainlit as cl
@cl.on_message # this function will be called every time a user inputs a message in the UI
async def main(message: str):
# this is an intermediate step
await cl.Message(author="Tool 1", content=f"Response from tool1", indent=1).send()
# send back the final answer
await cl.Message(content=f"This is the final answer").send()
```
Now run it!
```
$ chainlit run demo.py -w
```
<img src="/images/quick-start.png" alt="Quick Start"></img>
### π With LangChain
Check out our plug-and-play [integration](https://docs.chainlit.io/integrations/langchain) with LangChain!
### π More Examples - Cookbook
You can find various examples of Chainlit apps [here](https://github.com/Chainlit/cookbook) that leverage tools and services such as OpenAI, AnthropiΡ, LangChain, LlamaIndex, ChromaDB, Pinecone and more.
## π£ Roadmap
- [ ] New UI elements (spreadsheet, video, carousel...)
- [ ] Create your own UI elements via component framework
- [ ] DAG-based chain-of-thought interface
- [ ] Support more LLMs in the prompt playground
- [ ] App deployment
Tell us what you would like to see added in Chainlit using the Github issues or on [Discord](https://discord.gg/ZThrUxbAYw).
## π Contributing
As an open-source initiative in a rapidly evolving domain, we welcome contributions, be it through the addition of new features or the improvement of documentation.
For detailed information on how to contribute, see [here](.github/CONTRIBUTING.md).
## License
Chainlit is open-source and licensed under the [Apache 2.0](LICENSE) license.
Raw data
{
"_id": null,
"home_page": "https://github.com/meicanhong/chainlit",
"name": "fp-chainlit",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8.1,<4.0.0",
"maintainer_email": "",
"keywords": "LLM,Agents,gen ai,chat ui,chatbot ui,langchain",
"author": "danny",
"author_email": "danny@footprint.network",
"download_url": "https://files.pythonhosted.org/packages/97/55/a989ef201f0aeb37ccbe27b3fb5eedfe515d3cd6e1dbe808215dc150af43/fp_chainlit-0.7.1.tar.gz",
"platform": null,
"description": "# Welcome to Chainlit \ud83d\udc4b\n\n**Build Python LLM apps in minutes \u26a1\ufe0f**\n\nChainlit lets you create ChatGPT-like UIs on top of any Python code in minutes! Some of the key features include intermediary steps visualisation, element management & display (images, text, carousel, etc.) as well as cloud deployment.\n\n[![](https://dcbadge.vercel.app/api/server/ZThrUxbAYw?style=flat)](https://discord.gg/k73SQ3FyUh)\n[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/chainlit_io.svg?style=social&label=Follow%20%40chainlit_io)](https://twitter.com/chainlit_io)\n[![CI](https://github.com/Chainlit/chainlit/actions/workflows/ci.yaml/badge.svg)](https://github.com/Chainlit/chainlit/actions/workflows/ci.yaml)\n\nhttps://github.com/Chainlit/chainlit/assets/13104895/e347e52c-35b2-4c35-8a88-f8ac02dd198e\n\n## Installation\n\nOpen a terminal and run:\n\n```bash\n$ pip install chainlit\n$ chainlit hello\n```\n\nIf this opens the `hello app` in your browser, you're all set!\n\n## \ud83d\udcd6 Documentation\n\nPlease see [here](https://docs.chainlit.io) for full documentation on:\n\n- Getting started (installation, simple examples)\n- Examples\n- Reference (full API docs)\n\n## \ud83d\ude80 Quickstart\n\n### \ud83d\udc0d Pure Python\n\nCreate a new file `demo.py` with the following code:\n\n```python\nimport chainlit as cl\n\n\n@cl.on_message # this function will be called every time a user inputs a message in the UI\nasync def main(message: str):\n # this is an intermediate step\n await cl.Message(author=\"Tool 1\", content=f\"Response from tool1\", indent=1).send()\n\n # send back the final answer\n await cl.Message(content=f\"This is the final answer\").send()\n```\n\nNow run it!\n\n```\n$ chainlit run demo.py -w\n```\n\n<img src=\"/images/quick-start.png\" alt=\"Quick Start\"></img>\n\n### \ud83d\udd17 With LangChain\n\nCheck out our plug-and-play [integration](https://docs.chainlit.io/integrations/langchain) with LangChain!\n\n### \ud83d\udcda More Examples - Cookbook\n\nYou can find various examples of Chainlit apps [here](https://github.com/Chainlit/cookbook) that leverage tools and services such as OpenAI, Anthropi\u0441, LangChain, LlamaIndex, ChromaDB, Pinecone and more.\n\n## \ud83d\udee3 Roadmap\n\n- [ ] New UI elements (spreadsheet, video, carousel...)\n- [ ] Create your own UI elements via component framework\n- [ ] DAG-based chain-of-thought interface\n- [ ] Support more LLMs in the prompt playground\n- [ ] App deployment\n\nTell us what you would like to see added in Chainlit using the Github issues or on [Discord](https://discord.gg/ZThrUxbAYw).\n\n## \ud83d\udc81 Contributing\n\nAs an open-source initiative in a rapidly evolving domain, we welcome contributions, be it through the addition of new features or the improvement of documentation.\n\nFor detailed information on how to contribute, see [here](.github/CONTRIBUTING.md).\n\n## License\n\nChainlit is open-source and licensed under the [Apache 2.0](LICENSE) license.\n\n",
"bugtrack_url": null,
"license": "Apache-2.0 license",
"summary": "A faster way to build chatbot UIs.",
"version": "0.7.1",
"project_urls": {
"Homepage": "https://github.com/meicanhong/chainlit",
"Repository": "https://github.com/meicanhong/chainlit"
},
"split_keywords": [
"llm",
"agents",
"gen ai",
"chat ui",
"chatbot ui",
"langchain"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "a2e9609d383ee042399b23cfbb6431663bfb26f872adb9d8ddcb215b2c48b1ff",
"md5": "7d30a9b08686301eda09082d65d3e809",
"sha256": "3ef0f6073c3c1b281e8c5da89482e1d53aca5c8d7fe820dc17c572612a7f67d0"
},
"downloads": -1,
"filename": "fp_chainlit-0.7.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "7d30a9b08686301eda09082d65d3e809",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8.1,<4.0.0",
"size": 972443,
"upload_time": "2023-09-24T09:33:15",
"upload_time_iso_8601": "2023-09-24T09:33:15.907085Z",
"url": "https://files.pythonhosted.org/packages/a2/e9/609d383ee042399b23cfbb6431663bfb26f872adb9d8ddcb215b2c48b1ff/fp_chainlit-0.7.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9755a989ef201f0aeb37ccbe27b3fb5eedfe515d3cd6e1dbe808215dc150af43",
"md5": "42d485db79b3a343e6e514a714a1c3ae",
"sha256": "0d597122ff99a9287d1e99e4fcf267bb129f04cd90d9e2e9da595a2ea4220d49"
},
"downloads": -1,
"filename": "fp_chainlit-0.7.1.tar.gz",
"has_sig": false,
"md5_digest": "42d485db79b3a343e6e514a714a1c3ae",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8.1,<4.0.0",
"size": 953625,
"upload_time": "2023-09-24T09:33:17",
"upload_time_iso_8601": "2023-09-24T09:33:17.810873Z",
"url": "https://files.pythonhosted.org/packages/97/55/a989ef201f0aeb37ccbe27b3fb5eedfe515d3cd6e1dbe808215dc150af43/fp_chainlit-0.7.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-09-24 09:33:17",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "meicanhong",
"github_project": "chainlit",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "fp-chainlit"
}