pablo-rf commited on
Commit
ba66610
1 Parent(s): a3fc523

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -8
app.py CHANGED
@@ -5,17 +5,17 @@ import torch
5
  from transformers import pipeline
6
 
7
  # Model, information and examples ----------------------------------------------
8
- MODEL_NAMES = ["FLOR-1.3B-GL","Cerebras-1.3B-GL"]
9
  markdown_description_gl = """
10
  [*English below*]
11
 
12
  Este espazo contén diferentes Grandes Modelos da Linguaxe feitos para o galego desenvolvidos polo [Proxecto Nós](https://nos.gal/en/proxecto-nos).
13
 
14
- 💐 **[FLOR-1.3B-GL](https://huggingface.co/proxectonos/FLOR-1.3B-GL)** é un modelo de parámetros 1.3B que é un preadestramento continuo de [FLOR-1.3B]( https://huggingface.co/projecte-aina/FLOR-1.3B), baseado a súa vez en [Bloom 1.7B](https://huggingface.co/bigscience/bloom-1b7).
15
 
16
  👀 **Máis información sobre FLOR-1.3B-GL:** [tarxeta modelo oficial HF](https://huggingface.co/proxectonos/FLOR-1.3B-GL).
17
 
18
- 🧠 **[Cerebras-1.3B-GL](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)** é un modelo de parámetros 1.3B baseado en [Cerebras-GPT 1.3B](https://huggingface.co/cerebras/Cerebras-GPT-1.3B).
19
 
20
  👀 **Máis información sobre Cerebras-1.3B-GL:** [tarxeta modelo oficial HF](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)
21
  """
@@ -24,11 +24,11 @@ markdown_description_en = """
24
  ## English description
25
  This space contains the Galician language models developed by [Proxecto Nós](https://nos.gal/en/proxecto-nos).
26
 
27
- 💐 **[FLOR-1.3B-GL](https://huggingface.co/proxectonos/FLOR-1.3B-GL)** is a 1.3B parameters model which is a Continual pretraining from [FLOR-1.3B](https://huggingface.co/projecte-aina/FLOR-1.3B), which is based in [Bloom 1.7B](https://huggingface.co/bigscience/bloom-1b7).
28
 
29
  👀 **Learn more about FLOR-1.3B-GL:** [HF official model card](https://huggingface.co/proxectonos/FLOR-1.3B-GL).
30
 
31
- 🧠 **[Cerebras-1.3B-GL](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)** is a 1.3B parameters model based in [Cerebras-GPT 1.3B](https://huggingface.co/cerebras/Cerebras-GPT-1.3B).
32
 
33
  👀 **Learn more about Cerebras-1.3B-GL:** [HF official model card](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)
34
  """
@@ -47,14 +47,14 @@ few_shot_prompts_examples = [
47
  fronted_theme = 'Soft'
48
 
49
  # Model charge ---------------------------------------------------------
50
- model_id_flor = "proxectonos/FLOR-1.3B-GL"
51
  generator_model_flor = pipeline("text-generation", model=model_id_flor)
52
- model_id_cerebras = "proxectonos/Cerebras-1.3B-GL"
53
  generator_model_cerebras = pipeline("text-generation", model=model_id_cerebras, token=os.environ['TOKEN_HF'])
54
 
55
  # Generation functions ---------------------------------------------------------
56
  def get_model(model_selection):
57
- if model_selection == "FLOR-1.3B-GL":
58
  return generator_model_flor
59
  else:
60
  return generator_model_cerebras
 
5
  from transformers import pipeline
6
 
7
  # Model, information and examples ----------------------------------------------
8
+ MODEL_NAMES = ["Carballo-bloom-1.3B","Carballo-cerebras-1.3B"]
9
  markdown_description_gl = """
10
  [*English below*]
11
 
12
  Este espazo contén diferentes Grandes Modelos da Linguaxe feitos para o galego desenvolvidos polo [Proxecto Nós](https://nos.gal/en/proxecto-nos).
13
 
14
+ 💐 **[Carballo-bloom-1.3B](https://huggingface.co/proxectonos/Carballo-bloom-1.3B)** é un modelo de parámetros 1.3B que é un preadestramento continuo de [FLOR-1.3B]( https://huggingface.co/projecte-aina/FLOR-1.3B), baseado a súa vez en [Bloom 1.7B](https://huggingface.co/bigscience/bloom-1b7).
15
 
16
  👀 **Máis información sobre FLOR-1.3B-GL:** [tarxeta modelo oficial HF](https://huggingface.co/proxectonos/FLOR-1.3B-GL).
17
 
18
+ 🧠 **[Carballo-cerebras-1.3B](https://huggingface.co/proxectonos/Carballo-cerebras-1.3B)** é un modelo de parámetros 1.3B baseado en [Cerebras-GPT 1.3B](https://huggingface.co/cerebras/Cerebras-GPT-1.3B).
19
 
20
  👀 **Máis información sobre Cerebras-1.3B-GL:** [tarxeta modelo oficial HF](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)
21
  """
 
24
  ## English description
25
  This space contains the Galician language models developed by [Proxecto Nós](https://nos.gal/en/proxecto-nos).
26
 
27
+ 💐 **[Carballo-bloom-1.3B](https://huggingface.co/proxectonos/Carballo-bloom-1.3B)** is a 1.3B parameters model which is a Continual pretraining from [FLOR-1.3B](https://huggingface.co/projecte-aina/FLOR-1.3B), which is based in [Bloom 1.7B](https://huggingface.co/bigscience/bloom-1b7).
28
 
29
  👀 **Learn more about FLOR-1.3B-GL:** [HF official model card](https://huggingface.co/proxectonos/FLOR-1.3B-GL).
30
 
31
+ 🧠 **[Carballo-cerebras-1.3B](https://huggingface.co/proxectonos/Carballo-cerebras-1.3B)** is a 1.3B parameters model based in [Cerebras-GPT 1.3B](https://huggingface.co/cerebras/Cerebras-GPT-1.3B).
32
 
33
  👀 **Learn more about Cerebras-1.3B-GL:** [HF official model card](https://huggingface.co/proxectonos/Cerebras-1.3B-GL)
34
  """
 
47
  fronted_theme = 'Soft'
48
 
49
  # Model charge ---------------------------------------------------------
50
+ model_id_flor = "proxectonos/Carballo-bloom-1.3B"
51
  generator_model_flor = pipeline("text-generation", model=model_id_flor)
52
+ model_id_cerebras = "proxectonos/Carballo-cerebras-1.3B"
53
  generator_model_cerebras = pipeline("text-generation", model=model_id_cerebras, token=os.environ['TOKEN_HF'])
54
 
55
  # Generation functions ---------------------------------------------------------
56
  def get_model(model_selection):
57
+ if model_selection == "Carballo-bloom-1.3B":
58
  return generator_model_flor
59
  else:
60
  return generator_model_cerebras