Data exploration is an important step of every data science and machine learning project, including those involving textual data. We provide a novel language tool, in the form of a publicly available Python library for extracting patterns from textual data. The library integrates a first public implementation of the existing GrASP algorithm. It allows users to extract patterns using a number of general-purpose built-in linguistic attributes (such as hypernyms, part-of-speech tags, and syntactic dependency tags), as envisaged for the original algorithm, as well as domain-specific custom attributes which can be incorporated into the library by implementing two functions. The library is equipped with a web-based interface empowering human users to conveniently explore data via the extracted patterns, using complementary pattern-centric and example-centric views: the former includes a reading in natural language and statistics of each extracted pattern; the latter shows applications of each extracted pattern to training examples. We demonstrate the usefulness of the library in classification (spam detection and argument mining), model analysis (machine translation), and artifact discovery in datasets (SNLI and 20Newsgroups).
翻译:每一个数据科学和机器学习项目,包括涉及文本数据的数据,都是数据探索的重要一步。我们以公开的Python图书馆的形式提供了一种新语言工具,用于从文本数据中提取模式。图书馆将现有的 GrASP算法的首次公开实施结合起来。它使用户能够利用一些通用内在语言属性(如原算法所设想的超音频、部分语音标记和综合依赖标记)以及特定域的定制属性来提取模式。图书馆配备了基于网络的界面,使人类用户能够通过提取模式方便地探索数据,使用以模式为中心的补充观点和以实例为中心的观点:前者包括自然语言阅读和每种提取模式的统计;后者显示了每种提取模式在培训实例方面的应用。我们展示了图书馆在分类(垃圾检测和论证挖掘)、模型分析(机器翻译)以及在数据集(SNLI和20Newsgroupes)中发现手工艺(SNLI和20Newsgroup)中的有用性。