Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: nouvelle structure des métadonnées d'un article #1100

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

ggrossetie
Copy link
Collaborator

No description provided.

Copy link

netlify bot commented Nov 14, 2024

Deploy Preview for stylo-docs canceled.

Name Link
🔨 Latest commit 006c771
🔍 Latest deploy log https://app.netlify.com/sites/stylo-docs/deploys/6749db8793daf50008ae653f

Copy link

netlify bot commented Nov 14, 2024

Deploy Preview for stylo-dev ready!

Name Link
🔨 Latest commit 006c771
🔍 Latest deploy log https://app.netlify.com/sites/stylo-dev/deploys/6749db87051b7e000810e793
😎 Deploy Preview https://deploy-preview-1100--stylo-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ggrossetie
Copy link
Collaborator Author

Preview : https://rjsf-team.github.io/react-jsonschema-form/#eyJmb3JtRGF0YSI6eyJrZXl3b3JkcyI6W10sImZpcnN0TmFtZSI6IkNodWNrIiwibGFzdE5hbWUiOiJOb3JyaXMiLCJhZ2UiOjc1LCJiaW8iOiJSb3VuZGhvdXNlIGtpY2tpbmcgYXNzZXMgc2luY2UgMTk0MCIsInBhc3N3b3JkIjoibm9uZWVkIiwidGVsZXBob25lIjoiMS04MDAtS0lDS0FTUyJ9LCJzY2hlbWEiOnsiJHNjaGVtYSI6Imh0dHBzOi8vanNvbi1zY2hlbWEub3JnL2RyYWZ0LzIwMjAtMTIvc2NoZW1hIiwiJGlkIjoiaHR0cHM6Ly9zdHlsby5odW1hLW51bS5mci9zY2hlbWFzL2FydGljbGUtbWV0YWRhdGEuc2NoZW1hLmpzb24iLCJ0aXRsZSI6IkFydGljbGUgbWV0YWRhdGEiLCJ0eXBlIjoib2JqZWN0IiwiZGVmaW5pdG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oYXZpb3IiOnsiYXJyYXlNaW5JdGVtcyI6InBvcHVsYXRlIiwiYWxsT2YiOiJza2lwRGVmYXVsdHMiLCJlbXB0eU9iamVjdEZpZWxkcyI6InBvcHVsYXRlQWxsRGVmYXVsdHMiLCJtZXJnZURlZmF1bHRzSW50b0Zvcm1EYXRhIjoidXNlRm9ybURhdGFJZlByZXNlbnQifX19

@ggrossetie
Copy link
Collaborator Author

Exemple de métadonnées avec la structure actuelle :

{
  "abstract": [
    {
      "lang": "fr",
      "text_f": "Une honte totale nous envahit, à proportion de la stupeur du 24 février dernier. Quatre millions de personnes, surtout des femmes et des enfants, ont fui le risque mortel et connaissent les affres de l’exil. Six millions d’Ukrainiens de plus durent abandonner leur maison pour un lieu moins menacé du territoire national. La Russie a gagné : l’Ukraine détruite a perdu sa souveraineté, le temps des zones d’influence et des pactes militaires est de retour. La nouvelle guerre froide sera arbitrée par les puissances asiatiques, tandis que les soutiens dévoyés à la Russie de Poutine devront ravaler leurs inepties criminelles."
    },
    {
      "lang": "en",
      "text_f": "We are ashamed of ourselves, in proportion to the shock of February 24. Four million people, mostly women and children, have fled the mortal danger and are experiencing the agony of exile. Six million more Ukrainians had to abandon their homes for a less threatened part of the country. Russia has won: the destroyed Ukraine has lost its sovereignty, the time of zones of influence and military pacts has returned. The new Cold War will be mediated by the Asian powers, while the misguided supporters of Putin's Russia will have to swallow their criminal ineptitudes."
    }
  ],
  "authors": [
    {
      "forname": "Gérard",
      "orcid": "0000-0002-6651-1650",
      "surname": "Wormser"
    }
  ],
  "controlledKeywords": [
    {
      "idRameau": "FRBNF119313017",
      "label": "Europe",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb11931301w"
    },
    {
      "idRameau": "FRBNF13318436",
      "label": "Guerre et conflit",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb13318436b/"
    },
    {
      "idRameau": "FRBNF11975806",
      "label": "Politique et société",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb11975806s"
    }
  ],
  "date": "2022-04-14",
  "diffnum": "Érudit",
  "director": [
    {
      "forname": "Gérard",
      "orcid": "0000-0002-6651-1650 ",
      "surname": "Wormser"
    }
  ],
  "id": "SP1637",
  "issnnum": "2104-3272",
  "journal": "Sens public",
  "keywords": [
    {
      "lang": "fr",
      "list_f": [
        "Honte",
        "Ukraine",
        "Gauche",
        "Poutine",
        "Exil",
        "Photographie",
        "Presse"
      ]
    },
    {
      "lang": "en",
      "list_f": [
        "Shame",
        "Ukraine",
        "Left-wing",
        "Exile",
        "Photography",
        "Media"
      ]
    }
  ],
  "lang": "fr",
  "link-citations": true,
  "logocredits": "Volodymyr Zelensky visite Boutcha dévastée, à la veille de son intervention aux Nations-Unies. Le président ukrainien est sur *tous* les fronts depuis le 24 février 2022, son énergie a transcendé une situation impossible pour résister à l'invasion russe, renforcer l'appui militaire américain et européen, et galvaniser tant les corps d'armée que les secouristes et une population en état de choc.",
  "prod": "Sens public",
  "prodnum": "Sens public",
  "publisher": "Département des littératures de langue française",
  "rights": "Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)",
  "title_f": "Honteux, désarmés, décidés ! ",
  "typeArticle": [
    "Essai"
  ],
  "url_article": "/articles/1637"
}

Avec la nouvelle structure :

{
  "type": "article",
  "@version": "1.0",
  "id": "SP1637",
  "url": "/articles/1637",
  "publicationDate": "2022-04-14",
  "license": "CC-BY-SA-4.0",
  "lang": "fr",
  "title": "Honteux, désarmés, décidés !",
  "abstract":"Une honte totale nous envahit, à proportion de la stupeur du 24 février dernier. Quatre millions de personnes, surtout des femmes et des enfants, ont fui le risque mortel et connaissent les affres de l’exil. Six millions d’Ukrainiens de plus durent abandonner leur maison pour un lieu moins menacé du territoire national. La Russie a gagné : l’Ukraine détruite a perdu sa souveraineté, le temps des zones d’influence et des pactes militaires est de retour. La nouvelle guerre froide sera arbitrée par les puissances asiatiques, tandis que les soutiens dévoyés à la Russie de Poutine devront ravaler leurs inepties criminelles.",
  "keywords": [
    "Honte",
    "Ukraine",
    "Gauche",
    "Poutine",
    "Exil",
    "Photographie",
    "Presse"
  ],
  "localizedContent": [
    {
      "lang": "en",
      "abstract":"We are ashamed of ourselves, in proportion to the shock of February 24. Four million people, mostly women and children, have fled the mortal danger and are experiencing the agony of exile. Six million more Ukrainians had to abandon their homes for a less threatened part of the country. Russia has won: the destroyed Ukraine has lost its sovereignty, the time of zones of influence and military pacts has returned. The new Cold War will be mediated by the Asian powers, while the misguided supporters of Putin's Russia will have to swallow their criminal ineptitudes.",
      "keywords": [
        "Shame",
        "Ukraine",
        "Left-wing",
        "Exile",
        "Photography",
        "Media"
      ]
    }
  ],
  "authors": [
    {
      "forname": "Gérard",
      "orcid": "0000-0002-6651-1650",
      "surname": "Wormser"
    }
  ],
  "controlledKeywords": [
    {
      "idRameau": "FRBNF119313017",
      "label": "Europe",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb11931301w"
    },
    {
      "idRameau": "FRBNF13318436",
      "label": "Guerre et conflit",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb13318436b/"
    },
    {
      "idRameau": "FRBNF11975806",
      "label": "Politique et société",
      "uriRameau": "http://catalogue.bnf.fr/ark:/12148/cb11975806s"
    }
  ],
  "production": {
    "issn": "2104-3272",
    "diffnum": "Érudit",
    "producer": "Sens public",
    "prodNum": "Sens public"
  },
  "journal": {
    "name": "Sens public",
    "publisher": "Département des littératures de langue française"
  },
  "journalDirectors": [
    {
      "forname": "Gérard",
      "orcid": "0000-0002-6651-1650 ",
      "surname": "Wormser"
    }
  ],
  "@extra": {
    "logocredits": "Volodymyr Zelensky visite Boutcha dévastée, à la veille de son intervention aux Nations-Unies. Le président ukrainien est sur *tous* les fronts depuis le 24 février 2022, son énergie a transcendé une situation impossible pour résister à l'invasion russe, renforcer l'appui militaire américain et européen, et galvaniser tant les corps d'armée que les secouristes et une population en état de choc."
  }
}

@ggrossetie ggrossetie marked this pull request as ready for review November 26, 2024 22:03
"type": "string",
"title": "Last name"
},
"forname": {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

corriger la typo forname -> forename

},
abstract: abstract,
articleslies: [], // MISSING!
authors: metadata.authors,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Créer une méthode permettant de mapper les personnes, notamment le fait de mapper forename vers forname (legacy)

publicationDate: metadata.date,
url: metadata.url_article,
license: metadata.rights,
authors: metadata.authors,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Créer une méthode permettant de mapper les personnes, notamment le fait de mapper forname (legacy) vers forename

Comment on lines 242 to 243
"link-citations": "", // MISSING!
nocite: "", // MISSING!
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Informations déplacées dans l'export

Suggested change
"link-citations": "", // MISSING!
nocite: "", // MISSING!

funder_name: metadata.funder?.organization,
},
abstract: abstract,
articleslies: [], // MISSING!
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Plus utilisé ? à confirmer par @RochDLY

Suggested change
articleslies: [], // MISSING!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On ne permet pas/plus de le renseigner sur le formulaire actuel, est-ce que tu sais ce que doit contenir key et value ? Est-ce que c'est du spécifique Sens Public ?

Est-ce qu'on déplace la valeur dans senspublic.linkedarticles afin de conserver les données existantes mais on ne permet plus de renseigner les valeurs via le formulaire (uniquement possible en raw YAML) ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non je ne sais pas du tout ce qu'elle contiennent. Je vais vérifier à dans les archives de Sens Public. En attendant, on peut faire ce que tu proposes pour éviter que d'anciens articles soient cassés

translationOf: [
metadata.translationOf
],
translations: [], // MISSING!
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Plus utilisé ? à confirmer par @RochDLY

Suggested change
translations: [], // MISSING!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On ne permet pas/plus de le renseigner sur le formulaire actuel, est-ce que tu sais ce que doit contenir key et value ? Est-ce que c'est du spécifique Sens Public ?

Est-ce qu'on déplace la valeur dans senspublic.translations afin de conserver les données existantes mais on ne permet plus de renseigner les valeurs via le formulaire (uniquement possible en raw YAML) ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non je ne sais pas du tout ce qu'elle contiennent. Je vais vérifier à dans les archives de Sens Public. En attendant, on peut faire ce que tu proposes pour éviter que d'anciens articles soient cassés

],
translations: [], // MISSING!
translator: metadata.translators,
typeArticle: [], // MISSING!
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Faire un mapping à partir de metadata.senspublic.category

prodNum: metadata.prodnum,
diffNum: metadata.diffnum
},
localizedContent: localizedContent
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ajouter senspublic.category renseigné à partir de typeArticle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants