sitammeur commited on
Commit
3044294
·
verified ·
1 Parent(s): 9ffd554

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -5
app.py CHANGED
@@ -19,9 +19,6 @@ from exception import CustomExceptionHandling
19
 
20
 
21
  # Download gguf model files
22
- llm = None
23
- llm_model = None
24
-
25
  hf_hub_download(
26
  repo_id="bartowski/Qwen2.5-Coder-1.5B-Instruct-GGUF",
27
  filename="Qwen2.5-Coder-1.5B-Instruct-Q6_K.gguf",
@@ -33,11 +30,15 @@ hf_hub_download(
33
  local_dir="./models",
34
  )
35
 
 
36
  # Set the title and description
37
  title = "Qwen-Coder Llama.cpp"
38
  description = """Qwen2.5-Coder, a six-model family of LLMs, boasts enhanced code generation, reasoning, and debugging. Trained on 5.5 trillion tokens, its 32B parameter model rivals GPT-4o, offering versatile capabilities for coding and broader applications."""
39
 
40
 
 
 
 
41
  def respond(
42
  message: str,
43
  history: List[Tuple[str, str]],
@@ -79,8 +80,8 @@ def respond(
79
  n_gpu_layers=0,
80
  n_batch=8,
81
  n_ctx=2048,
82
- n_threads=2,
83
- n_threads_batch=2,
84
  )
85
  llm_model = model
86
  provider = LlamaCppPythonProvider(llm)
 
19
 
20
 
21
  # Download gguf model files
 
 
 
22
  hf_hub_download(
23
  repo_id="bartowski/Qwen2.5-Coder-1.5B-Instruct-GGUF",
24
  filename="Qwen2.5-Coder-1.5B-Instruct-Q6_K.gguf",
 
30
  local_dir="./models",
31
  )
32
 
33
+
34
  # Set the title and description
35
  title = "Qwen-Coder Llama.cpp"
36
  description = """Qwen2.5-Coder, a six-model family of LLMs, boasts enhanced code generation, reasoning, and debugging. Trained on 5.5 trillion tokens, its 32B parameter model rivals GPT-4o, offering versatile capabilities for coding and broader applications."""
37
 
38
 
39
+ llm = None
40
+ llm_model = None
41
+
42
  def respond(
43
  message: str,
44
  history: List[Tuple[str, str]],
 
80
  n_gpu_layers=0,
81
  n_batch=8,
82
  n_ctx=2048,
83
+ n_threads=8,
84
+ n_threads_batch=8,
85
  )
86
  llm_model = model
87
  provider = LlamaCppPythonProvider(llm)