Javierss
commited on
Commit
·
90e4a0d
1
Parent(s):
2d20748
Rm some comments
Browse files- app.py +0 -4
- data/ranking.txt +1 -1
- game_transformer.py +0 -24
- game_word2vec.py +0 -21
app.py
CHANGED
|
@@ -22,7 +22,6 @@ else:
|
|
| 22 |
|
| 23 |
|
| 24 |
def convert_to_markdown_centered(text):
|
| 25 |
-
# Separar el texto de último intento y el historial
|
| 26 |
lines = text.strip().split("\n")
|
| 27 |
|
| 28 |
if not lines:
|
|
@@ -30,10 +29,8 @@ def convert_to_markdown_centered(text):
|
|
| 30 |
|
| 31 |
last_attempt = lines[0]
|
| 32 |
history_attempts = lines[2:12]
|
| 33 |
-
# Crear el formato Markdown
|
| 34 |
markdown = '<div align="center">\n\n'
|
| 35 |
|
| 36 |
-
# Crear la tabla de historial
|
| 37 |
markdown += "## " + Menu["Best_tries"] + "\n"
|
| 38 |
markdown += "<table>\n"
|
| 39 |
markdown += " <tr>\n"
|
|
@@ -52,7 +49,6 @@ def convert_to_markdown_centered(text):
|
|
| 52 |
|
| 53 |
markdown += "</table>\n\n"
|
| 54 |
|
| 55 |
-
# Formatear el último intento
|
| 56 |
last_items = eval(last_attempt)
|
| 57 |
markdown += f"## " + Menu["Last_try"] + "\n"
|
| 58 |
markdown += (
|
|
|
|
| 22 |
|
| 23 |
|
| 24 |
def convert_to_markdown_centered(text):
|
|
|
|
| 25 |
lines = text.strip().split("\n")
|
| 26 |
|
| 27 |
if not lines:
|
|
|
|
| 29 |
|
| 30 |
last_attempt = lines[0]
|
| 31 |
history_attempts = lines[2:12]
|
|
|
|
| 32 |
markdown = '<div align="center">\n\n'
|
| 33 |
|
|
|
|
| 34 |
markdown += "## " + Menu["Best_tries"] + "\n"
|
| 35 |
markdown += "<table>\n"
|
| 36 |
markdown += " <tr>\n"
|
|
|
|
| 49 |
|
| 50 |
markdown += "</table>\n\n"
|
| 51 |
|
|
|
|
| 52 |
last_items = eval(last_attempt)
|
| 53 |
markdown += f"## " + Menu["Last_try"] + "\n"
|
| 54 |
markdown += (
|
data/ranking.txt
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
---------------------------
|
|
|
|
| 1 |
+
---------------------------
|
game_transformer.py
CHANGED
|
@@ -112,30 +112,6 @@ class Semantrix:
|
|
| 112 |
for item in ranking_data:
|
| 113 |
file.write("%s\n" % item)
|
| 114 |
|
| 115 |
-
# if len(self.words) > 11:
|
| 116 |
-
# if k in descending_indices[:11]:
|
| 117 |
-
# descending_indices = descending_indices[:11]
|
| 118 |
-
# else:
|
| 119 |
-
# descending_indices = descending_indices[:11]
|
| 120 |
-
# descending_indices.append(k)
|
| 121 |
-
# words_display = [self.words[i] for i in descending_indices]
|
| 122 |
-
# # displayvect_display = pca.transform([word_vect[i] for i in descending_indices])
|
| 123 |
-
# scores_display = [self.scores[i] for i in descending_indices]
|
| 124 |
-
# bold = descending_indices.index(k)
|
| 125 |
-
|
| 126 |
-
# else:
|
| 127 |
-
# words_display = self.words
|
| 128 |
-
# # displayvect_display = pca.transform(word_vect)
|
| 129 |
-
# scores_display = self.scores
|
| 130 |
-
# bold = k
|
| 131 |
-
|
| 132 |
-
# return (
|
| 133 |
-
# words_display,
|
| 134 |
-
# # displayvect_display,
|
| 135 |
-
# scores_display,
|
| 136 |
-
# bold,
|
| 137 |
-
# )
|
| 138 |
-
|
| 139 |
def play_game(self, word):
|
| 140 |
|
| 141 |
word = word.lower()
|
|
|
|
| 112 |
for item in ranking_data:
|
| 113 |
file.write("%s\n" % item)
|
| 114 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 115 |
def play_game(self, word):
|
| 116 |
|
| 117 |
word = word.lower()
|
game_word2vec.py
CHANGED
|
@@ -104,27 +104,6 @@ class Semantrix:
|
|
| 104 |
for item in ranking_data:
|
| 105 |
file.write("%s\n" % item)
|
| 106 |
|
| 107 |
-
# if len(self.words) > 11:
|
| 108 |
-
# if k in descending_indices[:11]:
|
| 109 |
-
# descending_indices = descending_indices[:11]
|
| 110 |
-
# else:
|
| 111 |
-
# descending_indices = descending_indices[:11]
|
| 112 |
-
# descending_indices.append(k)
|
| 113 |
-
# words_display = [self.words[i] for i in descending_indices]
|
| 114 |
-
# scores_display = [self.scores[i] for i in descending_indices]
|
| 115 |
-
# bold = descending_indices.index(k)
|
| 116 |
-
|
| 117 |
-
# else:
|
| 118 |
-
# words_display = self.words
|
| 119 |
-
# scores_display = self.scores
|
| 120 |
-
# bold = k
|
| 121 |
-
|
| 122 |
-
# return (
|
| 123 |
-
# words_display,
|
| 124 |
-
# scores_display,
|
| 125 |
-
# bold,
|
| 126 |
-
# )
|
| 127 |
-
|
| 128 |
def play_game(self, word):
|
| 129 |
|
| 130 |
word = word.lower()
|
|
|
|
| 104 |
for item in ranking_data:
|
| 105 |
file.write("%s\n" % item)
|
| 106 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 107 |
def play_game(self, word):
|
| 108 |
|
| 109 |
word = word.lower()
|