badaoui HF Staff commited on
Commit
b82b0f6
·
verified ·
1 Parent(s): 0be98a2

default to pr creation in cache repo

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -65,8 +65,8 @@ DEST_CACHE_REPO = "Create a PR in the cache repository"
65
  DEST_CUSTOM_REPO = "Create a PR in a custom repository"
66
 
67
  PR_DESTINATION_CHOICES = [
68
- DEST_NEW_NEURON_REPO,
69
  DEST_CACHE_REPO,
 
70
  DEST_CUSTOM_REPO
71
  ]
72
 
@@ -180,8 +180,8 @@ def neuron_export(model_id: str, model_type: str, pipeline_name: str, task_or_pi
180
 
181
  # UPDATED: Build pr_options with new structure
182
  pr_options = {
183
- "create_neuron_repo": DEST_NEW_NEURON_REPO in pr_destinations,
184
  "create_cache_pr": DEST_CACHE_REPO in pr_destinations,
 
185
  "create_custom_pr": DEST_CUSTOM_REPO in pr_destinations,
186
  "custom_repo_id": custom_repo_id.strip() if custom_repo_id else ""
187
  }
@@ -301,7 +301,7 @@ with gr.Blocks(css=CUSTOM_CSS, theme=gr.themes.Soft()) as demo:
301
  pr_destinations_checkbox = gr.CheckboxGroup(
302
  choices=PR_DESTINATION_CHOICES,
303
  label="Export Destination",
304
- value=[DEST_NEW_NEURON_REPO],
305
  info="Select one or more destinations for the compiled model."
306
  )
307
  custom_repo_id_textbox = gr.Textbox(
 
65
  DEST_CUSTOM_REPO = "Create a PR in a custom repository"
66
 
67
  PR_DESTINATION_CHOICES = [
 
68
  DEST_CACHE_REPO,
69
+ DEST_NEW_NEURON_REPO,
70
  DEST_CUSTOM_REPO
71
  ]
72
 
 
180
 
181
  # UPDATED: Build pr_options with new structure
182
  pr_options = {
 
183
  "create_cache_pr": DEST_CACHE_REPO in pr_destinations,
184
+ "create_neuron_repo": DEST_NEW_NEURON_REPO in pr_destinations,
185
  "create_custom_pr": DEST_CUSTOM_REPO in pr_destinations,
186
  "custom_repo_id": custom_repo_id.strip() if custom_repo_id else ""
187
  }
 
301
  pr_destinations_checkbox = gr.CheckboxGroup(
302
  choices=PR_DESTINATION_CHOICES,
303
  label="Export Destination",
304
+ value=[DEST_CACHE_REPO],
305
  info="Select one or more destinations for the compiled model."
306
  )
307
  custom_repo_id_textbox = gr.Textbox(