Skip to content

Commit

Permalink
change the index page and change the links to the API.
Browse files Browse the repository at this point in the history
  • Loading branch information
philippepons committed Oct 8, 2024
1 parent 76a314b commit 5b86de7
Show file tree
Hide file tree
Showing 5 changed files with 124 additions and 83 deletions.
20 changes: 10 additions & 10 deletions docs/cookbook/periodical.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ Le corpus de test est disponible : <a href="https://github.com/chartes/dots_docu

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=ENCPOS_1849")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=ENCPOS_1849")
}}

- Nous verrons qu’un document peut appartenir à plusieurs collections.
Expand Down Expand Up @@ -142,7 +142,7 @@ Exemples :

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=ENCPOS_1972")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=ENCPOS_1972")
}}

???+ note
Expand All @@ -166,7 +166,7 @@ Il permet de déclarer la structure du document TEI et de retrouver des fragment

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/navigation?resource=ENCPOS_1972_18&down=1")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=ENCPOS_1972_18&down=1")
}}

#### Créer la base de données
Expand Down Expand Up @@ -203,12 +203,12 @@ bash custom_collections.sh --collections_tsv_path 'path/to/tsv/file'

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=normandy")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=normandy")
}}

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=ENCPOS_1849_04&nav=parents")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=ENCPOS_1849_04&nav=parents")
}}

### Cas 2. Un article est un fragment
Expand Down Expand Up @@ -261,13 +261,13 @@ Le corpus de test est disponible : <a href="https://github.com/chartes/dots_docu
- Ici, le document `ENCPOS_1849_c2.xml`, par exemple, regroupe toutes les positions de 1849.
{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=ENCPOS_1972_c2")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=ENCPOS_1972_c2&down=1")
}}

- Chaque position est dans ce cas un fragment du document.
{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/navigation?resource=ENCPOS_1972_c2&ref=ENCPOS_1972_18")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=ENCPOS_1972_c2&ref=ENCPOS_1972_18")
}}

#### Dossier `metadata/`
Expand All @@ -278,7 +278,7 @@ Il contient les métadonnées descriptives : `default_resources_titles.tsv` per

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=ENCPOS_c2")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=ENCPOS_c2")
}}

#### Déclaration des fragments
Expand All @@ -298,12 +298,12 @@ L'élément `<citeStructure>` ( <a href="https://www.tei-c.org/release/doc/tei-p

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/navigation?resource=ENCPOS_1972_c2&ref=2320")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=ENCPOS_1972_c2&ref=2320")
}}

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/document?resource=ENCPOS_1972_c2&ref=2320")
url="https://dots.chartes.psl.eu/demo/api/dts/document?resource=ENCPOS_1972_c2&ref=2320")
}}

#### Créer la base de données
Expand Down
27 changes: 14 additions & 13 deletions docs/cookbook/theater.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ Le corpus de test est disponible : <a href="https://github.com/chartes/dots_docu

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=moliere")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=moliere")
}}

Un document pourra être inscrit dans d’autres collections ultérieurement.
Expand Down Expand Up @@ -140,14 +140,14 @@ Pour une collection : `api/dts/collection?id={collection_id}`, par exemple :

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=theater")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=theater")
}}

Pour une pièce : `api/dts/collection?id={document_id}`, par exemple :

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=moliere_tartuffe")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=moliere_tartuffe")
}}


Expand Down Expand Up @@ -253,7 +253,7 @@ Ces métadonnées – label et liage Wikidata du locuteur – sont ainsi accessi

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/navigation?resource=moliere_tartuffe&ref=a3-s2")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=moliere_tartuffe&ref=a3-s2")
}}


Expand Down Expand Up @@ -296,12 +296,12 @@ bash custom_collections.sh --collections_tsv_path path/to/tsv/file

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=comedie")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=comedie")
}}

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=moliere_tartuffe&nav=parents")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=moliere_tartuffe&nav=parents")
}}


Expand All @@ -315,31 +315,32 @@ Quelques exemples :

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/collection?id=moliere&filter=dc:date=1669")
url="https://dots.chartes.psl.eu/demo/api/dts/collection?id=moliere&filter=dc:date=1669")
}}


**Les références de tous les tours de parole (passages de niveau 3) de Tartuffe**

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/navigation?resource=moliere_tartuffe&down=3&filter=tei:role=Tartuffe")
url="https://dots.chartes.psl.eu/demo/api/dts/navigation?resource=moliere_tartuffe&down=3&filter=tei:role=Tartuffe")
}}

<!--
Mettre à jour DoTS sur le serveur de dev avant de décommenter ces lignes (code actuellement non fonctionnel)
**Le texte de tous les tours de parole de Tartuffe**

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/document?resource=moliere_tartuffe&filter=tei:role=Tartuffe")
url="https://dots.chartes.psl.eu/demo/api/dts/document?resource=moliere_tartuffe&filter=tei:role=Tartuffe")
}}


**Le texte de tous les tours de parole de Tartuffe en HTML pour republication**

{{ macro_collapse_card_api_doc(
verb_http="get",
url="https://dev.chartes.psl.eu/dots/api/dts/document?resource=moliere_tartuffe&filter=tei:role=Tartuffe&format=html")
url="https://dots.chartes.psl.eu/demo/api/dts/document?resource=moliere_tartuffe&filter=tei:role=Tartuffe&mediaType=html")
}}
-->

!!! warning

Pour bénéficier d'une version HTML d'un document ou d'un fragment, il est indispensable de fournir une feuille XSLT dans le dossier `path/to/basex/webapp/static/transform/hteiml`. Le chemin peut être modifié en changeant la variable `$G:xsl` du fichier `globals.xqm`. Le nom de la feuille XSLT doit être `tei2html.xsl`.
80 changes: 21 additions & 59 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,79 +1,41 @@
# DoTS
# Présentation

<img src="./assets/dots-logo-retro.drawio.svg" alt="dots-logo" width="30%" style="display: block; margin: 0 auto;">

## What is DoTS?
DoTS est une implémentation en XQuery de la spécification d'API DTS (<a href="https://distributed-text-services.github.io/specifications/" target="_blank">Distributed Text Services</a>), adossée au logiciel de base de données XML <a href="https://basex.org/" target="_blank">BaseX</a>.

DoTS is an XQuery implementation of DTS using a <a href="https://basex.org/" target="_blank">BaseX</a> backend.
Cet outil permet de publier aisément des sources en XML/TEI selon les principes FAIR (Findable, Accessible, Interoperable, Reusable).

!!! Note
La présente documentation indique :

**DoTS supports only DTS GET requests** for browsing collections, document retrieval and navigation.
- [comment installer DoTS](installation.md),
- et comment [organiser ses sources](dots-project-folder.md) TEI pour [publier un corpus](publishing-workflow.md).

## What is DTS?
## Code source

The <a href="https://distributed-text-services.github.io/specifications" target="_blank">Distributed Text Services</a> (DTS) Specification defines an API for working with collections of text as machine-actionable data.
Le code source de **DoTS** est disponible sous license MIT sur github à l'adresse suivante : <a href="https://github.com/chartes/dots" target="_blank">https://github.com/chartes/dots</a>.

Publishers of digital text collections can use the DTS API to help them make their textual data Findable, Accessible, Interoperable and Reusable (<a href="https://www.ccsd.cnrs.fr/principes-fair/" target="_blank">FAIR</a>).
La version actuelle respecte la dernière version 1-alpha de la spécification DTS.

## Capabilities
## Testez DoTS !

Using DoTS, you can
Si vous souhaitez tester notre résolveur DTS, les différents endpoints sont présentés [ici](api.md).
Le serveur de démo est aussi directement accessible à l'adresse suivante : <a href="https://dots.chartes.psl.eu/demo/api/dts/" target="_blank">https://dots.chartes.psl.eu/demo/api/dts/</a>.

- with the DTS Collection endpoint:
- Retrieve lists of collection members.
- Retrieve metadata about individual collection items.
- with the DTS Navigation endpoint:
- Retrieve lists of citeable passages within a text.
- Retrieve a range of citeable passages within a text.
- Retrieve metadata about the citation structure of a document.
- with the DTS Document endpoint:
- Retrieve a single text passage at any level of the citation hierarchy.
- Retrieve a range of text passages with a clearly defined start and end passage.
- Retrieve an entire text.
Les corpus qui s'y trouvent sont ceux présentés dans le [cookbook](cookbook/index.md) de cette documentation.

## Install
D'autres exemples vont venir en complément.

### BaseX
## Corpus disponibles

Download BaseX (>= 10.0): <a href="https://basex.org/download/" target="_blank">https://basex.org/download/</a>
### Corpus de l'école nationale des chartes

!!! info
Tous les corpus mis à disposition par l'école sont disponibles sur notre serveur <a href="https://dots.chartes.psl.eu/api/dts/collection" target="_blank">DoTS</a>.

- Prefer `ZIP Package`, which ensure that you will find the complete BaseX folder.
- Requirements : <a href="https://docs.basex.org/wiki/Startup#Startup" target="_blank">https://docs.basex.org/wiki/Startup#Startup</a>
Actuellement,seul le corpus des <a href="https://dots.chartes.psl.eu/api/dts/collection?id=ENCPOS" target="_blank">Positions de thèses de l'École nationale des chartes</a> est accessible, accompagné d'une <a href="https://theses.chartes.psl.eu/" target="_blank">application d'édition</a>.

### Autres corpus

### DoTS
DoTS étant un outil libre, d'autres institutions (particulièrement nos partenaires de Biblissima+) peuvent mettre leur corpus à disposition.

DoTS must be installed and started directly in the BaseX folder.

```Bash
cd path/to/basex/webapp
```

```{.Bash .copy}
git clone https://github.com/chartes/dots.git
```

The structure of your BaseX should be as follows:


basex/ # BaseX root dir.
bin/ # Start scripts (GUI, HTTP server, etc.).
data/ # Database directory.
webapp/ # Web Application directory.
dots/ # DoTS module (DTS reslover, etc.).
... # Others BaseX files.

## Start DTS resolver

```Bash
cd path/to/basex/bin
```

```{.Bash .copy}
bash basexhttp
```

By default, the base DTS API enpoint is available at <a href="http://localhost:8080/api/dts/" target="_blank">http://localhost:8080/api/dts/</a>.
Si vous avez partagé des corpus TEI grâce à DoTS, n'hésitez pas à nous le faire savoir !
77 changes: 77 additions & 0 deletions docs/installation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# DoTS

## What is DoTS?

DoTS is an XQuery implementation of DTS using a <a href="https://basex.org/" target="_blank">BaseX</a> backend.

!!! Note

**DoTS supports only DTS GET requests** for browsing collections, document retrieval and navigation.

## What is DTS?

The <a href="https://distributed-text-services.github.io/specifications" target="_blank">Distributed Text Services</a> (DTS) Specification defines an API for working with collections of text as machine-actionable data.

Publishers of digital text collections can use the DTS API to help them make their textual data Findable, Accessible, Interoperable and Reusable (<a href="https://www.ccsd.cnrs.fr/principes-fair/" target="_blank">FAIR</a>).

## Capabilities

Using DoTS, you can

- with the DTS Collection endpoint:
- Retrieve lists of collection members.
- Retrieve metadata about individual collection items.
- with the DTS Navigation endpoint:
- Retrieve lists of citeable passages within a text.
- Retrieve a range of citeable passages within a text.
- Retrieve metadata about the citation structure of a document.
- with the DTS Document endpoint:
- Retrieve a single text passage at any level of the citation hierarchy.
- Retrieve a range of text passages with a clearly defined start and end passage.
- Retrieve an entire text.

## Install

### BaseX

Download BaseX (>= 10.0): <a href="https://basex.org/download/" target="_blank">https://basex.org/download/</a>

!!! info

- Prefer `ZIP Package`, which ensure that you will find the complete BaseX folder.
- Requirements : <a href="https://docs.basex.org/wiki/Startup#Startup" target="_blank">https://docs.basex.org/wiki/Startup#Startup</a>


### DoTS

DoTS must be installed and started directly in the BaseX folder.

```Bash
cd path/to/basex/webapp
```

```{.Bash .copy}
git clone https://github.com/chartes/dots.git
```

The structure of your BaseX should be as follows:


basex/ # BaseX root dir.
bin/ # Start scripts (GUI, HTTP server, etc.).
data/ # Database directory.
webapp/ # Web Application directory.
dots/ # DoTS module (DTS reslover, etc.).
... # Others BaseX files.

## Start DTS resolver

```Bash
cd path/to/basex/bin
```

```{.Bash .copy}
bash basexhttp
```

By default, the base DTS API enpoint is available at <a href="http://localhost:8080/api/dts/" target="_blank">http://localhost:8080/api/dts/</a>.
3 changes: 2 additions & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ site_url: https://dots-documentation.github.io/
copyright: © 2023-2024 DoTS

nav:
- DoTS: index.md
- Présentation: index.md
- Installation: installation.md
- Publier un corpus: publishing-workflow.md
- Dossier de dépôt: dots-project-folder.md
- Cookbook:
Expand Down

0 comments on commit 5b86de7

Please sign in to comment.