feat: support French epithets in character extraction logic
All checks were successful
Build Docker Image / build (push) Successful in 1m14s
All checks were successful
Build Docker Image / build (push) Successful in 1m14s
This commit is contained in:
@@ -635,7 +635,9 @@ async function extractAffiliations($: cheerio.CheerioAPI, lang: string): Promise
|
|||||||
* Handles both quoted and unquoted epithets, keeping only the main/latest readable values.
|
* Handles both quoted and unquoted epithets, keeping only the main/latest readable values.
|
||||||
*/
|
*/
|
||||||
function extractEpithets($: cheerio.CheerioAPI): string[] {
|
function extractEpithets($: cheerio.CheerioAPI): string[] {
|
||||||
const div = $('[data-source="epithet"] .pi-data-value');
|
const div = $(
|
||||||
|
'[data-source="epithet"] .pi-data-value, [data-source="épithète"] .pi-data-value'
|
||||||
|
).first();
|
||||||
if (div.length === 0) return [];
|
if (div.length === 0) return [];
|
||||||
|
|
||||||
const cleanedDiv = div.clone();
|
const cleanedDiv = div.clone();
|
||||||
|
|||||||
Reference in New Issue
Block a user