cheminfo / octochemdb

https://octochemdb.cheminfo.org/documentation/static/index.html
MIT License
1 stars 0 forks source link

Improve patent abstract #108

Closed lpatiny closed 1 year ago

lpatiny commented 1 year ago

You could decode HTML (XML) entities for the abstract (at least, maybe the title as well).

you could use:

https://www.npmjs.com/package/he/v/1.2.0

Or do it manually using those urles

function parseHtmlEntities(str) {
    return str.replace(/&#([0-9]{1,3});/gi,(match, numStr) => {
        var num = parseInt(numStr, 10); // read num as normal number
        return String.fromCharCode(num);
    });
}

abstract: 'Disclosed are compositions and formulations comprising or consisting of, for example, N, N' -dimethyl 3, 4-dimethoxy-beta-phenylethylamine and/or a pharmacologically acceptable salt thereof, and methods use of said compositions and formulations, e.g. , to reduce caloric intake in a mammal.' },

'US-5668131-A': { title: 'Substituted aminoalkylaminopyridines', abstract: 'PCT No. PCT/EP94/03911 Sec. 371 Date May 31, 1996 Sec. 102(e) Date May 31, 1996 PCT Filed Nov. 26, 1994 PCT Pub. No. WO95/15324 PCT Pub. Date Jun. 8, 1995Compounds of formula I <IMAGE> (I) wherein R1, R2, R3, R4, R5, R6, X, n and A have the meanings as given in the description, can be used for combatting Helicobacter bacteria.' },