Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Add old ui as example #344

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions doc/source/examples/ai_podcast.rst
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,4 @@ Chinese (AI_Podcast_ZH.py)

**Source Code** :

* `AI_Podcast <https://github.com/xorbitsai/inference/blob/main/examples/AI_podcast.py>`_ (English Version)

* AI_Podcast_ZH (Chinese Version)
* `AI_Podcast <https://github.com/xorbitsai/inference/examples/gradio_arena.py>`
Bojun-Feng marked this conversation as resolved.
Show resolved Hide resolved
34 changes: 34 additions & 0 deletions doc/source/examples/arena.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
.. _dual_model_chatbot:

==========================
Example: Chatbot Arena 🤼️
==========================

**Description**:

Experience the thrill of conversing with two AI models simultaneously! This interface allows you to launch two models side by side and engage them in a chat. Enter a prompt, and watch as both models respond to your inquiry 🎙️

**Notice**:

Please do not try to open both models together. Patiently wait until one is finished launching before starting the next. Similarly, wait until you've received responses from both models before moving on to the next question. Thank you for understanding! 🚦

**Used Technology**:

@ `ggerganov <https://twitter.com/ggerganov>`_ 's `ggml <https://github.com/ggerganov/ggml>`_

@ `Xinference <https://github.com/xorbitsai/inference>`_ as a launcher

@ All LLaMA and Chatglm models supported by `Xorbitsio inference <https://github.com/xorbitsai/inference>`_

**Detailed Explanation on the Demo Functionality** :

1. Launch the two models with all required parameters selected by the user.

2. Initialize two separate chat histories to store the context for both models.

3. Prompt the user for input and simultaneously pass it to both models, generating individual responses.

5. Show the outputs of both models in the interface. Respective chat histories serve as context for upcoming rounds.

**Source Code** :
* `arena <https://github.com/xorbitsai/inference/blob/main/examples/gradio_arena.py>`_
3 changes: 2 additions & 1 deletion doc/source/examples/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ Examples
:hidden:

ai_podcast
chatbot
chatbot
arena
Loading