Spaces:
Running
Running
fill free
#2
by
nruto
- opened
- README-2.md +0 -61
- app.py +1 -6
- app_stabilityai.py +0 -3
README-2.md
DELETED
@@ -1,61 +0,0 @@
|
|
1 |
-
# Rxple Chat Bot π’
|
2 |
-
|
3 |
-
Welcome to Rxple Chat Bot, an advanced AI chat interface built using Gradio and Hugging Face's Inference Client. This bot is designed to engage in natural conversations while respecting user privacy, ensuring no data is stored.
|
4 |
-
|
5 |
-
## Features
|
6 |
-
|
7 |
-
- **Privacy-Focused**: Our AI does not store any user data.
|
8 |
-
- **Flexible Configuration**: Customize system messages, max tokens, temperature, and top-p parameters.
|
9 |
-
- **Interactive Interface**: Engage in real-time conversations through a user-friendly web interface.
|
10 |
-
|
11 |
-
## Getting Started
|
12 |
-
|
13 |
-
### Prerequisites
|
14 |
-
|
15 |
-
Ensure you have Python installed on your machine. Additionally, install the required packages by running:
|
16 |
-
|
17 |
-
```bash
|
18 |
-
pip install gradio huggingface_hub
|
19 |
-
```
|
20 |
-
|
21 |
-
### Running the Bot
|
22 |
-
|
23 |
-
1. Clone this repository or download the script.
|
24 |
-
2. Run the script using Python:
|
25 |
-
|
26 |
-
```bash
|
27 |
-
python rxple_chat_bot.py
|
28 |
-
```
|
29 |
-
|
30 |
-
3. Open your web browser and navigate to `http://localhost:7860` to access the chat interface.
|
31 |
-
|
32 |
-
## Usage
|
33 |
-
|
34 |
-
The chat interface provides several customization options to tailor the conversation experience:
|
35 |
-
|
36 |
-
- **System Message**: Set the initial context or instructions for the AI.
|
37 |
-
- **Max New Tokens**: Define the maximum number of tokens the AI can generate per response.
|
38 |
-
- **Temperature**: Adjust the randomness of the AI's responses (lower values make it more deterministic).
|
39 |
-
- **Top-p (Nucleus Sampling)**: Control the diversity of the generated text (higher values increase diversity).
|
40 |
-
|
41 |
-
## Customization
|
42 |
-
|
43 |
-
You can further customize the appearance and behavior of the chat interface by modifying the script. Here are some key areas to explore:
|
44 |
-
|
45 |
-
- **Custom CSS**: The `opq` variable allows you to change the title color and add a logo.
|
46 |
-
- **Custom HTML**: The `custom_html` variable lets you inject custom HTML content, such as a welcome message or logo.
|
47 |
-
- **Description**: Update the `combined_description` variable to provide additional information about the bot.
|
48 |
-
|
49 |
-
## Contributing
|
50 |
-
|
51 |
-
Contributions are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request.
|
52 |
-
|
53 |
-
## License
|
54 |
-
|
55 |
-
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
56 |
-
|
57 |
-
---
|
58 |
-
|
59 |
-
**Follow us on [Instagram](https://www.instagram.com/khellon_patel_21)** for updates and more!
|
60 |
-
|
61 |
-
Rxple Chat Bot is brought to you by the team behind Qwen2.5-Coder-32B-Instruct. Thank you for using our service! π
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
app.py
CHANGED
@@ -1,8 +1,6 @@
|
|
1 |
import gradio as gr
|
2 |
from huggingface_hub import InferenceClient
|
3 |
|
4 |
-
|
5 |
-
|
6 |
client = InferenceClient("Qwen/Qwen2.5-Coder-32B-Instruct")
|
7 |
|
8 |
def respond(
|
@@ -13,8 +11,6 @@ def respond(
|
|
13 |
temperature,
|
14 |
top_p,
|
15 |
):
|
16 |
-
|
17 |
-
|
18 |
messages = [{"role": "system", "content": system_message}]
|
19 |
|
20 |
for val in history:
|
@@ -51,7 +47,7 @@ opq = """
|
|
51 |
# Custom HTML to inject the logo
|
52 |
custom_html = """
|
53 |
<div>
|
54 |
-
<h1> Welcome to
|
55 |
</div>
|
56 |
"""
|
57 |
|
@@ -81,6 +77,5 @@ demo = gr.ChatInterface(
|
|
81 |
css=opq # Add the custom CSS here
|
82 |
)
|
83 |
|
84 |
-
|
85 |
if __name__ == "__main__":
|
86 |
demo.launch(share=True)
|
|
|
1 |
import gradio as gr
|
2 |
from huggingface_hub import InferenceClient
|
3 |
|
|
|
|
|
4 |
client = InferenceClient("Qwen/Qwen2.5-Coder-32B-Instruct")
|
5 |
|
6 |
def respond(
|
|
|
11 |
temperature,
|
12 |
top_p,
|
13 |
):
|
|
|
|
|
14 |
messages = [{"role": "system", "content": system_message}]
|
15 |
|
16 |
for val in history:
|
|
|
47 |
# Custom HTML to inject the logo
|
48 |
custom_html = """
|
49 |
<div>
|
50 |
+
<h1> Welcome to Rxple Chat Bot π¬</h1>
|
51 |
</div>
|
52 |
"""
|
53 |
|
|
|
77 |
css=opq # Add the custom CSS here
|
78 |
)
|
79 |
|
|
|
80 |
if __name__ == "__main__":
|
81 |
demo.launch(share=True)
|
app_stabilityai.py
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
import gradio as gr
|
2 |
-
|
3 |
-
gr.load("models/stabilityai/stable-diffusion-3.5-large-turbo").launch()
|
|
|
|
|
|
|
|