Spaces:
Sleeping
Sleeping
cryptocalypse
commited on
Commit
•
df8af4f
1
Parent(s):
949d8d2
memory improvements, diferent bugs solved, search improvement, parsers
Browse files
app.py
CHANGED
@@ -15,10 +15,13 @@ except:
|
|
15 |
|
16 |
def els_book(book_num,prompt):
|
17 |
els_space = torah.gematria_sum(prompt)
|
18 |
-
|
19 |
-
|
20 |
-
|
|
|
|
|
21 |
|
|
|
22 |
|
23 |
|
24 |
def translate_texts(start, end, step, length=0, tlang="en", spaces_include=False, strip_in_braces=True, strip_diacritics=True):
|
@@ -102,7 +105,7 @@ with gr.Blocks(title="Sophia, Torah Codes") as demo:
|
|
102 |
els_results = gr.JSON(label="Results")
|
103 |
search_els.click(
|
104 |
els_book,
|
105 |
-
inputs=[
|
106 |
outputs=els_results
|
107 |
)
|
108 |
with gr.Row():
|
|
|
15 |
|
16 |
def els_book(book_num,prompt):
|
17 |
els_space = torah.gematria_sum(prompt)
|
18 |
+
res=[]
|
19 |
+
for bok in book_num:
|
20 |
+
response_els, tvalue = torah.els(bk, els_space, tracert='false')
|
21 |
+
text_translate = torah.func_translate('iw', 'en', response_els)
|
22 |
+
res.append({"Book":bk,"Prompt gematria":els_space,"ELS Generated":response_els,"ELS Translated": text_translate})
|
23 |
|
24 |
+
return res
|
25 |
|
26 |
|
27 |
def translate_texts(start, end, step, length=0, tlang="en", spaces_include=False, strip_in_braces=True, strip_diacritics=True):
|
|
|
105 |
els_results = gr.JSON(label="Results")
|
106 |
search_els.click(
|
107 |
els_book,
|
108 |
+
inputs=[books_sel,to_convert],
|
109 |
outputs=els_results
|
110 |
)
|
111 |
with gr.Row():
|