Data Model (Node Type)

From Grooper Wiki

This article is about the current version of Grooper.

Note that some content may still need to be updated.

2025

STUB

This article is a stub. It contains minimal information on the topic and should be expanded.

data_table Data Models are leveraged during the Extract activity to collect data from documents (folder Batch Folders). Data Models are the root of a Data Element hierarchy. The Data Model and its child Data Elements define a schema for data present on a document. The Data Model's configuration (and its child Data Elements' configuration) define data extraction logic and settings for how data is reviewed in a Data Viewer.

About

The Data Model defines the data structure for a Content Type and can live at varying levels of structure, allowing for inheritance if a hierarchy exists.  This can be a simple list of data fields or a complex hierarchy of sections, subsections, tables and fields.  

The Data Model is leveraged by Grooper to extract data from a Batch.  All extraction logic (i.e. referencing a Data Extractor to fill a field, performing a database lookup, or generating a calculated field expression) is set on the Data Model or the Data Elements related to the Data Model.  It also provides information to the Data Review activity setting expectations for field appearance and behavior (i.e. if a field is required before completing batch validation).  

One Data Model can be created for each:


Data context can be critical to build the Data Type and Field Class extractors to populate a Data Model. For more information on this topic, visit the Data Context article.

Data Models in Grooper

Data Models are used for three main purposes in Grooper. The first and most obvious is Data Extraction

Extraction

A Data Model organizes its data using three child element types:

  • Data Field: Captures a single value, such as an invoice number or date.
  • Data Section: Groups related fields and tables, supporting hierarchical and repeating structures.
  • Data Table: Extracts tabular data, such as line items or transaction logs.

During extraction, Grooper uses the Data Model to guide the process. Each child element extracts its data from the document, and the results are fed up to the parent Data Model. The extraction process is typically performed by the "Extract" activity on a Batch Folder. For more information about the Extract Activity, click here.

The Run Child Extractors property allows you to control which child elements are extracted. If no elements are specified, all children are extracted. You can use this property to selectively extract or re-extract only certain fields, sections, or tables, which is useful for custom workflows or partial data updates.

Inheritance and overrides

Data Models in Grooper support inheritance, allowing a child Data Model to inherit structure and properties from a parent. This enables you to define common data elements once and reuse them across multiple document types. Properties and behaviors can be overridden in child Data Models, providing flexibility to customize extraction, validation, or appearance for specialized scenarios.

For example, you might have a base Data Model for generic invoices, with child Data Models for different invoice formats from different companies. Each child can override specific properties or add new fields as needed, while still inheriting the shared structure.

Appearance and styling

Data Models can be styled to improve visualization and usability in the Grooper UI. You can customize the appearance of Data Fields, Data Sections, and Data Tables by setting properties such as "Display Width", "Alignment", "Placeholder", and "Caption". Styling options help users review and edit extracted data more efficiently, and can make complex documents easier to navigate.

Resource Files (such as CSS) can be linked to a Data Model to further customize the look and feel of data grids and review screens. This allows for tailored user experiences and supports branding or compliance requirements.

Object Model info

Type name: Grooper.Core.DataModel

Inheritance

Grooper Object (Grooper.GrooperObject)
Connected Object (Grooper.ConnectedObject)
Node (Grooper.GrooperNode)
Data Element (Grooper.Core.DataElement)
Data Field Container (Grooper.Core.DataFieldContainer)
Data Element Container (Grooper.Core.DataElementContainer)
Data Model (Grooper.Core.DataModel)