Dado que los equipos están comenzando a usar Glyssen para preprocesar sus textos del NT e identificar a cada hablante en el texto para una grabación dramatizada, me pregunté si valdría la pena aprovechar ese trabajo para marcar AUTOMÁTICAMENTE las Palabras de Jesús \wj … \wj* en el proyecto de Paratext.
Glyssen produce un archivo de Excel con los datos necesarios, que se ve así:

image.png1171×522 59.8 KB
Por lo tanto, debería ser relativamente fácil generar un script para encontrar estos lugares en el texto y envolverlos con la marca \wj … \wj*
Yo mismo probé algo simple con un par de tablas CC generadas y logré marcar con éxito el 88% de las 1901 ocurrencias de las palabras de Jesús. Sin embargo, esto deja más de 200 lugares donde tendría que entrar y corregirlo manualmente. No satisfecho con este resultado, y queriendo ahorrar tiempo a otros en el futuro haciéndolo automatizado, completo y más a prueba de errores, me pregunté sobre la creación de un Script Personalizado (en Python) que pudiera realizar esta tarea directamente desde Paratext.
La mayoría de los casos “fallidos” con el método CC se deben a otras marcas como \w angel|angels\w* o \f notas al pie y \x referencias cruzadas que están incrustadas dentro del texto que se busca. Tengo algunas ideas sobre cómo sortearlos usando Expresiones Regulares (y buscando el inicio y el final de las cadenas en lugar de la cadena completa, etc.), pero eso va más allá de CC y requeriría usar algo de código Python para hacerlo posible.
PERO, antes de intentar crear un Script Personalizado para hacer esto, me pregunto si alguien más ya ha hecho algo similar. ¡No quiero reinventar la rueda! Mirando los scripts de muestra que se entregan con Paratext, lo más cercano que veo es TransferParallelPassageRefs.py de DRM.
¿Alguien más tiene algo similar, o hay alguien más con más talento para la programación en Python con ScriptureObjects que podría armar esto mejor de lo que yo podría? Estoy dispuesto a escribir el pseudocódigo si eso ayuda. Y estoy dispuesto a aprender y trabajar con otra persona en esto…
Given that teams are starting to use Glyssen to pre-process their NT texts to identify each speaker in the text for a dramatized recording, I wondered whether it would be worth piggy-backing on that work to AUTOMATICALLY mark up the Words of Jesus \wj … \wj* in the Paratext project.
Glyssen produces an Excel file with the needed data in it, which looks like this:

image.png1171×522 59.8 KB
So it should be relatively easy to generate a script to find these places in the text and wrap them with the \wj … markup …\wj*
I tried something simple myself with a couple of generated CC tables, and managed to get 88% of the 1901 occurrences of the words of Jesus marked up successfully. However, this still leaves 200+ places where I would need to go in and fix it manually. Being unsatisfied with this result, and wanting to save others time in the future by making it automated, complete and more foolproof, I wondered about creating a Custom Script (in Python) that could do this task directly from within Paratext.
Most of the “failed” cases with the CC method are because of other markup like \w angel|angels\w* or \f footnotes and \x cross-references being embedded within the text being searched for. I’ve got some ideas about how to get around those using Regular Expressions (and searching for the start and end of strings rather than the whole string, etc.) but that is beyond CC and would need to use some Python code to make it possible.
BUT, before I attempt to make a Custom Script to do this, I’m wondering if anyone else has done something similar already. I don’t want to re-invent the wheel! Looking at the sample scripts shipped with Paratext, the closest thing I see is TransferParallelPassageRefs.py by DRM.
Does anyone else have something similar, or is anyone else more gifted at Python programming with ScriptureObjects who could pull this together better than I ever could? I’m willing to write the pseudo code if that’s helpful. And I’m willing to learn and work with someone else on this…
Traducción automática desde English