perseids-project / perseids_docs

Project Documentation For Perseids
GNU General Public License v3.0
9 stars 4 forks source link

document create_from_agent integration approach #263

Open balmas opened 9 years ago

balmas commented 9 years ago

To get customized default epidoc templates (or skeletons) for your project, the means we have of supporting this right now in Perseids relies on the ability to provide an endpoint from which we can retrieve the data to populate the skeleton, preferably in XML. This allows the agent site to provide the list of texts to work on in whatever way is most appropriate for the project. This is the model we use for EAGLE.

Examples from the EAGLE interaction

  1. the EAGLE wiki presents a link to their users that looks something like

http://sosol.perseids.org/sosol/cts_publications/create_from_agent?agent=http://www.eagle-network.eu?&id=q58&lang=en

  1. Perseids uses the value of the agent param to look up its configuration how to a) retrieve data from EAGLE; and b) create a new publication in Perseids from that data; and c) define the default input form for the publication

So, In this case the system is configured to

(a) take the ID supplied in the query string and use it to construct a new request to the EAGLE mediawiki, e.g. http://www.eagle-network.eu/wiki/api.php?action=wbgetentities&ids=q58; and

(b) to transform the resulting XML via this transform: https://raw.githubusercontent.com/sosol/sosol/perseus_shibboleth/data/xslt/cts/eagle-xml-perseids.xsl ; and

(c) bring the user to the simplified text input form used for EAGLE

The XML returned by http://www.eagle-network.eu/wiki/api.php?action=wbgetentities&ids=q58 includes all of the data needed to construct the URN identifier for the new transcription as well as the EpiDoc template.

balmas commented 9 years ago

@fmcc I do have it documented -- in an issue which instructs me to document it! :)