Skip to content

Group Data By Key

The “Group Data By Key” component is designed to help you organize your data by grouping it based on a specific column. This makes it easier to format and analyze your data using a user-defined template. It’s a handy tool for anyone looking to streamline their data management processes in Nappai.

Relationship with Nappai

This component is part of the Nappai automation and AI assistant system. It helps users automate the task of grouping and formatting data, which is a common requirement in data management systems and applications.

Inputs

  • Key Column: Choose the column by which you want to group your data.
  • Data: The actual data you wish to organize.
  • Template: A customizable format for your grouped data, allowing you to include specific keys like {text} or {data}.
  • Separator: Decide how to separate formatted text, with a default option of a new line.
  • Metadata keys: Specify any additional metadata columns you want to include in your output.

Outputs

The component produces “Processed Data,” which is a list of your data grouped and formatted according to the specified key column. This output can be used to create more organized reports or to feed into other components for further processing.

Usage Example

Imagine you have a dataset of customer orders and you want to group these orders by customer ID. By using the “Group Data By Key” component, you can easily organize the orders for each customer and format them using a template that highlights key information like order date and total amount.

Templates

Currently, there are no specific flow templates where this component is used. However, it can be configured in any workflow that requires data grouping and formatting.

  • libSQLRetrieverTool: Interacts with libSQL Retriever to fetch data.
  • Embedding Similarity: Computes similarity between embedding vectors.
  • SQLite: Connects with SQLite databases for data interaction.
  • Supabase: Manages data in Supabase Vector Store with search capabilities.
  • Google Drive: Loads files from Google Drive for processing.

Tips and Best Practices

  • Always ensure your “Key Column” is correctly specified to achieve the desired grouping.
  • Use the “Template” input to customize how your grouped data is presented.
  • Consider using the “Metadata keys” input to enrich your output with additional information.

Security Considerations

When using this component, ensure that any sensitive data is handled in compliance with your organization’s data protection policies. Avoid including personal or confidential information in templates or metadata unless necessary and secure.