Jellyfish042 Claude Opus 4.5 commited on
Commit
1a54ca4
·
1 Parent(s): 9afeeeb

Fix Gradio compatibility for HuggingFace Spaces

Browse files

- Upgrade gradio to >=5.0.0 to fix API schema bug
- Add server_name and server_port to demo.launch()

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

Files changed (3) hide show
  1. .claude/settings.local.json +4 -1
  2. app.py +1 -1
  3. requirements.txt +1 -1
.claude/settings.local.json CHANGED
@@ -2,7 +2,10 @@
2
  "permissions": {
3
  "allow": [
4
  "Bash(git init:*)",
5
- "Bash(git add:*)"
 
 
 
6
  ]
7
  }
8
  }
 
2
  "permissions": {
3
  "allow": [
4
  "Bash(git init:*)",
5
+ "Bash(git add:*)",
6
+ "Bash(git remote add:*)",
7
+ "Bash(git push:*)",
8
+ "Bash(git branch:*)"
9
  ]
10
  }
11
  }
app.py CHANGED
@@ -359,4 +359,4 @@ with gr.Blocks(
359
 
360
 
361
  if __name__ == "__main__":
362
- demo.launch()
 
359
 
360
 
361
  if __name__ == "__main__":
362
+ demo.launch(server_name="0.0.0.0", server_port=7860)
requirements.txt CHANGED
@@ -1,7 +1,7 @@
1
  torch>=2.0.0
2
  transformers>=4.35.0
3
  tokenizers>=0.15.0
4
- gradio>=4.0.0
5
  numpy>=1.24.0
6
  tqdm>=4.65.0
7
  packaging
 
1
  torch>=2.0.0
2
  transformers>=4.35.0
3
  tokenizers>=0.15.0
4
+ gradio>=5.0.0
5
  numpy>=1.24.0
6
  tqdm>=4.65.0
7
  packaging