Spaces:
Sleeping
Sleeping
Ali Sartaz Khan
commited on
Commit
·
0feb9f7
1
Parent(s):
a5451af
edits
Browse files
talk_arena/__pycache__/audio_collection.cpython-312.pyc
CHANGED
Binary files a/talk_arena/__pycache__/audio_collection.cpython-312.pyc and b/talk_arena/__pycache__/audio_collection.cpython-312.pyc differ
|
|
talk_arena/audio_collection.py
CHANGED
@@ -18,7 +18,7 @@ os.makedirs("outputs", exist_ok=True)
|
|
18 |
# Initialize Hugging Face API client
|
19 |
hf_api = HfApi(token=os.getenv("HF_TOKEN"))
|
20 |
DATASET_REPO = "alisartazkhan/audioLLM_judge"
|
21 |
-
CATEGORY = "
|
22 |
MAX_RECORDINGS = 5 # Number of prompts to record
|
23 |
COMPLETION_CODE = "CEO4RWQ6"
|
24 |
resampler = Audio(sampling_rate=16_000)
|
@@ -103,8 +103,8 @@ def on_submit(audio_input, prompt_index):
|
|
103 |
if audio_input is None:
|
104 |
return (
|
105 |
gr.Markdown(f"# Recording {prompt_index + 1}/{MAX_RECORDINGS}"),
|
106 |
-
gr.Markdown(f"## Please
|
107 |
-
gr.Markdown(f"### {PROMPTS[prompt_index]}"),
|
108 |
gr.Audio(value=None, label="Record your response"),
|
109 |
gr.Button("Submit Recording", interactive=False),
|
110 |
gr.Button("Next Prompt", visible=False),
|
@@ -165,8 +165,8 @@ def next_prompt(prompt_index):
|
|
165 |
# Display the next prompt
|
166 |
return (
|
167 |
gr.Markdown(f"# Recording {prompt_index + 1}/{MAX_RECORDINGS}"),
|
168 |
-
gr.Markdown(f"##
|
169 |
-
gr.Markdown(f"### {PROMPTS[prompt_index]}"),
|
170 |
gr.Audio(value=None, label="Record your response", sources=["microphone"]),
|
171 |
gr.Button("Submit Recording", interactive=False),
|
172 |
gr.Button("Next Prompt", visible=False),
|
@@ -202,8 +202,8 @@ with gr.Blocks(theme=theme, css="footer {visibility: hidden}") as demo:
|
|
202 |
prompt_index = gr.State(0)
|
203 |
|
204 |
title = gr.Markdown(f"# Recording 1/{MAX_RECORDINGS}")
|
205 |
-
instructions = gr.Markdown("## Please
|
206 |
-
prompt_text = gr.Markdown(f"### {PROMPTS[0]}")
|
207 |
|
208 |
audio_input = gr.Audio(
|
209 |
label="Record your response",
|
|
|
18 |
# Initialize Hugging Face API client
|
19 |
hf_api = HfApi(token=os.getenv("HF_TOKEN"))
|
20 |
DATASET_REPO = "alisartazkhan/audioLLM_judge"
|
21 |
+
CATEGORY = "pilot_tempo_control4"
|
22 |
MAX_RECORDINGS = 5 # Number of prompts to record
|
23 |
COMPLETION_CODE = "CEO4RWQ6"
|
24 |
resampler = Audio(sampling_rate=16_000)
|
|
|
103 |
if audio_input is None:
|
104 |
return (
|
105 |
gr.Markdown(f"# Recording {prompt_index + 1}/{MAX_RECORDINGS}"),
|
106 |
+
gr.Markdown(f"## Please read out the following sentence:"),
|
107 |
+
gr.Markdown(f"### \"{PROMPTS[prompt_index]}\""),
|
108 |
gr.Audio(value=None, label="Record your response"),
|
109 |
gr.Button("Submit Recording", interactive=False),
|
110 |
gr.Button("Next Prompt", visible=False),
|
|
|
165 |
# Display the next prompt
|
166 |
return (
|
167 |
gr.Markdown(f"# Recording {prompt_index + 1}/{MAX_RECORDINGS}"),
|
168 |
+
gr.Markdown(f"## Please read out the following sentence:"),
|
169 |
+
gr.Markdown(f"### \"{PROMPTS[prompt_index]}\""),
|
170 |
gr.Audio(value=None, label="Record your response", sources=["microphone"]),
|
171 |
gr.Button("Submit Recording", interactive=False),
|
172 |
gr.Button("Next Prompt", visible=False),
|
|
|
202 |
prompt_index = gr.State(0)
|
203 |
|
204 |
title = gr.Markdown(f"# Recording 1/{MAX_RECORDINGS}")
|
205 |
+
instructions = gr.Markdown("## Please read out the following sentence:")
|
206 |
+
prompt_text = gr.Markdown(f"### \"{PROMPTS[0]}\"")
|
207 |
|
208 |
audio_input = gr.Audio(
|
209 |
label="Record your response",
|