Closed nathangibson closed 2 years ago
By the way, in order to chain odds, we have to start from a pre-compiled schema, but this could be auto-generated as needed. Thus my schemaSpec/@source
is https://github.com/biblia-arabica/mss-catalog-pilot/blob/feature/constrained-schema-for-forms/schemas/mss-compiled.odd
@nathangibson I would rather that we cast a wider net – even as we limit ourselves to only msIdentifier and msContents. Consider the following additions:
forename
, surname
, persName
, addName
incipit
, explicit
, finalRubric
, colophon
Thanks @mMoliere I've updated it with your suggestions. We will certainly need more additions/subtractions (especially removing attributes). This is a work in progress to explore how radically reducing the schema affects the form generation and to start implementing the ODD chaining. But feel free to make more suggestions or to make edits yourself.
@nathangibson I added some more elements that seemed essential to me.
I noticed that the schema as of now contains elements used for critical text editing (add
, del
, unclear
…). Do we intend to use them in this stage? If not they should be excised (at least until we begin work on the XForms blocks that require them).
@mMoliere No, let's get rid of them for now.
OK, I removed those also and merged the pull request, but feel free to keep modifying the branch and do another pull request as needed.
Will do!
To do: Align with the options we discussed on 21.7. for text contents module
We should sit together and discuss which attributes we want to excise from which elements. It's fairly easy to do that in Roma. But I want to be on the same page regarding how the msItems
will connect to the various authority files etc. Is this something we should discuss before the meeting on Wednesday or do your prefer we schedule a date after the meeting?
@mMoliere I was thinking of @ref
on title
, author
, etc. Did you have another idea?
Edit: Meaning @ref
pointing to URIs for works, persons, etc.
@nathangibson I was thinking along the same lines. Good, then I'll put the axe to the other attributes.
@nathangibson So, I have made a pull request for this subset of the Schema. I hope that it will behave in the XForms the way we want it to.
@mMoliere Fantastic! Going through it right now.
@mMoliere Overall it looks like this worked really well and the attribute removal is pretty clean. However, a couple things remain:
msDesc
, msIdentifier
, msContents
, and msItem
: @cert
, @rend
, @rendition
, @style
, and @xml:base
. I'm not sure if this is best done through classes or individually. @decls
and @sortKey
from msDesc
msItem
, please restore the @xml:lang
attribute so that it can be used to mark transcriptions.Let me know if you have any questions.
@nathangibson It seems clear at the moment what is required. If I run into problems, I will get back to you.
@nathangibson I think the schema should now conform to what we discussed. Tell me if it needs further modifications.
@mMoliere Looks like it's all in order except msItem still needs @cert
, @rend
, @rendition
, @style
, and @xml:base
removed.
@nathangibson Sorry, for that oversight. I'll take care of it.
@mMoliere I'm trying to generate the RNG and compiled ODD from the mss-forms.odd but Oxygen is giving me an error. I'm using the up-to-date version of the TEI add-on (15.0.0) but an outdated version of Oxygen (18.1).
Are you able to do the transforms or do you also get an error?
Edit: It's actually just the ODD to RNG that gives an error.
See also #15
@nathangibson My OxygenXML is version 22. I also have trouble compiling the RNG. Strangely, I wasn't able to compile RNGs from other ODDs as well.
@mMoliere I think something weird is going on in https://github.com/biblia-arabica/mss-catalog-pilot/pull/14/commits/ddd8012a19f2fb62ac0af3ad6cfba8cc5def1a1e .
mss-forms-compiled.rng is only 186 lines and doesn't have msDesc at all. How/from what was it compiled?
The RNG I compiled for a previous version is 2800+ lines. (I think it essentially contains the entire TEI grammar.)
I'm not particularly familiar with RNG syntax but this is rather mystifying to me.
Cf #14
@nathangibson Since the compiler did not display any errors, the ODD is valid. But the RNG with that length can't be right. I'm trying to understand what went wrong.
I compiled the RNG from the updated mss-forms.odd on OxygenXML Editor 22.
Hmm, we might need to get help from the TEI mailing list or file an issue.
Are you using the TEI Plugin for Oxygen? What version is the plugin? (Help > Check for add-ons updates)
I am using the newest version of the TEI Plugin (15.0.0)
Hmm. Years ago when I had a problem with the transformation I was able to run it in the command line using ANT. (You can see this happening when it attempts the transform in Oxygen.) I don't remember anymore how to do this. Do you want to try it and if it doesn't work maybe ask on the TEI list or post an issue at https://github.com/TEIC/oxygen-tei ?
Or else what do you think we should try?
I have compiled mss-forms.odd from the branch feature/constrained-schema... which is the latest updated, successfully, should I push it to that branch?
my result RNG is quite long, and complete. I am not sure if the input file was the correct one.
Yes, thank you @PietroLiuzzo that would be wonderful! That is the correct source file and branch. You can overwrite mss-forms.rng.
Not sure what's going on for Max and me with Oxygen transforms. Any ideas? Here's what happens for me:
Executing:
"/Applications/Oxygen XML Editor/.install4j/jre.bundle/Contents/Home/jre/bin/java" -Dapple.awt.UIElement=true -Xmx256m -classpath "/Applications/Oxygen XML Editor/tools/ant/lib/ant-launcher.jar" "-Dant.home=/Applications/Oxygen XML Editor/tools/ant" org.apache.tools.ant.launch.Launcher -lib "/Applications/Oxygen XML Editor/classes" -lib "/Applications/Oxygen XML Editor/lib/oxygenAuthor.jar" -lib "/Applications/Oxygen XML Editor/lib/oxygenDeveloper.jar" -lib "/Applications/Oxygen XML Editor/lib/oxygenEclipse.jar" -lib "/Applications/Oxygen XML Editor/lib/oxygenAuthorEclipse.jar" -lib "/Applications/Oxygen XML Editor/lib/oxygenDeveloperEclipse.jar" -lib "/Applications/Oxygen XML Editor/lib/resolver.jar" -lib "/Applications/Oxygen XML Editor/lib/xercesImpl.jar" -lib "/Applications/Oxygen XML Editor/lib/saxon9ee.jar" -lib "/Applications/Oxygen XML Editor/lib/saxon9-sql.jar" -lib "/Applications/Oxygen XML Editor/lib/saxon.jar" -lib "/Applications/Oxygen XML Editor/lib/xml-apis-ext.jar" -lib "/Applications/Oxygen XML Editor/lib/log4j.jar" -lib "/Applications/Oxygen XML Editor/lib/oxygen-basic-utilities.jar" -f "/Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/relaxng/build-to.xml" "-DinputFile=/Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/mss-forms.odd" "-DoutputFile=/Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/out/mss-forms.rng" "-Dprofile=default" "-Dlang=en" "-Doxygenlib=/Applications/Oxygen XML Editor/lib" "-DdefaultSource=file:/Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/odd/p5subset.xml" "-Dwebhelp.trial.license=no"
Buildfile: /Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/relaxng/build-to.xml
go:
[echo] Do ODD expand processing (schema ${selectedSchema})
[xslt] Processing /Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/mss-forms.odd to /Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/mss-forms.odd.processedodd
[xslt] Loading stylesheet /Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/odds/odd2odd.xsl
[echo] XSLT generate relaxng files
[xslt] Processing /Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/mss-forms.odd.processedodd to /Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/out/mss-forms.rng
[xslt] Loading stylesheet /Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/profiles/default/relaxng/to.xsl
[xslt] /Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/odds/odd2relax.xsl:471:51: Fatal Error! Concatenation operator ('||') requires XPath 3.0 to be enabled
[xslt] Failed to process /Users/blah/Github/biblia-arabica/mss-catalog-pilot/schemas/mss-forms.odd.processedodd
BUILD FAILED
/Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/relaxng/build-to.xml:30: The following error occurred while executing this line:
/Users/blah/Library/Preferences/com.oxygenxml/extensions/v18.1/frameworks/http___www.tei_c.org_release_oxygen_updateSite.oxygen/tei/xml/tei/stylesheet/common/teianttasks.xml:355: javax.xml.transform.TransformerConfigurationException: net.sf.saxon.s9api.SaxonApiException: Stylesheet compilation failed: 1 error reported
at net.sf.saxon.jaxp.SaxonTransformerFactory.newTemplates(SaxonTransformerFactory.java:155)
...
its in the default out/ directory. let me know if that is what you where trying to achieve. I have no idea why it fails. I am running oxygen 20.1 (yeah... licence...) and using the dev version of the framework. but perhaps it has the same error as the one you are discussing and I simply failed to understand. I did not follow all the conversation.
No problem, yes, it looks right and I moved it to the schemas directory.
I'll do some checking around on the error when I get time.
Thank you @PietroLiuzzo !
@mMoliere You can close this when you're ready.
@wsalesky I've started creating a constrained schema that should allow the basic stuff needed for msIdentifier and msContents (see #10 ). It still allows too many elements and attributes, but can you tell me if it's going in the right direction?
https://github.com/biblia-arabica/mss-catalog-pilot/blob/feature/constrained-schema-for-forms/schemas/mss-forms.odd
Also, does compiling an odd such as https://github.com/biblia-arabica/mss-catalog-pilot/blob/feature/constrained-schema-for-forms/schemas/mss-forms-compiled.odd using the odd2odd.xsl provided with TEI stylesheets allow you to not have to look at the parent ODD?
CC: @mMoliere