Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds Controlled Vocabulary Splitter 1.0.1.1, a generic plugin for OJS 3.5 that splits keywords, subjects, disciplines and supporting agencies pasted as a single line into the separate terms the author meant.
The problem
Authors often copy the whole keyword line of their manuscript and paste it into the keyword field:
That is stored as one controlled-vocabulary entry. Readers see a sentence where tags should be, keyword clouds show the whole phrase and
citation_keywordsgoes out as a single meta tag. In one journal we found it in every published article, in all three languages: 24 records that should have been 107 terms. Nothing in the currentplugins.xmladdresses it.What it does
Hypertension, Pregnancy-Inducedsurvives a list separated by semicolons.Law 13.964/2019) or a period closing a single letter (S. aureus,E. coli).PKP\cliTool\CommandLineTool) repairs an existing archive, dry run by default.How it plugs in
Core hooks only —
Publication::edit,Publication::addandnativexmlpublicationfilter::execute— with every write going throughRepo::controlledVocab(). No core class, template or UI component is replaced, and nothing is added to the reader-facing site. The hooks are registered unconditionally and each callback checks whether the plugin is enabled in the publication's journal, following pkp/pkp-lib#11793, so command-line imports are covered. Settings use the standard plugin settings form with POST and CSRF validation; at site level there is nothing to configure.Tests
PKP\tests\PKPTestCase(plugin classes against the installed PKP, splitting rules, the edit hook, site level, templates, 38 locales).pkp/pkp-github-actionson OJS 3.5 (PHP 8.2/8.3, MySQL/PostgreSQL) — green for this release.Checks run before opening this
xmllint --schema ./plugins.xsd ./plugins.xml --noout— validates.bae6c99265adfa4960a6b81603edfa0c) and the tarball unpacks as a singlecontrolledVocabSplitter/directory.3_5_0-0, hence~3.5.0.0.Use of generative AI
Generative AI (Claude, by Anthropic) was used to write and run tests, improve the code and bring it in line with PKP standards. Every change was reviewed and tested by OJSBR, which maintains the plugin and is responsible for its releases.
GPL-3.0 · https://github.com/OJSBR/controlledVocabSplitter