Stemming Field with ORΒΆ
Example
>>> from pprint import pprint
>>> from techminer2.database.field_extractors import StemmingOrExtractor
>>> # Creates, configures, and runs the extractor
>>> extractor = (
... StemmingOrExtractor()
... #
... # FIELD:
... .with_field("author_keywords")
... #
... # SEARCH:
... .having_pattern(
... [
... "financial technology",
... "artificial intelligence",
... ],
... )
... #
... # DATABASE:
... .where_root_directory_is("example/")
... .where_database_is("main")
... .where_record_years_range_is(None, None)
... .where_record_citations_range_is(None, None)
... )
>>> terms = extractor.run()
>>> # Print the first 10 extracted terms
>>> pprint(terms[:10])
['ARTIFICIAL_INTELLIGENCE',
'DIGITAL_TECHNOLOGIES',
'FINANCE_TECHNOLOGY',
'FINANCIAL_COMPUTING',
'FINANCIAL_INCLUSION',
'FINANCIAL_INSTITUTION',
'FINANCIAL_INTERMEDIATION',
'FINANCIAL_MANAGEMENT',
'FINANCIAL_SCENARIZATION',
'FINANCIAL_SERVICE']