Data preparation using semantic role
The method addresses the challenge of preparing complex datasets for visualization by using semantic roles and concept graphs to automate data processing, enhancing data preparation and visualization through intelligent data manipulation and validation.
Patent Information
- Application Number
- JP2024098885
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2019-11-10
- Filing Date
- 2024-06-19
- Publication Date
- 2024-10-23
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing data visualization applications struggle with processing large and complex datasets, requiring significant manual manipulation and specialized knowledge to prepare data for meaningful visualization, lacking an understanding of data semantics that limits user experience.
A method for data preparation that utilizes semantic roles to clean and transform data fields within a data model, incorporating concept graphs and user interfaces to automate data processing and enhance data understanding.
Enhances data preparation by automating data manipulation and providing intelligent data validation, reducing user expertise requirements and improving data visualization outcomes.
Smart Images

Figure 2024150441000001_ABST
Abstract
Description
[Technical field]
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS This application is related to U.S. patent application Ser. No. 16 / 234,470, filed Dec. 27, 2018, entitled “Analyzing Underspecified Natural Language Utterances in a Data Visualization User Interface,” the entire contents of which are incorporated herein by reference.
[0002] This application is also related to U.S. patent application Ser. No. 16 / 221,413, entitled “Data Preparation User Interface with Coordinated Pivots,” filed Dec. 14, 2018, the entirety of which is incorporated herein by reference.
[0003] This application is also related to U.S. patent application Ser. No. 16 / 236,611, entitled “Generating Data Visualizations According to an Object Model of Selected Data Sources,” filed Dec. 30, 2018, the entirety of which is incorporated herein by reference.
[0004] This application is also related to U.S. patent application Ser. No. 16 / 236,612, entitled “Generating Data Visualizations According to an Object Model of Selected Data Sources,” filed Dec. 30, 2018, the entirety of which is incorporated herein by reference.
[0005] The disclosed implementations relate generally to data visualization, and more specifically to systems, methods, and user interfaces for preparing and curating data for use by data visualization applications. [Background technology]
[0006] Data visualization applications allow users to visually understand data sets, including distributions, trends, outliers, and other factors important to making business decisions. Some data sets are very large or complex and contain many data fields. Various tools can be used to understand and analyze the data, such as dashboards with multiple data visualizations. However, data frequently needs to be manipulated or processed to get it into a format that can be easily used by data visualization applications. Summary of the Invention
[0007] The disclosed implementations provide a method for cleaning up and / or replacing data values in a dataset based on the semantic roles of data fields and can be used as part of a data preparation application.
[0008] According to some implementations, a method prepares data for subsequent analysis. The method is executed on a computer having a display, one or more processors, and a memory storing one or more programs configured to be executed by the one or more processors. The method includes obtaining a data model that encodes a first data source as a tree of logical tables. Each logical table has its own physical representation and includes one or more logical fields. Each logical field corresponds to either a data field or a calculated value that spans one or more logical tables. Each edge of the tree connects two related logical tables. The method also includes associating each logical table in the data model with a corresponding concept in a conceptual graph. The conceptual graph (e.g., a directed acyclic graph) embodies a hierarchical inheritance of the semantics of the logical tables. The method also includes, for each logical field included in the logical table, assigning a semantic role to the logical field based on the concept that corresponds to the logical table. The method also includes validating the logical field based on its assigned semantic role. The method further includes displaying, in a user interface on the display, one or more transformations for cleaning up (or filtering) the logical field based on validation of the logical field. In response to detecting user input selecting a transformation for transforming the logical field, the method transforms the logical field according to the user input and updates the logical table based on transforming the logical field.
[0009] In some implementations, the method further includes storing, for each logical field, its assigned semantic role in the first data source (or the auxiliary data source).
[0010] In some implementations, the method further includes generating a second data source based on the first data source and, for each logical field, storing its assigned semantic role in the second data source.
[0011] In some implementations, the method further includes retrieving, for each logical field, a representative semantic role (e.g., a semantic role assigned to a similar logical field) from a second data source different from the first data source. Assigning a semantic role to the logical field is further based on the representative semantic role. In some implementations, user input is detected from the first user, and the method further includes determining whether the first user is authorized to access the second data source before retrieving the representative semantic role from the second data source.
[0012] In some implementations, the semantic role includes a domain of the logical field, and validating the logical field includes determining whether the logical field matches one or more domain values of the domain. The method further includes determining the one or more transformations based on the one or more domain values before displaying the one or more transformations.
[0013] In some implementations, a semantic role is a validation rule (eg, a regular expression) used to validate a logical field.
[0014] In some implementations, the method further includes displaying, in the user interface, a first one or more semantic roles of the first logical field based on a concept corresponding to a first logical table that includes the first logical field. The method also includes assigning a preferred semantic role to the first logical field in response to detecting a user input selecting a preferred semantic role. In some implementations, the method further includes selecting a second one or more semantic roles of the second logical field based on the preferred semantic role. The method also includes displaying, in the user interface, a second one or more semantic roles of the second logical field. In response to detecting a second user input selecting a second semantic role from the second one or more semantic roles, the method includes assigning a second semantic role to the second logical field. In some implementations, the method further includes training one or more predictive models based on one or more semantically labeled data sources (e.g., data sources including data fields that have been assigned or labeled with semantic roles). The method also includes determining the first one or more semantic roles by inputting concepts corresponding to the first logical table into one or more predictive models.
[0015] In some implementations, the method further includes detecting changes to the first data source. In response to detecting the changes to the first data source, the method includes updating the conceptual graph according to the changes to the first data source, and repeating the assigning, validating, displaying, converting, and updating for each logical field according to the updated conceptual graph. In some implementations, detecting changes to the first data source is performed at a predetermined time interval.
[0016] In some implementations, the logical field is a calculated value based on the first data field and the second data field. Assigning a semantic role to the logical field is further based on a first semantic role corresponding to the first data field and a second semantic role corresponding to the second data field.
[0017] In some implementations, the method includes determining a default format of a data field that corresponds to the logical field. Assigning a semantic role to the logical field is further based on the default format of the data field.
[0018] In some implementations, the method further includes selecting and storing in the first data source default formatting options for displaying the logical field based on the assigned semantic role.
[0019] In some implementations, the method further includes displaying the conceptual graph in a user interface and one or more options for modifying the conceptual graph prior to assigning semantic roles to the logical fields. In response to detecting user input to modify the conceptual graph, the method includes updating the conceptual graph according to the user input.
[0020] In some implementations, the method further includes determining a first logical field to add to the first logical table based on a concept of the first logical table. The method also includes displaying a suggestion to add the first logical field in a user interface. In response to detecting a user input to add the first logical field, the method includes updating the first logical table to include the first logical field.
[0021] In some implementations, the method further includes determining a second dataset corresponding to the second data source for joining with the first dataset corresponding to the first data source based on the conceptual graph. The method also includes displaying, in a user interface, a suggestion to join the second dataset with the first dataset of the first data source. In response to detecting a user input to join the second dataset, the method also includes creating a join between the first dataset and the second dataset and updating the tree of logical tables.
[0022] In some implementations, the computer system has one or more processors, a memory, and a display. One or more programs contain instructions for performing any of the methods described herein.
[0023] In some implementations, a non-transitory computer-readable storage medium stores one or more programs configured for execution by a computer system having one or more processors, a memory, and a display. The one or more programs include instructions for performing any of the methods described herein.
[0024] Thus, disclosed are methods, systems, and graphical user interfaces that allow a user to analyze, prepare, and curate data. [Brief description of the drawings]
[0025] For a better understanding of the aforementioned systems, methods, and graphical user interfaces, as well as additional systems, methods, and graphical user interfaces for providing data visualization analysis and data preparation, reference should be made to the following description of implementations in conjunction with the following drawings, in which like reference numerals refer to corresponding parts throughout the drawings, in which:
[0026] [Figure 1]1 illustrates a graphical user interface for use in some implementations. [Diagram 2] 1 is a block diagram of a computing device according to some implementations. [Figure 3A-3B] 1 illustrates a user interface of a data preparation application according to some implementations. [Figure 4] 1 illustrates an exemplary conceptual graph according to some implementations. [Figure 5A] 1 illustrates an exemplary semantics services architecture, according to some implementations. [Figure 5B] 1 is a schematic diagram illustrating synchronization between modules that read and write data rolls according to some implementations. [Figure 6A] 1 is an example code snippet illustrating a ranking heuristic based on usage statistics, according to some implementations. [Figure 6B] 6 is an example data visualization 610 of a user query without semantic information, according to some implementations. [Figure 6C] 6C is an example data visualization 630 of the user query shown in FIG. 6B that utilizes semantic information, according to some implementations. [Figure 6D] 1 illustrates an example query according to some implementations. [Figure 6E] 1 provides examples of automatically generated suggestions according to some implementations. [Figure 6F] 1 illustrates example usage data according to some implementations. [Figure 6G] 1 illustrates exemplary inference according to some implementations. [Figure 6H] 1 illustrates exemplary usage statistics according to some implementations. [Figure 6I] 1 illustrates an example natural language query suggestion according to some implementations. [Figure 6J] 13 illustrates examples of smarter suggestions based on usage statistics according to some implementations. [Figure 6K] 1 shows a table of example implementations of an interface for fetching usage statistics, according to some implementations. [Figure 7A] 1 illustrates a UML model of a data role that uses a data source to store domain values, according to some implementations. [Figure 7B] 1 illustrates an example process for assigning data roles, according to some implementations. [Figure 7C] 1 illustrates an example user interface for validating data, according to some implementations. [Figure 7D] 1 illustrates an example user interface for improved searching utilizing semantic information, according to some implementations. [Figure 7E] 1 illustrates an example user interface for controlling access permissions to data roles, according to some implementations. [Figure 8] 1 illustrates an example user interface for previewing and / or editing cleanup suggestions, according to some implementations. [Figure 9A-9D] 1 illustrates an example user interface for resource suggestions based on semantic information, according to some implementations. [Figures 10A-10N] 1 is a flowchart of a method 1000 of preparing data for subsequent analysis, according to some implementations.
[0027] Reference will now be made to implementations, examples of which are illustrated in the accompanying drawings. In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present invention. However, it will be apparent to one skilled in the art that the present invention may be practiced without the need for these specific details. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0028] FIG. 1 illustrates a graphical user interface 100 for interactive data analysis. The user interface 100 includes a data tab 114 and an analysis tab 116, according to some implementations. When the data tab 114 is selected, the user interface 100 displays a schema information area 110, also referred to as a data pane. The schema information area 110 provides named data elements (e.g., field names) that can be selected and used to build a data visualization. In some implementations, the list of field names is divided into groups of dimensions (e.g., categorical data) and groups of measures (e.g., numeric). Some implementations also include a list of parameters. When the analysis tab 116 is selected, the user interface displays a list of analysis functions instead of data elements (not shown).
[0029] The graphical user interface 100 also includes a data visualization area 112. The data visualization area 112 includes multiple shelf areas, such as a column shelf area 120 and a row shelf area 122, which are also referred to as column shelf 120 and row shelf 122. As shown here, the data visualization area 112 also has a large space for displaying visual graphics. The space initially has no visual graphics because no data elements have been selected yet. In some implementations, the data visualization area 112 has multiple layers, referred to as sheets.
[0030] 2 is a block diagram illustrating a computing device 200 that may display a graphical user interface 100 according to some implementations. The computing device may also be used by a data preparation ("data prep") application 230. Various examples of computing device 200 include desktop computers, laptop computers, tablet computers, and other computing devices having a display and a processor capable of running a data visualization application 222 and / or a data prep application 230. Computing device 200 typically includes one or more processing units / cores (CPUs) 202 for executing modules, programs, and / or instructions stored in memory 214 and thereby performing processing operations, one or more network or other communication interfaces 204, memory 214, and one or more communication buses 212 for interconnecting these components. Communication bus 212 may include circuitry that interconnects and controls communication between system components.
[0031] The computing device 200 includes a user interface 206 that comprises a display device 208 and one or more input devices or mechanisms 210. In some implementations, the input device / mechanism comprises a keyboard. In some implementations, the input device / mechanism comprises a "soft" keyboard that is optionally displayed on the display device 208, allowing a user to "press keys" that are displayed on the display 208. In some implementations, the display 208 and input device / mechanism 210 comprise a touch screen display (also referred to as a touch sensitive display).
[0032] In some implementations, memory 214 includes high-speed random access memory such as DRAM, SRAM, DDR RAM, or other random access solid-state memory devices. In some implementations, memory 214 includes non-volatile memory such as one or more magnetic disk storage devices, optical disk storage devices, flash memory devices, or other non-volatile solid-state storage devices. In some implementations, memory 214 includes one or more storage devices located remotely from CPU 202. Memory 214, or alternatively a non-volatile memory device within memory 214, includes a non-transitory computer-readable storage medium. In some implementations, memory 214, or the computer-readable storage medium of memory 214, stores the following programs, modules, and data structures, or a subset thereof: · An operating system 216 that handles various basic system services and contains instructions for performing hardware-dependent tasks. · One or more communications network interfaces 204 (wired or wireless) and a communications module 218 used to connect the computing device 200 to other computers and devices via one or more communications networks, such as the Internet, other wide area networks, local area networks, metropolitan area networks, etc. · A browser (or other application capable of displaying web pages) 220 that allows a user to communicate with remote computers or devices over a network. A data visualization application 222 provides a graphical user interface 100 for a user to build visual graphics. For example, a user selects one or more data sources 240 (which may be stored on the computing device 200 or may be stored remotely), selects data fields from the data sources, and defines a visual graphic using the selected fields. In some implementations, the information provided by the user is stored as a visual specification 228. The data visualization application 222 includes a data visualization generation module 226, which receives user input (e.g., visual specification 228) and generates a corresponding visual graphic (also referred to as a "data visualization" or "data viz"). The data visualization application 222 then displays the generated visual graphic in the user interface 100. In some implementations, the data visualization application 222 executes as a standalone application (e.g., a desktop application). In some implementations, the data visualization application 222 executes within a web browser 220 or another application using a web page provided by a web server: Zero or more databases or data sources 240 (e.g., a first data source 240-1 and a second data source 240-2) used by the data visualization application 222. In some implementations, the data sources are stored as spreadsheet files, CSV files, XML files, flat files, or stored in a relational database. Zero or more semantic models 242 (e.g., first semantic model 242-1 and second semantic model 242-2), each of which is derived directly from a respective database or data source 240. The semantic models 242 represent the database schema and contain metadata about the attributes. In some implementations, the semantic models 242 also include metadata of alternative labels or synonyms for the attributes. The semantic models 242 include data types (e.g., “text”, “date”, “geospatial”, “boolean”, and “numeric”), attributes (e.g., a currency type such as USD), and semantic roles (e.g., a “City” role for a geospatial attribute) of the data fields of the respective database or data source 240. In some implementations, the semantic models 242 also capture statistics (e.g., data distribution, range limits, averages, and cardinalities) for each attribute. In some implementations, the semantic model 242 is augmented with a grammar vocabulary that contains a set of analytical concepts found in many query languages (e.g., average, filter, sort). In some implementations, the semantic model 242 also distinguishes between attributes that are measures (e.g., attributes that can be measured, aggregated, or used in mathematical operations) and dimensions (e.g., fields that cannot be aggregated other than by counting). In some implementations, the semantic model 242 includes one or more conceptual graphs that encapsulate semantic information about the data source 240. In some implementations, the one or more conceptual graphs are organized as directed acyclic graphs and / or embody hierarchical inheritance of semantics among one or more entities (e.g., logical fields, logical tables, and data fields). In this manner, the semantic model 242 helps infer and assign semantic roles to fields. · One or more object models 108, which identify the structure of the data sources 240. In an object model (i.e., a data model), data fields (attributes) are organized into classes, and the attributes in each class have a one-to-one correspondence with each other. The object model also includes many-to-one relationships between classes. In some cases, the object model maps each table in the database to a class, and the many-to-one relationships between classes correspond to foreign key relationships between tables. In some cases, the data model of the underlying source does not map cleanly to the object model in this simple manner, so the object model includes information that specifies how to convert raw data into appropriate class objects. In some cases, the raw data source is a simple file (e.g., a spreadsheet) that is converted into multiple classes.
[0033] In some cases, computing device 200 may store and use a data prep application 230 to analyze and prepare data for subsequent analysis (e.g., by data visualization application 222). Figure 3B shows an example of a data prep user interface 300. As described in more detail below, data prep application 230 allows a user to build a flow 323.
[0034] Each of the above identified executable modules, applications, or set of procedures may be stored in one or more memory devices and corresponds to a set of instructions for performing the functions described above. The above identified modules or programs (i.e., sets of instructions) need not be implemented as separate software programs, procedures, or modules, and thus various subsets of these modules may be combined or otherwise rearranged in various implementations. In some implementations, memory 214 stores a subset of the above identified modules and data structures. Additionally, memory 214 may store additional modules or data structures not described above.
[0035] 2 illustrates a computing device 200, which is intended more as a functional description of various features that may be present, rather than as a structural overview of the implementations described herein. In practice, items shown separately may be combined and some items may be separated, as will be recognized by those skilled in the art.
[0036] FIG. 3A shows an overview of a user interface 300 for data preparation, showing panes that group different functions together. In some implementations, the left pane 312 provides options for the user to find and connect to data or perform operations on data already selected. In some implementations, the flow area 313 shows one or more operations at the node to perform on the selected data (e.g., data operations to prepare the data for analysis). In some implementations, the profile area 314 provides information about the dataset at the currently selected node (e.g., a histogram of data value distribution for some of the data fields in the dataset). In some implementations, the data grid 315 provides raw data values for the rows and columns of the dataset at the currently selected node.
[0037] 3B provides a specific example of a user interface 300 for data preparation, showing the user interface elements in each of the panes. The menu bar 311 includes one or more menus, such as a File menu and an Edit menu. While the Edit menu is available, further changes to the flow are performed by having an interaction with the flow pane 313, the profile pane 314, or the data pane 315.
[0038] In some implementations, the left pane 312 includes a data source palette / selector. The left pane 312 also includes an operations palette that displays operations that can be placed in the flow. In some implementations, the list of operations includes any join (including any type and with various predicates), union, pivot, column rename and limit, scalar calculation projection, filter, aggregation, data type conversion, data analysis, coalesce, unify, split, aggregate, value replacement, and sampling. Some implementations also support operators to create tuples (e.g., split the data values of a data field into tuples), binning (e.g., group the numeric data values of a data field into a set of ranges), and table calculations (e.g., calculate a data value, such as a percentage sum, for each row that depends not only on the data values of each row but also on other data values in the table).
[0039] The left pane 312 also contains a palette of other flows that can be incorporated into the current flow, in whole or in part. This allows the user to reuse components of a flow to create a new flow. For example, if a portion of a flow is created that uses a combination of ten steps to scrub a particular type of input, that ten-step flow portion can be saved and reused in the same flow or in a completely different flow.
[0040] The flow pane 313 displays a visual representation (e.g., a node / link flow diagram) 323 of the current flow. The flow pane 313 provides an overview of the flow that is useful for documenting a process. As the number of nodes increases, implementations typically add scroll boxes. The need for scroll bars is reduced by collapsing multiple related nodes into supernodes, also called container nodes. This allows the user to see the entire flow more conceptually and drill down into details only when necessary. In some implementations, when a "supernode" is expanded, the flow pane 313 shows only the nodes within the supernode, and the flow pane 313 has a heading that identifies which part of the flow is being displayed. Implementations typically enable multiple hierarchical levels.
[0041] Complex flows can include multiple levels of nested nodes. Different nodes in the flow diagram 323 perform different tasks and therefore the internal information of the nodes is different. Additionally, in some implementations, different information is displayed depending on whether a node is selected. The flow diagram 323 provides an easy, visual way to understand how data is being processed and organizes the process in a logical way for the user.
[0042] As described above, the profile pane 314 contains schema information about the data in the node (or nodes) currently selected in the flow pane 313. As shown here, the schema information provides statistical information about the data, such as a histogram 324 of the data distribution for each of the fields. The user can directly interact with the profile pane to modify the flow 323 (e.g., by selecting a data field to filter rows of data based on the value of that data field). The profile pane 314 also provides the user with relevant data about the currently selected node (or nodes) and visualizations to guide the user's work. For example, the histogram 324 shows the distribution of domains for each column. In some implementations, brushing is used to show how these domains have interactions with each other.
[0043] The data pane 315 displays rows 325 of data that correspond to the node or nodes selected in the flow pane 313. Each of the columns 326 corresponds to one of the data fields. The user can directly interact with the data in the data pane to modify the flow 323 in the flow pane 313. The user can also directly manipulate the data pane to modify individual field values. In some implementations, when the user makes a change to one field value, the user interface applies the same change to all other values in the same column that match the value (or pattern) that the user just changed.
[0044] A sampling of the data in the data pane 315 is selected to provide valuable information to the user. For example, in some implementations, rows are selected that display the full range of values for a data field (including outliers). As another example, if a user selects a node with two or more data tables, in some implementations rows are selected that aid in joining the two tables. The rows displayed in the data pane 315 are selected to display both matching and non-matching rows between the two tables. This helps determine which fields to use for the join and / or which join type to use (e.g., inner join, left outer join, right outer join, or full outer join).
[0045] Although a user can edit the flow diagram 323 directly in the flow pane 313, changes to operations are typically made in a more rapid manner by directly manipulating the data or schema in the profile pane 314 or data pane 315 (e.g., right-clicking on a data field's statistics in the profile pane to add or remove columns from the flow).
[0046] Traditional data visualization frameworks rely on users to interpret the meaning of the data. Some systems understand low-level data constraints, like data types, but lack an understanding of what the data represents in the real world. This limits the value they provide to users in two important ways. First, users need expertise in each data sheet to understand what it means and how to best produce a useful visualization (even curated data sources provide little context). Second, users need to spend a lot of time manually manipulating the data and writing calculations to produce the data in a meaningful form.
[0047] In some implementations, these limitations are overcome by enriching data models with deeper semantics and by using those semantics to enable intelligent automation. Such implementations reduce user dependency on knowledge and expertise to access meaningful content. Semantics include metadata that helps computationally model what data represents in the real world. Semantics come in many forms, ranging from exposing relationships between fields to enriching individual rows of data with additional information. In some implementations, row-level semantics include synonyms, geocodes, and / or entity enrichment. In some implementations, field-level semantics include data types, field roles, data range types, bin types, default formats, semantic roles, unit conversions, validation rules, default behaviors, and / or synonyms. In some implementations, object-level semantics include object relationships, field calculations, object validation, query optimization, and / or synonyms.
[0048] Field-level semantics In some implementations, field-level semantics augment existing metadata about fields with richer type information in the context of a single field. In some implementations, field-level semantics exclude knowledge about relationships between fields or objects. In some implementations, field-level semantics are built from field type metadata. Some implementations use semantic role attributes (e.g., geographic role) on data source fields. In some implementations, field-level semantics are extended by adding support for additional field attributes.
[0049] Unit of measurement In some implementations, units are added as attributes of fields (specifically, measures) to automate unit conversions, improve formatting, and improve default visualization behavior. Examples of unit scales include currency ($), duration (hours), temperature (°F), length (km), volume (L), area (sq ft), mass (kg), file size (GB), pressure (atm), percentage (%), and rate (km / hr).
[0050] Some implementations apply field-level semantics in different use cases to provide improved user experience or results in various scenarios. Some implementations use field-level semantics to provide unit conversion in natural language queries. For example, assume a user queries "calls over 3.5 hours". Some implementations provide automatic unit conversion from hours to milliseconds (e.g., in filters). Some implementations provide unit normalization in dual-axis visualizations. Assume a user compares a Fahrenheit field to a Celsius measure. In this example, Fahrenheit is automatically converted to Celsius. Similarly, during data preparation, some implementations apply field-level semantics to format inferences in calculations. Assume a user creates a calculated field by dividing "Distance" (in miles) by "Time" (in seconds). Some implementations infer a default format of "miles / second". Some implementations apply field-level semantics in visualizations. For example, assume a user creates a bar chart visualization that includes height. In some implementations, measures are formatted (e.g., an axis shows units such as 156 cm). In some implementations, certain conversions (such as miles to kilometers) are encoded in the ontology, but variables such as currency are derived from an external source (e.g., a computational knowledge engine).
[0051] Automatic data validation and cleanup In some implementations, validation rules are added as attributes of fields to enable users to more easily identify and clean up dirty data. For example, out-of-the-box validation rules include phone number, zip code, address, and URL. In some implementations, field-level semantics are used to clean up dirty data. For example, assume that a user uploads a dataset that includes an incorrectly formatted address during data preparation. In some implementations, we automatically detect invalid rows of data and suggest a cleanup flow (e.g., in Tableau Prep). As another use case, some implementations use field-level semantics to perform field inference while processing natural language user queries. For example, assume that a user queries "user sessions for name@company.com". In some implementations, we automatically detect that the value provided by the user is an email address and infer and filter the "Email" field.
[0052] Default behavior Some implementations use other attributes of miscellaneous semantic concepts to automatically refine default behavior across fields. Some implementations apply field-level semantics to determine a default sort for generating a data visualization. Assume a user creates a bar chart visualization with a "Priority" field with data values of "High", "Medium", and "Low". In some implementations, the values are automatically sorted in scalar order instead of alphabetically. Some implementations apply field-level semantics to determine a default color for generating a data visualization. Assume a user creates a visualization of votes in an election. When the user visualizes party wins by county, some implementations automatically color the regions by their party's color. Some implementations apply field-level semantics during data preparation to determine a default role. Assume a user uploads a dataset that includes a primary key. Some implementations automatically set the role of the primary key field as a dimension, even if it is a numeric data field.
[0053] synonym In some implementations, knowledge of what fields and their domain values represent in the real world, and the different names people give to fields, is used to improve interpretation of natural language queries and improve data discovery through search.
[0054] In some implementations, field-level semantics are used to recognize synonyms during natural language processing. For example, assume a user queries for "average order size by category." In some implementations, "order size" is mapped to a "quantity" field and a bar chart visualization showing the average quantity per category is shown. In some implementations, field-level semantics are used to perform data source mining. For example, assume a user searches for "customers" in a data visualization server (e.g., Tableau Server). In some implementations, data sources containing data corresponding to "clients," "customers," and "subscribers" are determined.
[0055] Object-Level Semantics In some implementations, object-level semantics are used to extend semantic roles with new concepts that have meaning in the context of a particular object. Thus, in some implementations, natural language, associated calculations, analysis rules, and constraints are automatically associated with data elements.
[0056] In some implementations, semantics are associated with data attributes by assigning a semantic role to a field and associating it with a concept. In some implementations, concepts are represented using a directed acyclic concept graph. In some implementations, the chain of concepts forms a hierarchy, with each hierarchical level adding new real-world understanding to the data and inheriting the semantics of the previous level.
[0057] FIG. 4 illustrates an exemplary concept graph 400 according to some implementations. In the illustrated example, a first node 402 corresponds to the concept "currency", a second node 406 corresponds to the concept "dollar", a third node 407 corresponds to the concept "market capitalization", and a fourth node 408 corresponds to the concept "stock". The edges connecting the nodes represent relationships between the concepts. Data fields and / or tables are associated with one or more concepts. Assume that a field is associated with the concept currency. In some implementations, based on the concept graph, we infer that the concept currency is associated with the concept dollar. Based on this semantic relationship, in some implementations, the possible units of the field (dollars in this example) are shown. In some implementations, concepts are nested. In some implementations, the relationship is hierarchical, meaning that a child concept inherits the characteristics of a parent concept. In the example illustrated in FIG. 4, the concept market capitalization inherits the semantic role of the stock concept.
[0058] In some implementations, each semantic concept includes context information that defines what the concept means, what natural language expressions a user may use to refer to it, and / or what types of calculations a user should be allowed to perform (or blocked from performing). In some implementations, this context information is different in different object contexts, e.g., the term "rate" is used differently in the context of taxes or investments than in the context of audio frequencies or race cars.
[0059] Field Calculated Value In some implementations, the meaning of a field is used to automatically infer calculated values of related information in other fields that may be semantically meaningful. In some implementations of object-level semantics, calculated fields are inferred to assist users during data preparation. For example, assume that a user exposes a data source that includes a Person object that includes a Birth Date field. In some implementations, we automatically suggest adding a calculated field called "Age". In some implementations, natural language queries that reference age are automatically interpreted. In some implementations, object-level semantic information is used to interpret ambiguous natural language queries. For example, assume that a user queries "largest countries". In some implementations, the top countries are automatically filtered by descending population. In some implementations, object-level semantics is used to interpret natural language queries that include relationships between fields. For example, assume that a user queries "average event duration" and further assume that duration is not present in any of the data sources. In some implementations, the duration is automatically calculated as a function of the start and end dates (and / or times).
[0060] Object Relationships In some implementations, object-level semantics are used to reason about relationships between objects and their fields. In some implementations, this inference is limited to relationships between pairs of objects. In some implementations, this inference is extended to all networks of objects to form entire known datasets, such as "Salesforce" or "Stripe." In some implementations, this inference is used to make content suggestions, associate similar datasets, or understand natural language queries.
[0061] In some implementations, object-level semantics are used to interpret natural language queries and determine relationships between objects. For example, assume a user queries "messages sent by John". In some implementations, one or more tables (e.g., Users and Messages) are determined to be joined. In some implementations, it is determined that a filter operation should be performed on relationships joined by a foreign key (e.g., sender_id foreign key).
[0062] In some implementations, object-level semantics are used to perform query evaluation optimization. For example, assume that a user evaluates a query on a "count of users" and further assume that the user has many messages. In some implementations, an efficient query is performed on the distinct normalized message counts.
[0063] Object Validation In some implementations, data and / or object validation is performed based on object level semantics. In some implementations, the context of the object is used to gain insight into which validations may be applied to the field. In some implementations, analysis is suppressed to determine validations to apply to the field based on the context. In some implementations, object level semantics are used to assist the user during data preparation. For example, assume a user publishes a data source that includes earthquake magnitude data. In some implementations, dirty data (e.g., magnitude<1) is detected. In response, in some implementations, a user option is provided to clean or filter the data or to otherwise automatically clean and / or filter out bad data.
[0064] Row-level semantics In some implementations, entities are recognized at the row level of the data and the recognized entities are enriched with additional information derived from other data sources by intelligently joining them. In some implementations, enrichment data is derived from existing data sources supplied by the customer, or from data provided by the data visualization platform (e.g., geocode data from Tableau), or even third parties (e.g., public or government datasets).
[0065] In some implementations, the user is assisted during data preparation. For example, assume that a user publishes a data source with stock ticker symbols. In some implementations, entity enrichment is performed using external data. For example, some implementations suggest a join with another dataset (either provided by the user or derived from an external source) to obtain data about each public company (e.g., headquarters location). In this example, some implementations then interpret a question about investing in companies headquartered in Canada.
[0066] Deriving Semantic Information In some implementations, data models are enriched with semantics even when it is uncertain how a piece of data should be classified. In some implementations, inferred semantics are used by defining deterministic rules to infer semantic classifications from existing metadata stored in the data source, such as inferring whether a measure is a percentage by looking at its default format. In some implementations, manual classification is used, allowing users to manually label fields by selecting one or more semantic roles from a list of options. In some implementations, automatic semantic classification is performed by learning patterns in how users label data sources to make suggestions. In some implementations, these suggestions are explicit semantic classifications and can be overcome by the user. In some implementations, these patterns are used to obtain fingerprints of fields for use in similarity-based suggestion algorithms (e.g., "similar fields are typically used like this").
[0067] Global Semantic Concepts In some implementations, the user is provided with an ontology of global semantic concepts to choose from when labeling fields. These are concepts that have universal semantic meaning. For example, the vague concepts of "Currency" or "Length" are context independent, and in some implementations, reasonable assumptions are made about the desired behavior on fields of these types.
[0068] User-defined semantic concepts Some implementations start with a robust model for describing semantics and allow users to extend the ontology with custom semantic concepts. Preferably, the valuable concepts are specific to the customer dataset or the customer's business and / or are reconfigurable.
[0069] For example, a customer chooses to build their own package of semantic concepts related to "Retail." When the user later uploads a dataset and chooses to apply the "Retail" package, in some implementations, it automatically suggests which semantic labels may be applied to which fields.
[0070] With semantic governance, in some implementations, organizations can curate ontologies of shared semantic packages among teams of people. In some implementations, they develop large repositories of domain-specific semantic concepts and create a marketplace where those semantic concepts can be shared among customers.
[0071] Some implementations include modules that provide semantic information. In some implementations, such modules and / or semantic information are configurable. In some implementations, data roles are automatically detected. Some implementations use a framework that describes the structure and representation of semantic concepts, as well as the architecture and interfaces of semantic services responsible for holding, accessing, and / or managing the semantic concepts. Some implementations use the framework to generate a library of global semantic concepts (e.g., a "default ontology"). In some implementations, the library is made available for users to manage or edit. In some implementations, examples of semantically labeled data sources are used to train predictive models and make semantic label suggestions to reduce the amount of work required to semantically prepare data for analysis.
[0072] Semantic Services Architecture FIG. 5A provides an example of a semantics service architecture 500 according to some implementations. In some implementations, the semantics service 524 runs on a data visualization server 522 (e.g., Tableau Server, either on-premise, online or in the cloud) and / or on a data preparation server (e.g., Tableau Prep Server). In some implementations, the semantics service 524 is responsible for holding and / or managing semantic concepts for use by the data role service 512 and related functions. In some implementations, the semantics service 524 is written in Go or a similar programming language (e.g., a language that provides memory safety, typing and concurrency). In some implementations, the semantics service connects services within and across data centres using a gRPC interface or similar high performance remote procedure call (RPC) framework that runs in a variety of environments. The data role service 512 captures the semantic properties of data that are easily reused, shared and managed. In some implementations, data roles represent content types. In some implementations, data role data has two components: (i) content metadata, which is typically stored in the monolith 502 in a data_roles table, and (ii) semantic concept data, which is typically stored in the semantics service 524 (e.g., in a Postgres database 518, an Elasticsearch database 526, and / or a similar analytics engine).
[0073] In some implementations, a data role service 512 (e.g., a Java module) runs on the monolith 502 and is responsible for managing the data role content metadata. In some implementations, the data role service 512 is an in-process service and does not listen on any ports. In some implementations, the data role service 512 receives requests from external APIs such as a REST API 504 (used by Data Prep), a Web Client API 506 (used by the Server front end), and a Client XML Service 508.
[0074] In some implementations, the semantics service 524 is a Go module that runs in the NLP service 522 that provides services such as natural language query processing. In some implementations, the semantics service 524 has an internally exposed gRPC interface that is consumed by the data role service 512.
[0075] Authoring Data Roles In some implementations, there are two kinds of data roles: built-in data roles (eg, country, or URL) and custom data roles defined by the customer / user.
[0076] In some implementations, custom data roles are authored only in Data Prep, in some implementations, custom data roles are also authored in desktop versions of the data visualization software, Server, and / or any environment in which data sources are authored or manipulated (e.g., Catalog, Web Authoring, or Ask Data).
[0077] The arrows in FIG. 5A show an example process flow according to some implementations. In some implementations, Data Prep sends a request to the REST API service 504. In some implementations, the data role service 512 uses the authorization service 510 to verify the authorization 516 for the request. In some implementations, the data role service 512 persists the content metadata of the data role in a data_roles table in a database (e.g., a Postgres database 518). In some implementations, the data role service 512 sends a request to the semantics service 524 to persist the field concept data of the data role. The field concept data contains the semantic content of the data role according to some implementations. In some implementations, the data role service 512 notifies the search service 514 that a piece of content has been updated and needs to be indexed in Solr 520 (or a similar enterprise search platform).
[0078] Matching Data Roles and Data Fields In some implementations, the semantics service 524 provides a gRPC (or similar) interface to expose functionality to use the field concept data to discover the data role of a field and to semantically enrich / validate a field or its values. In some implementations, the field concept data is used to provide value pattern matching. In such cases, the field concept data encodes a regular expression that validates whether a value is valid in the context of a data role. In some implementations, the field concept data is used to provide name pattern matching. In such cases, the field concept data encodes a regular expression that validates whether the name of a data field is valid in the context of a data role. In some implementations, the field concept data is used to provide value domain matching. In such cases, the field concept data references an exposed data source identifier and a field name, which defines a domain of valid member values for a data role.
[0079] FIG. 5B is a schematic diagram 530 illustrating synchronization between modules that read and write data roles 532 according to some implementations. In some implementations, if a data role uses value domain matching, the semantics service 524 retrieves values from exposed data sources 536 and indexes them in Elasticsearch 526 so that matching is highly performant. In some cases, the underlying data sources may be slow, and using a service like ElasticSearch helps determine if a value matches any value of any (accessible) data role within a short duration (e.g., less than a millisecond). In some implementations, each data role references an exposed data source 536 as the source of truth for the values of that data role. When a data role is created or a data source is updated, in some implementations, the semantics service 524 queries the data server to extract values and indexes them in Elasticsearch 526.
[0080] In some implementations, the data for the data roles 532 comes from data prep flows 534 and / or workbooks 538 that embed data sources. In some implementations, the published data 540 for the data roles 532 is stored in the database 240 (e.g., as part of the semantic model 242).
[0081] Data-Centric Natural Language Query Processing In some implementations, natural language commands and questions provided by the user (e.g., questions asked by the user regarding information contained in a data visualization or a published workbook) may be leveraged to improve the quality and relevance of suggestions, reasoning, and for ambiguity resolution.
[0082] suggestion In some implementations, interpreting a user input (such as a question or natural language command) may include inferring an expression or a portion of an expression contained in the user input. In such cases, one or more suggestions or suggestions may be provided to the user. For example, when a user input selects a data source of interest, a list of automatically generated suggestions may include any of the following suggestions: "By Neighborhood," "Sort Neighborhood in alphabetical order," "Top Neighborhood by sum of Number of Records," "Sum of Square Feet," "Sum of Square Feet and sum of Host Total Listing Count as a scatter plot," or "Square Feet at least 0." In some cases, the automatically generated suggestions may contain suggestions that are unlikely to be relevant to the user.
[0083] In some implementations, one or more models are used to provide relevant suggestions to a user. For example, once a data source of interest is selected or identified by a user, the suggestions may include, for example, one or more top fields in the selected data source, one or more top concepts (e.g., an "average" filter), or one or more fully specified subexpressions (e.g., filters, sorts, limits, aggregations). In a second example, once a user selects a data source and a data field within the selected data source, the suggestions may include one or more top subexpressions (e.g., filters, sorts, limits, aggregations) or one or more top values. In a third example, once a user selects a data source and one or more expressions, the suggestions may include one or more top data visualization types. In another example, once a data source, a data field, and a filter are selected by a user, the suggestions may include one or more top values in the data field that satisfy the filter criteria. In yet another example, once a data source and a subexpression are selected by a user, the suggestions may include one or more top correlated subexpressions.
[0084] Existing Visualization Context In some implementations, the one or more models used to provide suggestions may take into account the data visualization type of the currently displayed data visualization (e.g., bar chart, line chart, distribution chart, heat map, geographic map, or pie chart) and historical usage behavior, including similar data visualization types. For example, once a data source and data visualization type are specified by a user, the suggestions may include one or more top fields to be added to the existing content. Alternatively, the suggestions may include one or more top expressions (e.g., popular filters) to be added to a given existing content.
[0085] User Context In some implementations, one or more models may include one or more users (e.g., user accounts and / or user profiles) to provide suggestions that are customized to each user's individual behavior. For example, a Business Team user may prioritize the "Order Date" field, while a Shipping & Logistics Team member may prioritize the "Ship Date" field. When a Business Team user selects a data source, the model may suggest the "Order Date" field, and when a Shipping & Logistics Team user selects the same data source, the model may suggest the "Ship Date" field instead of or in addition to the "Order Date" field. In this way, the model may provide personalized suggestions that are most relevant and appropriate to each user.
[0086] Ambiguity Resolution In some implementations, the natural language input may contain competing representations, and although it is possible to use heuristics to select a default representation, the default selection may not always be the best choice given the selected data source, existing visualization context, or user.
[0087] Some examples of types of conflicts include the following: · Conflicts between multiple fields Conflicts between multiple values across fields Conflicts between multiple values in a field Conflicts between analytical concepts or expressions Conflicts between values and fields Conflicts between values / fields and analytical concepts or expressions
[0088] To address such conflicts in natural language input, some implementations use various types of weights to select the most appropriate or relevant expressions. Some examples of weights include hard-coded weights for particular expression types, popularity scores for fields, frequency of occurrence for values and / or key phrases, etc.
[0089] In some implementations, the weights may be updated based on the frequency of occurrence of the expressions in the natural language input and / or in visualizations in a published data visualization workbook.
[0090] For example, when a user provides the natural language input "avg price seventh ward" when accessing a data source containing information about holiday rentals, suggestions may include any of the following options: Filter neighborhoods for daily average prices, seventh ward Filter neighborhoods for weekly average price, seventh ward Filter neighborhoods for monthly average price, seventh ward Filter host neighborhood for daily average price, seventh ward Filter host neighborhood for weekly average price, seventh ward
[0091] In a generalized example, when a user selects a data source and provides a string, such as "seventh ward," the suggestions may include one or more text fields that include the string as a data value. In another example, when a user selects a data source and a visualization and provides a string, the suggestions may include one or more expressions (e.g., value expressions or field expressions). Similarly, when a user is logged into an account or profile (so that personal preferences may be considered in one or more models), when a user selects a data source and provides a string, the suggestions may include one or more expressions (e.g., value expressions or field expressions). In some implementations, the one or more expressions include regular expressions, such as patterns that help the user make selections.
[0092] In resolving conflicting expressions in natural language input, heuristics may not perform well. FIG. 6A is an example code snippet 600 illustrating ranking heuristics based on usage statistics according to some implementations. In this example, assume that filter FilterTo 604 has a higher usage count compared to filter AtLeast 602. This may be because there are only numeric fields (Salary) in the corresponding data source, while there are many text or geographic fields such as City, Continent, Country, League, Player, Team. In these situations, some implementations rank the filters accordingly. In this example, filter FilterTo 604 is ranked above filter AtLeast 602.
[0093] 6B is an example data visualization 610 for a user query without semantic information, according to some implementations. Assume a user queries maximum salaries 612 by league 614 by country 616. Assume further that the user does not select a visualization type. In the absence of semantic information, in some implementations, maps 622 and 624 corresponding to leagues 618 and 620, respectively, are displayed.
[0094] 6C is an example data visualization 630 of the user query in FIG. 6B that utilizes semantic information, according to some implementations. In some implementations, the visualization type (bar chart 632 in this example) is automatically derived based on the semantic information of the underlying data fields. In this case, the data visualization 630 includes bar charts 634 and 636 for leagues 618 and 620, respectively.
[0095] 6D illustrates an example query, according to some implementations. In some implementations, repeated expressions in past queries are tracked and / or usage counts of expressions in natural language queries are tracked, and such statistics are associated with data fields (e.g., Salary or League) to automatically derive a visualization type. In the example illustrated in FIG. 6D, the expression "as a bar chart" 640 appears explicitly multiple times. In this example, when the system (e.g., a parser module) determines that the natural language expression refers to Salary or League, the system automatically shows a bar chart.
[0096] FIG. 6E illustrates an example of an automatically generated suggestion, according to some implementations. Assume a user queries for a transaction amount by Merchant Type Description 642-2 and specifies a filter 642-4 (thereby filtering the Merchant Type Description to Home Supply Warehouse). Assume further that the user makes a typo in refining the query 642-6, or natural language query processing is unable to understand the request. In some implementations, a number of suggestions are provided for the user to refine the query. In this example, suggestion 642-8 asks if the user would like to add "Transaction Amt at least -20.870". In the absence of semantic information about the transaction amount, natural language processing information allows the filter to use negative amounts.
[0097] FIG. 6F illustrates exemplary usage data according to some implementations. In this working example, the usage statistics include data regarding the usage of "Transaction Amt." Using this usage data, some implementations determine that the value "185.05" is frequently used in user queries, and therefore infer that value as a much more plausible value for Transaction Amt. In some implementations, the derived "Transaction Amt" value proposed in FIG. 6E falls short of being inferred as a plausible value and is flagged as a suspect value.
[0098] FIG. 6G illustrates an example suggestion for filtering data, according to some implementations. In this example, the suggestion 646 for filtering on the Audit Type field includes a default inference value, here null. FIG. 6H illustrates an example usage statistic, according to some implementations. In this current example, based on usage data 648 for "Audit Type" (corresponding to "Transaction Amt"), some implementations determine that "Alcohol" is much more popular than all other Audit Type values. Based on this usage data, some implementations determine that the inference in this case is "Alcohol."
[0099] FIG. 6I illustrates an example suggestion for a natural language query, according to some implementations. In the illustrated example, after aggregating to Merchant Name 650, various suggestions 652, 654, and 656 fail to provide useful hints to the user. In particular, in this example, suggesting to add a filter to the count of Merchant Name is not meaningful. On the other hand, suggestions 660 (to add a field / filter such as Transaction Amount at least 100) or 662 (to add salary at least 0) are more meaningful. Thus, in some implementations, usage data associated with the data fields (e.g., usage statistics stored in semantic roles or semantic information) are applied to improve the suggestions.
[0100] FIG. 6J illustrates an example of smarter suggestions based on usage statistics according to some implementations. In some implementations, smarter suggestions are provided for all or partial expressions provided by a user (as part of a natural language query). In the example illustrated in FIG. 6J, assume that the value “China” 664 exists in both Country and State, and assume that State is more popular than Country. The first suggestion 666 incorrectly treats China as a state. Based on usage, few people would select China as a state, so in some implementations, the natural language parser can auto-correct the data source and correctly interpret China as Country (as illustrated by suggestions 668 and 670).
[0101] In some implementations, the usage statistics are represented using a data structure that associates a lookup map to retrieve for each data source for each value, an example of which is shown below. UsageStats struct { datasourceURI string Lookup map[StatKey][]ValueCount }
[0102] Some implementations use one or more interfaces that represent the keys used to fetch the top values and counts. Figure 6K shows a table 672 of example implementations of interfaces for fetching usage statistics, according to some implementations. In the table, a first column 674 corresponds to the various interfaces, a second column 676 corresponds to the type of statistics supported by the interface in the first column, a third column 678 corresponds to the key to pass to the interface in the first column, and a final column 680 corresponds to the value returned by each interface in the first column.
[0103] In some implementations, a data structure is used to represent the values returned by the interface described above with reference to FIG. 6K, an example of which is shown below. ValueCount of type { value interface{} count int32 }
[0104] Some implementations convert the value to a specific type depending on the type of the Statkey to which it is attached.
[0105] In some implementations, an interface (e.g., Statkey) in a parser (e.g., a natural language query parser) is used to obtain the values and counts. For example, to fetch the most popular values of field sales and filter atLeat, in some implementations the following operations are performed: values:= usageStats.Loopup[NewFieldFilterToValueKey(”sales”,”atLeast”)] mostPopularValue:=values[0].value.(complexValue)
[0106] Some implementations guarantee that the above conversion succeeds, and that all Values are validated before adding them to UsageStats.
[0107] In some implementations, one or more semantic model interfaces are used. The following are examples of semantic model interfaces: func(s *UsageStats)GetTopVizType(interpretation_nlg string)vizType []string func(s *UsageStats)GetRecommendedExpsForToken(token string,datasource *Datasource) []ExpCount type ExpCount struct { Type string(Field,,AnalyticalConcept,TextValue) Value string(fieldGraphID,ConceptID or textValue) Count int32 }
[0108] Some implementations interface with the ArkLangData module to fetch usage statistics (e.g., func(parser)GetStats)expArkLangExp)[]Stat). In some implementations, natural language processing suggestion records are stored to track usage statistics. In some implementations, each row in the suggestion record represents a daily count of an analytic concept and includes time information (e.g., the month the record was created), a data source URI string, a statistic type string, a string representing a key, a data string, and / or a count string. Some implementations also include a data visualization type column for natural language processing-based visualization.
[0109] In some implementations, natural language processing usage statistics are stored. In some implementations, the statistics include data source URI strings and the usage statistics (e.g., in JSON format).
[0110] In some implementations, performance estimates such as the number of visualizations over a period of time (e.g., the last 90 days) are stored. In some implementations, the number of statistics for each visualization (e.g., 20 statistics) or a range of statistics is stored. In some implementations, aggregate counts of natural language processing statistics per month (e.g., 5 per month means 60,000 records / 5=12,000 records) are stored. In some implementations, the number of active data sources (e.g., 200 active data sources) and / or the number of records per data source are stored.
[0111] Various applications of Dataroll In some implementations, knowledge about the real world, when associated with data elements such as objects, fields, values, etc., is used to automate or augment the analytical experience. Such knowledge provides an understanding of the semantics of data fields and is then used to help users clean, analyze, effectively present, and / or associate their data with other data to create rich data models.
[0112] In some implementations, different representations of the same data value that come from different sources or manually entered data values are standardized. In some implementations, the semantics of the field serve to describe the expected domain values that are used for standardization.
[0113] In some implementations, data knowledge includes concepts that are commonly applied in many different contexts, such as geographic codes, emails, URLs, etc. These concepts are sometimes referred to as global data roles.
[0114] In addition to global data roles, in some implementations, data knowledge also includes concepts related to domain-specific context. These are referred to as user-defined data roles. Often, customer use cases include non-standard domains, such as product names or hygiene standards. For example, users can configure custom data roles (e.g., user-defined data roles) to help standardize domain values by automatically identifying invalid values and helping users correct them (e.g., by applying fuzzy matching against known values).
[0115] In some implementations, the user-defined data roles are only available when the user is connected (e.g., signed in) to the server. In some implementations, the semantics and standardization rules included in the first user's user-defined data roles may be shared with other users for data preparation and analysis via the server. In this way, users connected to the server may share, discover, and mine content within the organization, such as user-defined data roles created by other users in the same team, group, or company.
[0116] In some implementations, a user may be able to access and reuse in a current application user-defined data roles that were previously defined in another application different from the current application.
[0117] In some implementations, multiple applications share and leverage a pool of data roles to gain added value specific to the context of each application. Examples of application-specific semantic capabilities include: · Applying data roles to data fields to identify domain values that do not match the roles and allow users to clean up the data fields. Analyzing a user's data and suggesting matching data roles to apply to data fields. For data fields that have a data role, analyzing the user's data and suggesting to apply cleanup transformations to the data field. Select good default formatting options for displaying values in a data field when a data role is applied to the data field. Cleaning the user's data fields and storing the cleaned data fields on the server as data roles, thereby providing other users within the user's organization connected to the server with access to the data roles for further data prep and analysis. · Identifying data fields by synonyms entered in a user query (e.g., natural language command, question, search input). · Automatically converting the units of a data field from its standard units to the units entered in the user's query. Inferring fields from the data roles of specific data values entered in a user query (for example, a user query such as "user sessions for name@company.com"). Inferring calculated data fields from an understanding of relationships between data fields and the subject of a user's query (e.g., calculating a duration from a start and end date in a data source). Inferring joins between tables from understanding the relationships between data fields and the subject of a user's query. (For example, the natural language input "messages sent by John" results in a join of Users and Messages on sender_id filtered by "John".) · Searching for fields that can match synonyms used in a query with field names in a table. · Searching across flows, which generally allows for more expressive queries (e.g., "all input steps that connect to customers"). · Creating data fields that are calculated from an understanding of the relationship between the data fields and the subject of the user's query (e.g. calculating a duration from a start and end date in a table). Creating joins between tables from an understanding of the relationships between data fields and the subject of a user's query (e.g. the natural language input "messages sent by users" would join Users and Messages on sender_id). Searching data sources that can match synonyms used in a query with data field names in the data sources. · Searching in general can handle more expressive queries (e.g. "all bug data sources used by at least 5 workbooks"). View and edit a catalog of user-defined data roles that are shared across an organization or company. · Automatically label units on axes or legends. · Automatically normalize units on dual-axis charts (e.g. comparing measurements in Celsius to measurements in Fahrenheit). · Automatically convert units when performing calculations with values in different units (e.g. adding a temperature in Fahrenheit to a temperature in Celsius). · By default, bar charts are ordered by priority (e.g. "High", "Medium", "Low"), but now sorted by associated scalar value (e.g. 1, 2, 3). · Colour areas on the map to identify political party affiliation by defaulting to party colours. Assigning data roles to data fields, exporting cleaned data sources to a data preparation application to clean up (e.g., remove) invalid values, and importing the cleaned data sources back into the initial data application or desktop to continue analysis. Searching data sources that can match synonyms used in a query with data field names in the data sources. · Searching in general can handle more expressive queries (e.g. "all bug data sources used by at least 5 workbooks"). Impact analysis, i.e. discovering all flows and data sources that contain data fields that use a particular data role. Identifying semantically related data fields via the configured object model (e.g. Name, Address, and ID fields are all related to a Customer when they are in the Customer object). · Automatically joining data fields and / or data tables using Object Model relationships. Suggesting groupings of data fields that have semantic associations (e.g., we can suggest grouping Product_Name, Product_Code, Product_Details into a Product Object). · Suggesting relationships based on joins made with other tables during the object model building phase.
[0118] In some implementations, data roles have short-term implications and effects on a user's workflow. For example, data roles are used to automatically detect dirty data in a data preparation application (e.g., marking invalid phone numbers so that the user knows they need cleanup). In another example, data roles are used to automatically interpret synonyms for natural language input of a data source in a server (e.g., mapping "Great Britain" to "United Kingdom"). In yet another example, user-defined data roles are created and published to the server for shared use.
[0119] In some implementations, data roles have long-term implications and effects in a user's workflow. For example, data roles are used to suggest or infer calculated data fields on exposed data sources (e.g., infer "age" when "birthdate" is known). In another example, data roles are used to add support for units of measurement (e.g., perform unit conversion from kilometers to miles in response to receiving natural language input such as "distance at least 4,000km").
[0120] By adopting user-defined data roles, users are introduced to a new experience in authoring, association, and governance workflows.
[0121] In some implementations, when a user adds a data source to either the user's desktop, a data preparation application, or a connected server, the associated data fields in the data source are automatically associated with a known (e.g., predefined or previously used) field-level data role. This association is visible to the user, and the user can choose to override the inferred data role by selecting a data role from a set of existing data roles. When many data roles exist, the user can search and / or navigate a catalog of options to more easily select a concept that is relevant to the current data source context and / or the user's own preferences.
[0122] In some implementations, there may be no existing data roles that meet the user's needs. In such cases, the user may author (e.g., create, generate, customize) new field-level data roles. For example, the user may publish metadata from existing data fields as data roles to the connected server. In some implementations, the metadata includes the data field's name, synonyms, definitions, validation rules (e.g., regular expressions), or known domain values. In some implementations, the user may edit these properties before publishing the data role to the server. In some implementations, the user may also author new field-level data roles from scratch without inheriting properties from existing data fields. In some implementations, the newly authored data roles are persisted in storage (e.g., storage managed by the Semantics Service) and / or automatically discovered in other data sources. Additionally, the user may choose whether to share his or her data roles with other users who are using applications provided by the same server.
[0123] In some implementations, users can browse a catalog of authored data roles to view the metadata and trace the lineage of data roles to understand which data sources have elements associated with them. In some implementations, users may modify data roles from within a catalog of concepts on a connected server. For example, users may modify existing concepts in the metadata (e.g., add synonyms, change validation rules, change known domain values, etc.), create new concepts (e.g., modify and duplicate existing concepts, author new concepts from scratch), deduplicate concepts and update data sources to point to the same concept, delete concepts, and further control the permissions with which other users on the server can modify the user's data roles.
[0124] Example use cases for data analytics In some implementations, data analysis capabilities are provided, examples of which are provided below. A user cleans up a data field that contains a list of product names (e.g., using regular expressions ("regex"), mapping value synonyms to canonical values using groups and substitutions). Users save the domain of a data field as a data role (including synonym mappings) so that users can assign data roles to data fields from other data sources to validate and clean other data fields and data sources. · The user saves the domain of the cleaned data fields as a data role so that other users in the user's organization can use the data role for validation and cleanup. The user validates and cleans up other data fields (e.g., automatically or using natural language input) using previously defined data roles in one or more applications. · The user edits a previously defined data role (eg, to correct an error or update a data role).
[0125] For example, a user may connect to a data source that contains information about product inventory. The user creates a data cleanup step and the application may suggest that the user apply the data role "Product Name" to the "prod_name" data field in the data source. The user may have worked with this data source before, but for example, this may be the first time the application has made this suggestion. After accepting the suggestion and applying the proposed data role to the proposed data fields, the user determines that some of the product names are not valid names. The user then receives another suggestion to automatically clean up the data by mapping invalid names to corresponding valid names. The user accepts the suggestion and the invalid values in the data field "prod_name" are replaced with valid names.
[0126] In another example, a user publishes an already existing data source and promotes a data role from one of the data fields to the published data source, such that values in the data fields remain in sync (so that if the data source is republished, the data role is automatically updated). In some cases, one or more data fields in the data source need some cleanup, and the user creates a data preparation flow to clean up the data fields and update the published data source. The user publishes the data preparation flow to a server and specifies the data fields for the data role. The user then sets the data preparation flow to a weekly refresh schedule, so that the data role is updated every week. In some cases, the user (or a different user than the user who published the data role) retrieves the data role from the server and / or applies the data role to fields in other data preparation flows.
[0127] Example Data Catalog Use Cases In some implementations, a data catalog function is provided, an example of which is provided below. · Users promote data fields in published data sources to data roles so that users may reuse them in other applications or with other data sources. · Users can apply existing data roles to data fields in published data sources, allowing applications with natural language input interfaces to associate synonyms with language patterns.
[0128] For example, a user may be working with two different data visualizations for the number of alerts per priority. The user suspects that the two data visualizations use the same data source, but one data visualization has some priority values that are different from the other data visualization. The user may use the Data Catalog to examine the lineage of each data visualization and determine, for example, that one data visualization is directly connected to a database while the other is using a published data source connected to a data preparation flow that is connected to the same database. The Priority field in the published data source has a data role associated with it that has a set of valid values, and the data preparation includes a cleanup step that filters out rows that have priority values that do not match the data role. The user notifies the creator of the first data visualization to consider using the published data source.
[0129] In another example, a user updates a "Product Name" data role by removing some outdated product names and adding some new product names. In yet another example, a user promotes a data role from a data field.
[0130] In some implementations, the values of the data roles are kept in sync with the data fields, so that when the user republishes the data source, the data roles are automatically updated. In this way, other analysts can start using the data roles in their data preparation flows. In some implementations, the natural language query processing system creates better insights.
[0131] In another example, a user promotes a data field in a published data source to a data role so that the user can reuse the data role in other data sources or in other applications.
[0132] In another example, the user reviews the list of data roles stored on the server to ensure that they are valid. The user may delete any data roles that may be inappropriate (e.g., data roles that are out of date or contain inaccurate information).
[0133] In another example, a user ensures that data roles containing sensitive data have the correct permissions, making them available only to those intended. A user can edit permissions to ensure that the list of users with access to a data role is up to date.
[0134] In another example, a user edits synonyms associated with data roles on a server to improve the effectiveness of using an application that has a natural language input interface with a data source.
[0135] Use cases for applications that include natural language input interfaces In one example, users can apply existing data roles to data fields in published data sources, allowing applications to associate synonyms with linguistic patterns (e.g., "like geography").
[0136] In another example, a user provides a natural language command or query that includes units of measure that are different from the units stored in a selected data source, and the application uses data roles to automatically convert the data in the data source to the units specified by the user's natural language input.
[0137] For example, a user may provide a natural language input "average order size by category." The application maps the phrase "order size" to the "quantity" data field and shows a bar graph data visualization showing the average quantity per category.
[0138] For example, a user may provide a natural language query for "largest countries," and the application creates a data visualization showing the top countries by population in descending order (most populous to least populous).
[0139] For example, a user may provide a natural language query for "average event duration," but the term "duration" is not included in the data source. The application calculates the duration as a function of the start and end dates included in the data source and creates a bar chart data visualization. The duration can also be calculated using the start and end times.
[0140] Example Data Roles In some implementations, a data role includes a name for the data role, a description of the data role, synonyms for the data role name, a data role identification string, a data role version number, a data type (e.g., string, integer, date, Boolean, or 64-bit floating point), and / or a data role type. Some examples of data role types include (i) a dictionary data role type, which is a discrete list of valid domain values, (ii) a range of values for the data role type, which is a range (e.g., a numeric range) that defines the values that are valid, and (iii) a regular expression data role type, which includes one or more values that match one or more regular expressions to be considered valid. Each domain value in a dictionary can have an associated list of synonym values. For example, a "Month" data role (e.g., a data role with the name "Month") can have an integer type with domain values (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12) and can have synonym domains of matching string values ("January", "February", ..., "December").
[0141] In some implementations, a data role type is more meaningful when understood in combination with other data fields. For example, a zip code data field may be disabled when city and state data fields are provided. In some implementations, the importance or priority of a given data field may be determined based on a hierarchy between related data fields. For example, in a geographic hierarchy, a city data field may be prioritized over state and country data fields because the city data field provides information corresponding to a more precise location compared to the state and country data fields.
[0142] In some implementations, a semantic type is represented as an object with a set of associated defining attributes. For example, a city type is represented using the attributes city name, state name, and country name. In some implementations, only one of these attributes on the field itself is exposed.
[0143] In some implementations, a data role includes optional attributes such as default aggregation, dimension / measure, continuous / discrete, default view type (data visualization type), default formatting, units, and visual coding information. The visual coding information can include related fields and derived attributes. For example, for the Profit attribute, the derived attribute is "Profitable", which has a calculated value Profitable:=(Profit>0).
[0144] Associated Data In some implementations, data roles can be associated with field domain data. For example, a dictionary data role is defined by a list of all valid domain values. As another example, a regular expression data role references a list of valid values that are used as sample data to show the valid data to the user. In some implementations, these data roles are stored in a data source, allowing users to (i) maintain data role specific data using data sources embedded in the data role, (ii) create data roles from previously published data sources, (iii) use published data sources output from a data preparation flow on a server that is refreshed on a schedule as dictionary data role data, and / or (iv) manage connections to data sources used in bulk by the data role along with connections from other data sources.
[0145] In some implementations, a user can publish a workbook with data sources embedded in it that are private to the workbook. A workbook may also reference published data sources that are available to others to connect to. In some implementations, a user is allowed to make changes to connections. In some implementations, a user is allowed to make changes in bulk (e.g., across many data sources). In some implementations, connections used by both published and embedded data sources can be edited together.
[0146] Exemplary uses of associated data in data roles include: · The user exposes a user-defined dictionary data role from a data preparation flow where the source data of a data field is cleaned. If the user does not want this data to be visible on the server outside the data role, the data source is marked accordingly (e.g. with a label such as "embedded extract only"). · A user exposes a user-defined dictionary data role from a data preparation flow where the source data for a data field is cleaned. If the user makes this data visible on the server outside of the data role so that the data can be connected separately from the data role for analysis, the data source is marked accordingly (e.g. with a label such as "published extract only"). A user creates a user-defined dictionary data role from a data source that is already published on the server and has a live connection to a database (e.g., a Hadoop database). In this case, the data source is published as a live connection to the database. A user uses a published data source that is an extracted CSV as the source of example data for a regex data role. In this case, the data source is a published extract connected to a file.
[0147] Correcting Data In some implementations, the application includes a user interface that allows the user to edit and modify the data source values. For example, when a data role uses an embedded data source with a connection to a file, the user may be able to modify the data source values on the server via the user interface.
[0148] In some implementations, such as when a data role uses a published data source, a user can use any application or tool used to create the data role and its associations and to modify the data role.
[0149] FIG. 7A illustrates a UML model 700 of a data role that uses a data source to store domain values, according to some implementations. The example data role 702 illustrated in FIG. 7A stores semantic information including a name, name synonyms, a description, a role type (regular expression or dictionary), and a data type. In some implementations, a data field associated with the data role 702 has one or more display formats 704 for displaying values. The data role 702 can have a dictionary role 706 and / or a regular expression role 708, according to some implementations. If the data role 702 performs the role of a dictionary, according to some implementations, the domain values of the dictionary role are stored in a data source 710. If the data role performs the role of a regular expression (sometimes referred to as a "regexp"), according to some implementations, the data source 710 stores sample domain values. In some implementations, the data source 710 is an embedded data source 714. In some implementations, the data source 710 is a public data source 712 .
[0150] 7B illustrates an exemplary process for assigning data roles, according to some implementations. Assume that a user wishes to change (720) a data field identified as a string to latitude (i.e., change the semantic role or semantic information). Some implementations are provided with a menu of different options for the user to select in response to selecting an open type menu option 722. Assume further that the user selects (724) the latitude option from the geography category 726. In some implementations, various subcategories of geography type data are displayed, including latitude 728. Assuming the user selects the latitude option 728, some implementations allow the user to reopen (730) the type menu to confirm the current selection. For example, the type menu is refreshed to show the subcategory latitude 732 for the Geography type field. Thus, some implementations allow the user to change the semantic role of the data field.
[0151] FIG. 7C illustrates an exemplary user interface 734 for validating data, according to some implementations. In some implementations, a user may be allowed to set data validation rules 736. In some implementations, a user may be allowed to set triggers or notifications 738 (e.g., actions to be taken when validation fails). In some implementations, a user may be allowed to enter validation rules and have them converted into a data role. In the example shown, the user has selected to validate the data using a regular expression 740. In some implementations, various options for validation are provided using a pull-down menu. The example also illustrates a regular expression 742 that the user entered to validate the data. After the user selects a validation rule, in some implementations, an option 744 is provided to save the validation rule as a data role. In some implementations, each customer (identified by customer ID 746) is presented with certain options based on their permissions. (In some implementations, the options displayed also depend on past usage, the data field, data roles of similar fields, and / or object level information.) Some implementations also provide the option to switch between data sources or databases 748 when setting validation rules and / or data roles.
[0152] FIG. 7D illustrates an exemplary user interface window for improved searches using semantic information, according to some implementations. In some implementations, an interface (e.g., a first interface 750) is provided that provides an overview of the columns. In some implementations, a summary bar for the entire profile card is provided so that the user can evaluate the quality of the filters, data roles, or suggestions. In some implementations, an option 752 is provided to select search criteria. In some implementations, a fit indicator 754 is provided that indicates the degree to which the underlying data fits the search criteria. Some implementations also provide an indication 756 of the confidence level of the suggestions (e.g., from low to very high). In some implementations, a second interface (e.g., interface 758) is provided that allows the user to set default search behavior. Records that match the search results are shown by default, according to some implementations. In the illustrated example, the user sees options related to email 760. In some implementations, the appropriate email domain address (e.g., .com 762) is selected and / or various options 764 of email addresses are shown. In some implementations, a third interface (e.g., interface 766) is provided for in and out searches. In some implementations, the user can select the "out" portion of the chart to view in and out of the records. In the example shown, the user selects email 768 and the system responds by selecting domain 770 and / or several email options 772. In some implementations, a fourth interface (e.g., interface 774) is provided for regular expression filtering. In some implementations, the data preparation application recognizes regular expression search patterns and filters using the patterns. In some implementations, the user can switch to see the in and out portions of the chart directly.In the example shown, the user has selected to filter email 776. In some implementations, a regular expression 778 is shown, as well as a sampling 780 of email addresses that match the regular expression.
[0153] In some implementations, a user interface and / or options are provided for authoring and / or editing data roles. In some implementations, a user option is provided for editing domain values. In some implementations, a user is allowed to import or export a CSV or Excel file to modify an embedded data role. In some implementations, a user is allowed to edit regular expressions (e.g., validation rules for a data role). In some implementations, an embedded data source is an extract file with no associated source data document. In some implementations, a data role has a specific data format for increased machine readability and / or ease of manipulation. In some implementations, the specific file format allows for exporting or sharing data roles with other prep (i.e., data preparation) users without a server. In some implementations, an embedded data source is embedded in the same document that contains the data fields. In some implementations, a user is allowed to drop a file into a preparation folder or prep repository folder to add a data role.
[0154] In some implementations, data roles have a proprietary format (e.g., a JSON file format stored in the Semantic Service) that contains information about the data role, including its name, validation criteria, and sort order. In some implementations, data roles are associated with exposed or embedded data sources (e.g., a particular data format that a data visualization platform or data preparation flow knows how to consume, update, edit, and / or assign permissions).
[0155] In some implementations that expose data role formats to users and others, such information is hidden or concealed from the user. In some implementations, users are allowed to expose data roles from a shared data role file (e.g., via a data preparation or prep flow). In some implementations, users are allowed to create data roles using command line and / or using bulk add or batch processing.
[0156] In some implementations, users are allowed to review data values and apply regular expressions to data values for testing. In some implementations, users are allowed to import or connect to database tables or systems and set data roles. In some implementations, embedded data roles are excluded from searches.
[0157] In some implementations, a user may be allowed to set or change permissions for access to a data role. For example, a data preparation user may want to save a data role for a personal user and not publish the data role for sharing with others. FIG. 7E illustrates an example user interface 782 for controlling permissions for access to a data role, according to some implementations. In some implementations, a search box 784 for searching for a user and options for granting permission 788 to view 790, interact / edit 792, and / or edit 794 the data role (and / or the underlying data source or view 798) are provided. Some implementations allow a user to select a user or a group of users 786. In some implementations, a user may be allowed to add 796 another user or group rule 796. Thus, in various implementations, access control for data roles is provided.
[0158] In some implementations, differential access to (and / or control over) global data roles versus local data roles (local to some group of data objects) and / or custom data roles versus built-in data roles are provided. In some implementations, built-in data roles are not editable. In some implementations, users are allowed to view data sources that reference values that correspond to built-in roles (e.g., geographic roles).
[0159] In some implementations, users are allowed to catalog and / or search the lineage contained in a data catalog of data roles. In some implementations, users are allowed to search for data roles and / or for objects (e.g., data sources) that use data roles. In some implementations, semantic browseable and / or searchable content (e.g., content hosted by a data visualization server) is provided. In some implementations, lineage information for custom data roles is excluded. In some implementations, data roles are treated like other content on a database server, allowing users to search for data roles by name rather than value without needing a catalog. In some implementations, data roles are allowed to be packaged as products that can be sold like other database products. In some implementations, users are allowed to specify data roles while authoring desktop or web documents. In some implementations, users are allowed to associate data roles with fields in desktop applications so that the data is automatically validated when the information is exported to a data source and / or brought into a data preparation dataflow.
[0160] Data Rollup and Cleanup In some implementations, data roles are automatically updated to reflect changes in a user's workflow. In some implementations, data roles are automatically maintained by cleaning up data roles (e.g., updating and / or removing old, out-of-date, or irrelevant data roles).
[0161] In some implementations, data roles are output to a database that does not support semantic types. In some implementations, when outputting data roles to a database, semantic types are mined and the mined semantic types are written out. In some implementations, semantic types are used as an aid to clean up the data. In some implementations, there are multiple output steps, some of which write back to a database (that does not support semantic types). In some implementations, no semantic types are output from the workflow, even though semantic types are used to facilitate cleanup and / or shaping of data roles.
[0162] In some implementations, the user is allowed to connect to a data source and the data provided by the data source is used without type conversion or data cleanup. This step allows the user to view the data before any changes are made to the data. In some implementations, for databases with strongly typed fields, the data type is indicated in the input step. For text files (e.g., CSV), in some implementations, all data is identified with a string data type and additional data type identification is performed in a subsequent conversion step.
[0163] To further illustrate, assume that a user wishes to filter data to include only data from the past three months. In some implementations, the user is provided with at least two options in the input step: a moderate option that includes primitive type identification, and a flexible option that includes semantic type identification. Assume further that the user selects the moderate option. Some implementations respond by identifying primitive data types (e.g., numbers, strings, dates, or Booleans) without cleaning up the data. In some implementations, an initial data type inference is performed for text files. In some implementations, filtering is supported. For fields where data type identification results in a drop of data or values, some implementations notify the user and allow the user to perform cleanup in a subsequent conversion step, e.g., by changing the data type to string. More advanced semantic type identification is only performed in a subsequent conversion step. Conversely, assume that the user selects the flexible option. In some implementations, the user is allowed to mine and / or assign data types. In some implementations, the user is allowed to mine semantic types during the input step. In some implementations, the user can initiate semantic type mining to ensure that initial data type identification is fast and efficient. For example, the first step may include an option to launch semantic type analysis. In some implementations, the user can optionally clean up the data during the input step. In some implementations, all type mining and / or no cleanup is allowed during the input step.
[0164] In some implementations, filtering is performed during the input step to remove unnecessary fields, so that they are excluded from the workflow. For example, rows can be filtered out to reduce the data passing through the flow. In some cases, such as when sampling limits are imposed, filtering is performed during the input step in some implementations. In some implementations, semantic types are identified to make it easier for users to understand which data fields should be excluded or filtered out during the input step. In some implementations, data cleanup or semantic type suggestions are provided whether all domains of data fields are provided or known.
[0165] In some implementations, data cleanup is an iterative process that balances the interactive performance of the tool with the robustness of running flows on all data. In some cases, data may need to be updated or cleaned up for several reasons, such as when working with sampled data and when transitioning to data that includes all domains. In other words, the cleanup may remain accurate and sufficient for a limited period of time, but transitioning to data that includes all domains changes the data and introduces new domain values, thereby invalidating assumptions about the data. For example, an iterative data cleanup process includes providing suggestions to the user so that the user may clean the data based on the sampled data. The user then runs the flow, and various types of assertions trigger notifications that inform the user about where the processed data runs counter to assumptions made interactively during the first step. In a particular example, the user sets groups and replacement mappings for data fields. When the user runs all flows, new values other than the original sample data are discovered. Alternatively, the user may use groups to change the data type of a data field and replace the data values in the data field to map to values in the specification. In such cases, a new value in a data field is discovered that is not valid for the previously defined data type (when working with sampled data). As a result of any of these scenarios, in some implementations, the user receives a series of resulting notifications when the user reopens the flow, and the user can edit the flow to take this new information into account. After finishing any edits, the user can run the flow again.
[0166] Semantic Role Interaction with Data Types In some implementations, semantic types are treated as an extension to an existing type system. For example, a user selects a single data type name (e.g., "Email address") that identifies a primitive data type (e.g., string) and any associated semantics. When a user selects the "Email address" type, the data type of the data field is changed to "string" (if it is not already) and invalid values in the data field are identified to the user. In such implementations, semantic type processing allows for there to be a single underlying data type for a semantic role. The selected data type best reflects the semantics of the role and allows a user to perform expected operations and / or cleanup on values with that role. In some cases, not casting values to an ideal underlying data type may cause problems, such as preventing a user from normalizing values to a single representation or performing meaningful calculations or cleanup operations.
[0167] In some implementations, the semantic role is treated as independent of the underlying primitive data type, and the two attributes may be changed independently of each other. For example, a user may set the data type to "Whole Number" to see which values are invalid, and then apply the semantic role "Email Address" to a data field (e.g., the values are all numeric, and the data type remains Whole Number). In another example, zip codes are stored in an integer data type, and the semantic role is set to "Zip Code / Postcode". In this way, the semantic role is applied without changing the data type of the data field, even though the most general data type needed to allow all valid values is actually "String" (to handle alphanumeric zip codes and possibly hyphens). In some cases, this is useful if the user ultimately wants the data field to be written back to the database so that it remains an integer data type.
[0168] In some implementations, a user may access all of the semantic roles available for any data through a user interface. Additionally, the user interface may also include any of the following: a list of available data types that should be suitable for any data field; a list of available semantic roles that should be suitable for any data field; a list of available data types and / or data roles; a list of semantic roles from which a user may choose where each of the semantic roles is independent of the current field data type (e.g., a user may change from any permutation of data types or data roles to any other permutation). In some implementations, the user interface displays both semantic roles and primitive data types (e.g., via representative icons on field headers that summarize the data fields). In some implementations, changing the formatting of a data field does not change the data type to maintain the calculated value. In some implementations, a user may merge formatting into a data field during an output step (e.g., export, write, save).
[0169] In some implementations, data types are maintained separate from semantic roles. This is useful when the output target does not retain the semantic roles (e.g., modeling attributes). In such cases, it may be useful to maintain a user perception of stable data type elements throughout the workflow. In some implementations, the underlying base data types are maintained without changing the data types, and the semantic roles are stored independently. For example, in some implementations, this information appears in a tooltip when the system detects input (e.g., the user moves or hovers over the data type icon in the profile). The user perception of the data types is also important in computations (which only work with primitive data types). In some implementations, the user perception of the data types is maintained without changing the data types and semantic roles independently of each other. In some implementations, the representation of the data is maintained throughout the workflow such that the information displayed in the user interface maintains context throughout the user's workflow. For example, the data representation is maintained from an input step (e.g., a data cleanup step) to an output step (e.g., a save, publish, export, or write step).
[0170] In some implementations, a semantic role applies to more than one data type. In some implementations, once a semantic role is selected, the data type is not automatically changed in order to keep the data type consistent for output purposes.
[0171] In some implementations, when different data field types are present, the data field may be automatically changed to a more general type (without semantics) that can represent values in both data fields. Alternatively, when dealing with different data field types, the data field may be automatically changed to a more general type that can represent values in both fields. On the other hand, if the semantic roles are different, the semantic roles are automatically cleared.
[0172] In some implementations, invalid joins are identified based on the semantic roles of the join clause fields. For example, assume that the join clause fields have different data types or different semantic types. In some implementations, invalid joins are identified when the join clauses have similar semantic roles.
[0173] In some implementations, the data type of a data field retains its original data type regardless of format (e.g., even when a user changes the display format of the data field) so that the data field can be manipulated predictably. For example, a date data field may be in pure numeric format or string format, but retains the same canonical date data type regardless of how it is displayed. In another example, a "day of week" data field retains its underlying numeric type even when the data field value displays text such as "Monday", so that calculations can still be performed using the "day of week" data value. For example, if the value is "Monday", the calculated value "day + 1" results in "Tuesday". In this example, accepted data values are strings (e.g., "Sunday", "Monday", ... "Friday", "Saturday"). At the output node, the data type of the "day of week" data field may need to be changed depending on the user's goals and output targets. For example, data may be output to a strongly typed database, so that the data output defaults to the base data type and a date data field needs to be switched to a "string" data type to maintain formatting. Alternatively, in some implementations, the data output defaults to a "string" data type and therefore does not require a data type change to preserve formatting. In some implementations, the data type may be changed by the user.
[0174] In some implementations, various semantic type operations are supported while maintaining the underlying primitive data type. For example, assume a user manipulates a date field of type Date to change the format of the date. In some implementations, the primitive data type of the date is maintained as an integer even as the format changes. In some implementations, the primitive data type is identified and the semantic type is only indicated when the user requests the type.
[0175] In some implementations, data is not cleaned up at the input node (described above). In some implementations, the user will be notified of any data that is dropped by type assignment and will be provided with an opportunity to edit the data in a subsequent transform node. In some implementations, the transform node may be initiated by the user from the input node. Additionally, data quality and cardinality may not be displayed during the input step, only shown during the transform step.
[0176] In some implementations, semantic types have a corresponding mode. Some implementations include strict and lax modes. When a semantic type is in strict mode, values that fall outside the type definition are not kept within the domain. When a semantic type is set to lax mode, values that fall outside the type definition are kept within the domain and carried through the flow. In some implementations, primitive types are always strict and do not support values that fall outside the range of the type definition throughout the flow.
[0177] In some implementations, a text scan is performed and the user is notified if data is being dropped for a particular type. In some implementations, the values of the dropped data are provided to the user. In some implementations, in the case of a type change operation, values that fall out of the type's range (to be dropped) are marked in the profile view when the type change recipe is selected. In some implementations, these dropped values are no longer displayed when the user moves to a new (e.g., next) recipe. In this way, the user is provided with immediate visibility to the dropped (or to be dropped) values, so that the user can select them and perform a remap, if necessary. Additionally, in some implementations, the user is allowed to select an action from a list of actions, which creates a remap to null for all values that fall out of the range of the type definition. In some implementations, the user can also edit or refine the remap, or select a remap action from one or more of the suggestions or suggestions provided. In some implementations, the remap is performed immediately before the type change operation (because the dropped values do not leave the type change operation and cannot be remapped after the type change) so that the remap values flow into the type change. In some implementations, semantic types are used as data assertions rather than as types or in addition to being treated as types. In some implementations, a user can indicate to the system "this is the sort of data I expect here; notify me if that is not the case," and the system automatically notifies the user accordingly.
[0178] In some implementations, additional automatic cleanup steps are included to provide type identification and suggestions. In some implementations, the additional automatic cleanup steps are run in the background (e.g., by a backgrounder) or can be canceled by the user.
[0179] For example, when an existing column is cloned, if any data for a particular type is being dropped, the values in the column being dropped are remapped to null. In some implementations, a side-by-side comparison of the original and cloned columns is provided.
[0180] In some implementations, the user is allowed to add an auto-clean step, which adds a step and initiates type identification and suggestions. In some implementations, the step runs as a background job. In some implementations, a user option is provided to cancel the job while it is running.
[0181] In some implementations, columns are duplicated to clean up the data. In some implementations, existing columns are duplicated, the column's type default value is mapped to null, a side-by-side comparison of columns is performed or displayed (e.g., selecting null in the mapped column and brushing the mapped value in the duplicated column), and the user is allowed to select data field values that fall outside the type value of the duplicated column and filter to retrieve only rows that contain the value, showing other fields in the row as the context for the correction. In some implementations, the user is allowed to correct the null-mapped values in the duplicated column and then remove the original column. In some implementations, an interface similar to the join clause tuple remap user interface is used to allow the user to perform the operations described herein.
[0182] In some implementations, to perform a robust correction, all domain values of the field are obtained. In some implementations, the domain values are indicated.
[0183] In response to a type change action, some implementations incorporate a remap to automatically map out-of-spec values to null. Some implementations allow the user to edit the remap from the type change recipe.
[0184] In some implementations, values that fall outside of the type specification are shown when the user selects a type change recipe. In some implementations, out-of-spec values disappear when another recipe is added (so they do not move through the flow). In some implementations, remaps for these values are performed or edited inline, which creates a remap recipe before the type change recipe. In some implementations, values that are groups are shown with a group icon when the user selects a recipe.
[0185] In some implementations, the type change operation creates a recipe that remaps out-of-spec values to null, followed by a type change recipe, which remaps the values before making the type change. In some implementations, this is used as a fallback if it is not possible to display out-of-spec values marked in the domain when the user selects the type change recipe.
[0186] In some implementations, a type change action implicitly excludes any values that fall outside the type specification. In some implementations, a recipe corresponds to the number of excluded values. In some implementations, a user is allowed to create a remap upstream for the type change mapping (e.g., to map excluded values to null). In some implementations, when the cleanup flow runs, a list of excluded values is provided to the user so that the user can add the values upstream and remap them to clean up the data.
[0187] In some implementations, the user interface allows a user to delete a recipe by dragging a selected annotation (corresponding to the recipe) out of the profile. In some implementations, type assignment is strict in the input and output steps and non-strict (e.g., loose) during intermediate steps (e.g., steps between the input and output steps) to preserve values.
[0188] In some implementations, the data type and / or semantic role of a field indicate the user's aspirations for what the user wants the data in the data field to be. In combination with the data name, the data type helps convey meaning and provide understanding of the data field. For example, if the value is a decimal number called "Profit", the value is likely to be either a dollar or a percentage. In this way, the data type can inform or determine which sorting operations are allowed on the data field, thereby providing both the user and the application with increased confidence regarding the context (including inferred context) of the data field (and possibly the data source) and the results of operations such as applying calculations, remapping, or filters. For example, if a data field has a numeric type, the user can be confident that the user can perform mathematical calculations.
[0189] In some implementations, the semantic role of a data field is used to help users clean up data by highlighting values that do not match the data type and require cleanup and / or filtering. In some implementations, the data type and / or semantic role of a data field provide context and enable a data preparation application to perform automated cleanup operations on the data field.
[0190] In some implementations, when a user selects to change the type of a field, values that are outside the type specification are grouped together and mapped to null. In some implementations, such values are filtered out and / or the user is allowed to inspect and / or edit the values in the group. In some implementations, values outside the type specification and values outside the semantic roles are grouped separately. In some implementations, the user is allowed to select the groups and merge / apply the groups to the new field.
[0191] In some implementations, a profile summary view is shown that shows a visualization of selected outliers (e.g., null values). In some implementations, a histogram shows each value. In some implementations, values that do not match the data type (e.g., labeled "Dropped"), values that do not match the semantic role (e.g., labeled "Invalid"), and / or outliers are selected. In some implementations, values that do not match the data type are shown using strike-through text. In some implementations, values that do not match the semantic role are shown in red text or by a special icon. In some implementations, values are filtered to show only outliers, values that do not match the data type, and / or values that do not match the semantic role. In some implementations, a search box is provided for filtering, allowing the user to activate a search to "Search within invalid values" using an option in a dropdown. In some implementations, an option is provided for filtering the list. In some implementations, an option is provided to select individual outliers or entire summary histogram bars and move the selection to another field (e.g., with a right-click option or drag-and-drop functionality) or move values between fields to create a new field. In some implementations, the data type of the new field is indicated and / or an indication is provided that all values match the data type. In some implementations, the user is provided with the option to clean up the values in the new field and / or drag the dropped values or entire fields back to the original field to merge back the changes.
[0192] Data Preparation Suggestions In some implementations, the automated suggestions include transforming values of individual fields. In some cases, this may be facilitated by assigning a data role to the data field. In other cases, assigning a data role to the data field is not required. Once a data role is applied to a data field, validation rules are applied to the data values of the data field, and outliers are displayed with different visual treatments in the profile and data grid (e.g., outliers may be emphasized, such as by being highlighted or shown in a different color font, or de-emphasized, such as by being grayed out or shown in a lighter color font). This visual treatment of outliers is maintained throughout various steps in the workflow.
[0193] In some implementations, the remapping suggestions include (i) manual remapping of outliers, (ii) remapping of outliers by utilizing fuzzy matching against a domain associated with the assigned data role, and / or (iii) automatic remapping of outliers to null.
[0194] In some implementations, a one-click option is provided to filter out outliers. In some implementations, a one-click option is provided to extract outliers into a new data field so the user can edit the extracted values (manually, through a remap operation, or by applying a data role) and then merge the edited values back into the data field or store the edited values separately. In some implementations, an option is provided to drop the data field if most of the values are null.
[0195] In some implementations, when a user selects a data role for a particular data field, the data preparation application provides transformation suggestions. For example, for a domain in a URL or an area code in a phone number, the transformation suggestions may include extract / split transformations (e.g., from 1112223333 to "area code" = "111" and "phone number" = "2223333"). In another example, the transformation suggestions may include suggestions to reformat data fields such as (i) state names to state abbreviations (e.g., from California to CA), (ii) phone numbers to specific formats (e.g., from 1112223333 to (111) 222-3333), and (iii) transform dates to be represented in different formats or with different extracted parts (e.g., from December 1, 1990 to extract only the year or change the format to 12 / 01 / 1990).
[0196] In some implementations, date fields of various formats are automatically parsed, validated, and / or corrected / cleaned up. In some implementations, country values are standardized. In some implementations, values are displayed based on a canonical list of names. In some implementations, age is recognized as a positive number and / or options are provided to search and / or standardize age values. In some implementations, a user is allowed to standardize a list of database names based on a connector name. In some implementations, a user is allowed to further edit options and / or provide manual overrides. In some implementations, city, state, or similar values are standardized based on semantic roles.
[0197] In some implementations, remapping suggestions are used to inform the user that semantics of the data fields have been identified and to present the user with suggestions for cleaning up the data. In some implementations, the cleanup suggestions include showing at least a portion of the metadata to the user so the user can better understand what each suggestion is and why it is relevant to the user's needs. In some implementations, the user's selections drive analysis and / or further suggestions. In some implementations, the user interface includes options for the user to view overviews and / or details, zoom, and / or filter data fields and / or data sources.
[0198] In some implementations, the user interface includes result previews (e.g., a preview of the results of operations such as applying a filter, zoom, or data roll) so that the user can proceed with confidence.
[0199] FIG. 8 illustrates an exemplary user interface 800 for previewing and / or editing cleanup suggestions, according to some implementations. The example illustrated in FIG. 8 illustrates suggestions 802 for a city 804. In some implementations, a list of suggested options is shown first, followed by further suggestions 806. In some implementations, a confidence level 808 for the additional suggestions 806 is shown. In some implementations, specific suggestions (or individual values) are shown, which may be particularly useful for long values or names. In some implementations, multiple possible suggestions are shown if the confidence is below a predefined threshold (e.g., an 80% confidence level). In some implementations, more suggestions are shown in response to a user click or selection. In some implementations, particularly for long suggestions, the user is allowed to select from the list 810 without having to type the additional suggestions. In some implementations, such options (e.g., in-group mode and replace editor) are provided as part of the display modes. In some implementations, a user option is provided to switch between display modes. For example, one display mode may be more appropriate for one set of data roles, while another display mode may be more appropriate for another set of data roles.
[0200] 9A-9D illustrate example user interfaces for resource suggestions based on semantic information, according to some implementations. FIG. 9A illustrates various interfaces for manipulating portions of dates, according to some implementations. Exemplary interface 900 is a pill-style context menu showing various options for dates. Exemplary interface 902 shows a right drag-and-drop option that allows a user to drop a field (a date type in this example). Exemplary interface 904 shows an option for a user to enter text for search actions. Exemplary interface 906 shows an option for creating a custom date. Exemplary interface 908 shows an option for adding and / or editing field mappings to allow a user to edit relationships (e.g., relationships between fields). In some implementations, DATEPART and / or DATETRUNC functions are provided for manipulating date fields. FIG. 9B illustrates various interfaces for manipulating portions of URLs. Exemplary interface 910 is a pill-style context menu showing various options for URLs. Exemplary interface 912 shows a right drag-and-drop option that allows a user to drop a field (a URL type in this example). Exemplary interface 914 shows options for a user to enter text to search for actions corresponding to a URL. Exemplary interface 916 shows options for creating a custom URL. Exemplary interface 918 shows options for adding and / or editing field mappings to allow a user to edit relationships between URL fields. In some implementations, functions are provided for manipulating data fields and / or data roles, similar to BigQuery's HOST(), DOMAIN(), and TLD() functions. FIG. 9C shows various interfaces for manipulating portions of an email address.Exemplary interface 920 is a pill-style context menu showing various options for an email. Exemplary interface 922 shows a right drag-and-drop option that allows a user to drop a field (a portion of an email in this example). Exemplary interface 924 shows an option for a user to enter text to search for actions corresponding to the email. Exemplary interface 926 shows an option for creating a custom email or filtering the email (e.g., using a date). Exemplary interface 928 shows an option for adding and / or editing field mappings to allow a user to edit relationships between email fields. FIG. 9D shows various interfaces for manipulating a portion of a name. Exemplary interface 930 is a pill-style context menu showing various options for a name. Exemplary interface 932 shows a right drag-and-drop option that allows a user to drop a field (a portion of a name in this example). Exemplary interface 934 shows an option for a user to enter text to search for actions corresponding to the name. Exemplary interface 926 shows an option for creating a custom name or filtering the email (e.g., using a date). The example interface 928 shows options for adding and / or editing field mappings to allow a user to edit relationships between email fields. In some implementations, examples of field names are included, parts are grouped, truncations are included, and / or parts are matched (for editing field mappings) in one or more user interfaces.
[0201] 10A-10N provide a flowchart 1000 of a method for preparing data for subsequent analysis according to some implementations. The method is typically performed on a computer 200 having a display 208, one or more processors 202, and a memory 214 that stores one or more programs configured to be executed by the one or more processors.
[0202] The method includes obtaining (1002) a data model (e.g., object model 108) that encodes a first data source as a tree of logical tables. Each logical table has its own physical representation and includes one or more logical fields. Each logical field corresponds to either a data field or a calculated value that spans one or more logical tables. Each edge of the tree connects two related logical tables. The method also includes associating (1004) each logical table in the data model with a corresponding concept in a conceptual graph. The conceptual graph (e.g., a directed acyclic graph) embodies the hierarchical inheritance of the semantics of the logical tables. An exemplary conceptual graph, according to some implementations, is described above with reference to FIG. 4. The method also includes, for each logical field (1006) included in the logical table, assigning (1008) a semantic role (sometimes referred to as a data role) to the logical field based on the concept that corresponds to the logical table.
[0203] Referring now to FIG. 10B, in some implementations, the method further includes storing (1016) for each logical field its assigned semantic role in the first data source (or the auxiliary data source).
[0204] Referring now to FIG. 10C, in some implementations, the method further includes generating a second data source based on the first data source (1018) and, for each logical field, storing its assigned semantic role in the second data source.
[0205] 10D, in some implementations, the method further includes retrieving (1020) a representative semantic role (e.g., a semantic role assigned to a similar logical field) from a second data source different from the first data source for each logical field. Assigning a semantic role to the logical field is further based on the representative semantic role. In some implementations, a user input is detected from the first user, and the method further includes determining (1022) whether the first user is authorized to access the second data source before retrieving the representative semantic role from the second data source.
[0206] 10E, in some implementations, the method further includes displaying, in a user interface, a first one or more semantic roles for the first logical field based on a concept corresponding to a first logical table that includes the first logical field (1024). The method also includes assigning a preferred semantic role to the first logical field in response to detecting a user input selecting a preferred semantic role (1026). In some implementations, the method further includes selecting, based on the preferred semantic role, a second one or more semantic roles for the second logical field (1028). The method also includes displaying, in a user interface, a second one or more semantic roles for the second logical field (1030). In response to detecting a second user input selecting a second semantic role from the second one or more semantic roles, the method includes assigning a second semantic role to the second logical field (1032). In some implementations, the method further includes training one or more predictive models based on the one or more semantically labeled data sources (e.g., data sources that include data fields that have been assigned or labeled with semantic roles) (1034). The method also includes determining the first one or more semantic roles by inputting concepts corresponding to the first logical table into the one or more predictive models (1036).
[0207] Referring now to FIG. 10F, in some implementations, the logical field is a calculated value based on the first data field and the second data field (1038), and assigning a semantic role to the logical field is further based on a first semantic role corresponding to the first data field and a second semantic role corresponding to the second data field.
[0208] Referring now to FIG. 10G, in some implementations, the method includes determining (1040) a default format of a data field corresponding to the logical field, and assigning a semantic role to the logical field is further based on the default format of the data field.
[0209] Referring now to FIG. 10H, in some implementations, the method further includes selecting and storing (1042) default formatting options for displaying the logical field based on the assigned semantic role in the first data source.
[0210] 10I, in some implementations, prior to assigning semantic roles to the logical fields 1044, the method further includes displaying the conceptual graph and one or more options for modifying the conceptual graph in a user interface 1046. In response to detecting user input to modify the conceptual graph, the method includes updating the conceptual graph according to the user input 1048.
[0211] Referring back to FIG. 10A, the method also includes validating the logical field based on its assigned semantic role (1010). Referring now to FIG. 10J, in some implementations, the semantic role includes a domain of the logical field (1050), and validating the logical field includes determining whether the logical field matches one or more domain values of the domain. The method further includes determining one or more transformations based on the one or more domain values before displaying the one or more transformations. Referring now to FIG. 10K, in some implementations, the semantic role is a validation rule (e.g., a regular expression) used to validate the logical field (1052).
[0212] 10A , the method further includes displaying, in a user interface on the display, one or more transformations for cleaning up (or filtering) the logical field based on validating the logical field (1012). In response to detecting user input selecting a transformation for transforming the logical field, the method transforms the logical field according to the user input and updates the logical table based on transforming the logical field (1014).
[0213] 10L, in some implementations, the method further includes determining a first logical field to add to the first logical table based on the concept of the first logical table (1054). The method also includes displaying a suggestion to add the first logical field in a user interface (1056). In response to detecting a user input to add the first logical field, the method includes updating the first logical table to include the first logical field (1058).
[0214] 10M, in some implementations, the method further includes determining (1060) a second dataset corresponding to the second data source for joining with the first dataset corresponding to the first data source based on the conceptual graph. The method also includes displaying (1062) in a user interface a suggestion to join the second dataset with the first dataset of the first data source. In response to detecting a user input to join the second dataset, the method also includes creating a join between the first dataset and the second dataset and updating the tree of logical tables (1064).
[0215] 10N, in some implementations, the method further includes detecting changes to the first data source (1066). In some implementations, detecting changes to the first data source is performed at a predetermined time interval (1068). In response to detecting changes to the first data source (1070), the method includes updating the conceptual graph according to the changes to the first data source (1072) and repeating the assigning, validating, displaying, converting, and updating for each logical field according to the updated conceptual graph (1074).
[0216] The terminology used in the description of the invention herein is for the purpose of describing particular implementations only and is not intended to limit the invention. When used in the description of the invention and the appended claims, the singular forms "a", "an" and "the" are intended to include the plural forms unless the context clearly dictates otherwise. It will also be understood that the term "and / or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items. It will be further understood that the terms "comprises" and / or "comprising" as used herein specify the presence of stated features, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, steps, operations, elements, components, and / or groups thereof.
[0217] The foregoing description has been described with reference to specific implementations for purposes of illustration. However, the exemplary discussion above is not intended to be exhaustive or to limit the invention to the precise forms disclosed. Many modifications and variations are possible in light of the above teachings. The implementations have been chosen and described in order to best explain the principles of the invention and its practical application, so that those skilled in the art can make best use of the invention and its various implementations with various modifications suitable for the particular use contemplated.
Claims
1. 1. A method of preparing data for subsequent analysis, comprising:
1. A computer having a display, one or more processors, and a memory storing one or more programs configured for execution by the one or more processors, obtaining a data model encoding a first data source as a tree of logical tables, each logical table having its own physical representation and including a respective one or more logical fields, each logical field corresponding to either a data field or a calculated value spanning one or more logical tables, each edge of the tree connecting two related logical tables; Associating each logical table in the data model with a corresponding concept in a conceptual graph, the conceptual graph embodying a hierarchical inheritance of semantics; For each logical field in the logical table, assigning semantic roles to the logical fields based on concepts corresponding to the logical tables; validating the logical field based on its assigned semantic role; displaying, in a user interface on the display, one or more transformations for cleaning up the logical field based on validating the logical field; in response to detecting user input selecting a transformation for transforming the logical field, transforming the logical field in accordance with the user input, and updating the logical table based on transforming the logical field.
2. The method of claim 1 , further comprising: for each logical field, storing its assigned semantic role in the first data source.
3. 2. The method of claim 1, further comprising: generating a second data source based on the first data source; and for each logical field, storing its assigned semantic role in the second data source.
4. 2. The method of claim 1, further comprising: for each logical field, retrieving a representative semantic role from a second data source different from the first data source; and assigning the semantic role to the logical field further based on the representative semantic role.
5. 5. The method of claim 4, wherein the user input is detected from a first user, the method further comprising determining whether the first user is authorized to access the second data source before retrieving the representative semantic role from the second data source.
6. displaying, in the user interface, a first one or more semantic roles for a first logical field based on a concept corresponding to a first logical table that includes the first logical field; The method of claim 1 , further comprising: in response to detecting user input selecting a preferred semantic role, assigning the preferred semantic role to the first logical field.
7. selecting a second one or more semantic roles for a second logical field based on the preferred semantic roles; and displaying, in the user interface, the second one or more semantic roles for the second logical field; and 7. The method of claim 6, further comprising: in response to detecting a second user input selecting a second semantic role from the second one or more semantic roles, assigning the second semantic role to the second logical field.
8. training one or more predictive models based on one or more semantically labeled data sources; 7. The method of claim 6, further comprising: determining the first one or more semantic roles by inputting the concepts corresponding to the first logical table into the one or more predictive models.
9. 2. The method of claim 1 , wherein the logical field is a calculated value based on a first data field and a second data field, and wherein assigning the semantic role to the logical field is further based on a first semantic role corresponding to the first data field and a second semantic role corresponding to the second data field.
10. The method of claim 1 , further comprising determining a default format of a data field corresponding to the logical field, and wherein assigning the semantic role to the logical field is further based on the default format of the data field.
11. The method of claim 1 , further comprising selecting and storing in the first data source default formatting options for displaying the logical field based on the assigned semantic role.
12. Prior to assigning the semantic role to the logical field, displaying, in the user interface, the conceptual graph and one or more options for modifying the conceptual graph; The method of claim 1 , further comprising, in response to detecting a user input to modify the concept graph, updating the concept graph according to the user input.
13. the semantic role includes a domain of the logical field, and validating the logical field includes determining whether the logical field matches one or more domain values of the domain; The method of claim 1 , the method further comprising, prior to displaying the one or more transformations, determining the one or more transformations based on the one or more domain values.
14. The method of claim 1 , wherein the semantic role is a validation rule used to validate the logical field.
15. determining a first logical field for adding to the first logical table based on a concept of the first logical table; displaying in the user interface a suggestion to add the first logical field; 2. The method of claim 1, further comprising: in response to detecting a user input to add the first logical field, updating the first logical table to include the first logical field.
16. determining a second data set corresponding to a second data source for combining with the first data set corresponding to the first data source based on the conceptual graph; displaying in the user interface a proposal to combine the second data set with the first data set of the first data source; 2. The method of claim 1, further comprising: in response to detecting a user input to join the second dataset, creating a join between the first dataset and the second dataset and updating the logical table tree.
17. Detecting changes to the first data source; In response to detecting the change to the first data source, updating the conceptual graph according to the changes to the first data source; 2. The method of claim 1, further comprising: repeating the assigning, validating, displaying, converting, and updating for each logical field according to the updated conceptual graph.
18. The method of claim 9 , wherein detecting the changes to the first data source is performed at predetermined time intervals.
19. 1. A computer system for generating a data visualization, comprising: one or more processors; A memory, The memory stores one or more programs configured to be executed by the one or more processors, the one or more programs comprising: obtaining a data model encoding a first data source as a tree of logical tables, each logical table having its own physical representation and including a respective one or more logical fields, each logical field corresponding to either a data field or a calculated value spanning one or more logical tables, each edge of the tree connecting two related logical tables; Associating each logical table in the data model with a corresponding concept in a conceptual graph, the conceptual graph embodying a hierarchical inheritance of semantics; For each logical field in the logical table, assigning semantic roles to the logical fields based on concepts corresponding to the logical tables; validating the logical field based on its assigned semantic role; displaying, in a user interface on the display, one or more transformations for cleaning up the logical field based on validating the logical field; in response to detecting user input selecting a transformation for transforming the logical field, transforming the logical field in accordance with the user input, and updating the logical table based on transforming the logical field.
20. 1. A non-transitory computer-readable storage medium storing one or more programs configured to be executed by a computer system having a display, one or more processors, and a memory, the one or more programs comprising: obtaining a data model encoding a first data source as a tree of logical tables, each logical table having its own physical representation and including a respective one or more logical fields, each logical field corresponding to either a data field or a calculated value spanning one or more logical tables, each edge of the tree connecting two related logical tables; Associating each logical table in the data model with a corresponding concept in a conceptual graph, the conceptual graph embodying a hierarchical inheritance of semantics; For each logical field in the logical table, assigning semantic roles to the logical fields based on concepts corresponding to the logical tables; validating the logical field based on its assigned semantic role; displaying, in a user interface on the display, one or more transformations for cleaning up the logical field based on validating the logical field; in response to detecting user input selecting a transformation for transforming the logical field, transforming the logical field in accordance with the user input, and updating the logical table based on transforming the logical field.
Citation Information
Patent Citations
Format conversion device and method, and computer program
JP2004341605A
Specifying and applying logical validation rules to data
JP2017509971A
Data cleansing tool with new cleansing tree
US20150278258A1
