dsebaseapp stands for Digital (Scholarly) Editions Base Application. Its purpose is to bootstrap the development of (web) applications which support the process of
- and publishing
texts encoded in XML and validating against a TEI (P5) schema.
dsebaseapp based projects
dsebaseapp is a successor of the generic-de-web-app project described by the blog post series How to build a digital edition web app. While these blog posts were focused on describing general principles and basic implementations of a digital edition web app, dsebaseapp should help you getting things done. generic-de-web-app as well as dsebaseapp are designed as (almost) self-containing eXist-db packages. Therefore you can
- install your dse-web application via eXist-db’s package manager,
- download your dse-web app via eXist-db’s package manager,
- and tweak your app via eXist-db’s built in editor eXide.
Web app features
The application ships with the following default features:
A customizable (in terms of ordering and filtering) table of contents of documents stored in specific directories
Links from this table of contents to HTML views
Default XSLT transforms TEI documents into HTML
Full text search over all documents in the edition.
Linking between index entries (e.g. of persons, places, …) and mentions of those indices in the text (e.g. through
@ref) is supported.
Index based search
Access to data via simple API(s)
Timeline and Network visualisations
Map Visualisation of georeferenced places
several scripts for processing/enriching/harmonizing your data
an NLP (natural language processing) module for processing your data with 3rd party NLP services
autocomplete endpoints for entities
Clone the repo into a suitable directory. Be aware that the name of the applications root directory will show up in several places (e.g. the name of the application’s .xar package)
git clone https://github.com/KONDE-AT/dsebaseapp.git <folder-name>
Run a search and replace through the whole codebase, replacing
dsebaseappwith e.g. the name of your application’s root directory. Since
dsebaseappis used in several namespaces, make sure the replacement string does not contain any tricky characters.
Go through the
datadirectory and replace the existing data with your own. But keep the directory structure (
data/editions/, data/indices/, data/meta/) as it is.
Ideally, your data (structure, markup) is very similar to the application’s sample data – in this case most of the features mentioned above should work 'out of the box'.
After these initial changes try to build your application by running
antin your application’s root directory. This should create a
Install this package via eXist-db’s package manager.
Click through your application and start customizing.
The detail views of the 'regular' XML/TEIs is generated by a simple XML2HTML transformation using an XSLT stylesheet.
The stylesheet(s) used for this transformation are located in
<folder-name>/resources/xslt/. Which XSLT is going to be used for the transformation depends on the actual request.
- explictly: by adding an
stylesheetURL parameter providing the name of chosen styleseheet
- implictly I: if there is no
stylesheetparam provided, the for the transformation responsible function
app:XMLtoHTMLlooks in the
<folder-name>/resources/xslt/for a stylesheet with the same name as the collection where the to processed XML is located.
- a request like
/show.html?document=1771-IV-17.xml&directory=editionswill be processed by an XSLT
- a request like
- implictly II: if there is no
stylesheetparam provided and also no stylesheet named like the collection, the script will search for an XSLT with the same name as the XML. (But the order of those lookups might change in future)
- fallback: if no matching XSLT exists, the transformation uses a fallback XSLT which is declared in
- later defaults to
- later defaults to
<folder-name>/resources/xslt/shared/ contains to XSLTs (
base_index.xsl) which can be included in the actual processing templates because they provide common TEI to HTML transformation templates.
The index views for persons, places, … are created with XQuery functions, called through eXist-db’s templating system and stored in
<folder-name>/modules/app.xql. To find out which function is responsible for which view, look into the according
HTML. To modify e.g. the person index view called by the URL
.../pages/persons.html you need to
- search for the line(s) calling any template function like
- Look up this function in
- Tweak that function according to your needs.
- Make sure the number of returned columns match the HTML markup.