Upload app.py with huggingface_hub
Browse files
app.py
CHANGED
|
@@ -3,16 +3,17 @@
|
|
| 3 |
OpenLLM Real Models App - Final working version with correct attribute naming
|
| 4 |
"""
|
| 5 |
|
| 6 |
-
import gradio as gr
|
| 7 |
-
import torch
|
| 8 |
-
import torch.nn as nn
|
| 9 |
-
import torch.nn.functional as F
|
| 10 |
import json
|
| 11 |
import logging
|
| 12 |
-
import sentencepiece as spm
|
| 13 |
import math
|
| 14 |
from pathlib import Path
|
| 15 |
-
from typing import
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
from huggingface_hub import snapshot_download
|
| 17 |
|
| 18 |
# Set up logging
|
|
|
|
| 3 |
OpenLLM Real Models App - Final working version with correct attribute naming
|
| 4 |
"""
|
| 5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
import json
|
| 7 |
import logging
|
|
|
|
| 8 |
import math
|
| 9 |
from pathlib import Path
|
| 10 |
+
from typing import Any, Dict, Optional
|
| 11 |
+
|
| 12 |
+
import gradio as gr
|
| 13 |
+
import sentencepiece as spm
|
| 14 |
+
import torch
|
| 15 |
+
import torch.nn as nn
|
| 16 |
+
import torch.nn.functional as F
|
| 17 |
from huggingface_hub import snapshot_download
|
| 18 |
|
| 19 |
# Set up logging
|