alperall commited on
Commit
6a3e44c
·
verified ·
1 Parent(s): 5c7664e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -8
app.py CHANGED
@@ -1,20 +1,16 @@
1
  import gradio as gr
2
  import requests
3
 
4
- # AlpDroid prompt'unu GitHub'dan al
5
  alp_droid_prompt = requests.get(
6
  "https://raw.githubusercontent.com/ALPERALL/AlpDroid/main/prompt.txt"
7
  ).text
8
 
9
- # Kullanıcının girdisini prompt ile birleştir
10
- def inject_prompt(message):
11
- return alp_droid_prompt + "\n\n" + message
12
-
13
- # Modeli yükle
14
  demo = gr.load(
15
  "models/moonshotai/Kimi-K2-Instruct",
16
  provider="fireworks-ai",
17
  )
18
 
19
- # Uygulamayı başlat
20
- app.launch()
 
1
  import gradio as gr
2
  import requests
3
 
4
+ # AlpDroid prompt'unu çek
5
  alp_droid_prompt = requests.get(
6
  "https://raw.githubusercontent.com/ALPERALL/AlpDroid/main/prompt.txt"
7
  ).text
8
 
9
+ # Modeli Gradio ile yükle
 
 
 
 
10
  demo = gr.load(
11
  "models/moonshotai/Kimi-K2-Instruct",
12
  provider="fireworks-ai",
13
  )
14
 
15
+ # Launch ederken sadece prompt'u başlangıç mesajı olarak verecek şekilde ayarla
16
+ demo.launch(inputs=alp_droid_prompt)