Installation
Install the plugin using npm:Configuration & Parameters
Thesummarize function accepts a configuration object with the following parameters:
Usage Examples
Basic Usage
Custom Summary Length
Percentage-Based Summary
Troubleshooting
- Plugin not triggering: Double-check that the
sheetSlugin your configuration exactly matches the slug of your Sheet in Flatfile - Summaries not appearing: Verify that the
contentField,summaryField, andkeyPhrasesFieldnames are correct and that thecontentFieldactually contains text - Data not being processed: Ensure the
summaryFieldis empty for records you expect to be processed, as the plugin will not overwrite existing summaries
Notes
Default Behavior
By default, the plugin generates a summary containing 2 sentences. The summarization logic takes sentences from the beginning and end of the source text to form the summary. The plugin will only generate a summary and key phrases if the targetsummaryField is empty; it will not overwrite existing data. If the source contentField for a record is empty, the plugin will add an error to that field and skip processing for that record.
Limitations and Considerations
- The pluginβs summarization algorithm is basic: it combines a number of sentences from the beginning and end of the text, separated by ββ¦β. It is not an abstractive or AI-based summarization
- The plugin will not overwrite data. If the
summaryFieldalready contains a value for a given record, that record will be skipped - Key phrase extraction is based on a fixed grammatical pattern (
#Adjective? #Adjective? #Noun+), which identifies phrases consisting of up to two optional adjectives followed by one or more nouns - The plugin depends on the
compromiseNLP library, and the quality of the output is determined by its capabilities - The plugin is designed to work on
stringfield types
Error Handling
The main error handling pattern is to check for preconditions on a per-record basis. If a precondition fails (e.g., the source text field is empty), the plugin adds a field-level error to the record usingrecord.addError(). This provides direct feedback to the user in the Flatfile UI without halting the entire import process.
