Update app.py
Browse files
app.py
CHANGED
@@ -1,40 +1,6 @@
|
|
1 |
from huggingface_hub import InferenceClient
|
2 |
import gradio as gr
|
3 |
|
4 |
-
js = """
|
5 |
-
function createGradioAnimation() {
|
6 |
-
var container = document.createElement('div');
|
7 |
-
container.id = 'gradio-animation';
|
8 |
-
container.style.fontSize = '2em';
|
9 |
-
container.style.fontWeight = 'bold';
|
10 |
-
container.style.textAlign = 'center';
|
11 |
-
container.style.marginBottom = '20px';
|
12 |
-
|
13 |
-
var text = 'Hi 👋, I'm Rishiraj Acharya (ঋষিরাজ আচার্য্য)';
|
14 |
-
for (var i = 0; i < text.length; i++) {
|
15 |
-
(function(i){
|
16 |
-
setTimeout(function(){
|
17 |
-
var letter = document.createElement('span');
|
18 |
-
letter.style.opacity = '0';
|
19 |
-
letter.style.transition = 'opacity 0.5s';
|
20 |
-
letter.innerText = text[i];
|
21 |
-
|
22 |
-
container.appendChild(letter);
|
23 |
-
|
24 |
-
setTimeout(function() {
|
25 |
-
letter.style.opacity = '1';
|
26 |
-
}, 50);
|
27 |
-
}, i * 250);
|
28 |
-
})(i);
|
29 |
-
}
|
30 |
-
|
31 |
-
var gradioContainer = document.querySelector('.gradio-container');
|
32 |
-
gradioContainer.insertBefore(container, gradioContainer.firstChild);
|
33 |
-
|
34 |
-
return 'Animation created';
|
35 |
-
}
|
36 |
-
"""
|
37 |
-
|
38 |
client = InferenceClient(
|
39 |
"mistralai/Mixtral-8x7B-Instruct-v0.1"
|
40 |
)
|
@@ -53,13 +19,13 @@ def show_info(section):
|
|
53 |
return "Select a section to display information."
|
54 |
|
55 |
# Creating Gradio Interface
|
56 |
-
with gr.Blocks(
|
57 |
with gr.Row():
|
58 |
with gr.Column():
|
59 |
gr.Markdown("# Hi 👋, I'm Rishiraj Acharya (ঋষিরাজ আচার্য্য)")
|
60 |
gr.Markdown("## Google Developer Expert in ML ✨ | Hugging Face Fellow 🤗 | GSoC '22 at TensorFlow 👨🏻🔬 | TFUG Kolkata Organizer 🎙️ | Kaggle Master 🧠 | Dynopii ML Engineer 👨🏻💻")
|
61 |
gr.Markdown("### I work with natural language understanding, machine translation, named entity recognition, question answering, topic segmentation, and automatic speech recognition. My work typically relies on very large quantities of data and innovative methods in deep learning to tackle user challenges around the world — in languages from around the world. My areas of work include Natural Language Engineering, Language Modeling, Text-to-Speech Software Engineering, Speech Frameworks Engineering, Data Science, and Research.")
|
62 |
-
gr.HTML(value='<a href="https://twitter.com/rishirajacharya" target="blank"><img
|
63 |
with gr.Column():
|
64 |
gr.Image("profile.png")
|
65 |
|
|
|
1 |
from huggingface_hub import InferenceClient
|
2 |
import gradio as gr
|
3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
client = InferenceClient(
|
5 |
"mistralai/Mixtral-8x7B-Instruct-v0.1"
|
6 |
)
|
|
|
19 |
return "Select a section to display information."
|
20 |
|
21 |
# Creating Gradio Interface
|
22 |
+
with gr.Blocks() as app:
|
23 |
with gr.Row():
|
24 |
with gr.Column():
|
25 |
gr.Markdown("# Hi 👋, I'm Rishiraj Acharya (ঋষিরাজ আচার্য্য)")
|
26 |
gr.Markdown("## Google Developer Expert in ML ✨ | Hugging Face Fellow 🤗 | GSoC '22 at TensorFlow 👨🏻🔬 | TFUG Kolkata Organizer 🎙️ | Kaggle Master 🧠 | Dynopii ML Engineer 👨🏻💻")
|
27 |
gr.Markdown("### I work with natural language understanding, machine translation, named entity recognition, question answering, topic segmentation, and automatic speech recognition. My work typically relies on very large quantities of data and innovative methods in deep learning to tackle user challenges around the world — in languages from around the world. My areas of work include Natural Language Engineering, Language Modeling, Text-to-Speech Software Engineering, Speech Frameworks Engineering, Data Science, and Research.")
|
28 |
+
gr.HTML(value='<a href="https://twitter.com/rishirajacharya" target="blank"><img src="https://raw.githubusercontent.com/rahuldkjain/github-profile-readme-generator/master/src/images/icons/Social/twitter.svg" alt="rishirajacharya" height="30" width="40"></a><a href="https://linkedin.com/in/rishirajacharya" target="blank"><img src="https://raw.githubusercontent.com/rahuldkjain/github-profile-readme-generator/master/src/images/icons/Social/linked-in-alt.svg" alt="rishirajacharya" height="30" width="40"></a><a href="https://instagram.com/rishirajacharya" target="blank"><img src="https://raw.githubusercontent.com/rahuldkjain/github-profile-readme-generator/master/src/images/icons/Social/instagram.svg" alt="rishirajacharya" height="30" width="40"></a>')
|
29 |
with gr.Column():
|
30 |
gr.Image("profile.png")
|
31 |
|