Picky Assist Help Desk
Main WebsiteBlogFacebook Community
Picky Assist Help Desk
Picky Assist Help Desk
  • Welcome To Picky Assist 🙏
  • Setting Up Guide
    • Sending First Message
    • Connecting Channels
      • WhatsApp Web Automation to Official API Migration Guide 2024
      • Connecting WhatsApp Web Automation
      • Connecting Facebook Messenger
        • Introduction
        • Getting Start
        • Guidelines & Compliances
        • Messenger Link
      • Connecting WhatsApp Official
        • Introduction
        • Dashboard
        • Profile
        • Templates
      • Connecting WhatsApp Cloud API
      • WhatsApp Official Managed Service
      • Connecting Instagram
      • Phone Bridge (Call Blaze)
      • Connecting SMTP
      • Connecting Amazon SES
      • Connecting Sendgrid
      • Connecting Additional WhatsApp Numbers
      • Porting WhatsApp Number to Picky Assist
      • WhatsApp Official Message Delivery Issues & Solutions
    • Working With Prebuilt CRM Modules
      • Introduction
      • Onboarding
      • Modules
        • Leads
        • Deals
        • Meetings
        • Company
        • Support Cases
        • System Modules
          • Contacts
          • Notes
          • Task
          • Call Logs
          • Tags
          • Activity Logs
      • Automations
        • Workflows
        • Chatbots
        • Funnels
        • Connectors
        • Scheduler
        • Other Prebuilt Features
      • Reports and Dashboard
      • Mandatory Preconditions for Using Prebuilt
      • Testing Prebuilt
    • Managing Organization
    • Setting Up Teambox
      • Introduction
      • Routing Rules
      • Teambox
      • Inbox View
      • Organization Hierarchy
      • Analytics
    • Setting Up Smart Replies
      • Introduction
      • Train Module
        • Training Bot Introduction
        • Topics / Categories
        • Intent & Context
        • Question Variations
        • Uploading Bulk Questions
        • Reply with Media Files
        • Personalising Replies
        • Smart Actions
        • Direct URL
        • Fall Back Response
        • Small Talks
        • Testing the Bot
        • Publishing Bot
      • ChatGPT Integration
      • Learn Module
      • Stats Module
      • Deep Linking
      • Settings
    • Smart Reply V2
      • Introduction
      • ChatGPT Integration
      • Train Module
        • Training Bot Introduction
        • Topics / Categories
        • Intent & Context
        • Question Variation
        • Uploading Bulk Questions
        • Reply with Media Files
        • Personalizing Replies
        • Smart Actions
        • Direct URL
        • Fall Back Response
        • Small Talks
        • Publishing Bot
      • Learn Module
      • Stats Module
      • Deep Linking
      • Settings
    • Setting Up Broadcaster
      • Introduction
      • Creating a Campagin
      • Sending Message to WhatsApp Groups
      • Reports
      • Broadcaster V2
        • Introduction
        • Creating Campaign
        • Reports
    • Setting Up Sequence
      • Introduction
      • Creating New Sequence
      • Sequence Stats
      • Subscribe & Unsubscribe
      • Disabling Sequence Message
    • Setting Up Reminder
    • Setting Up Mobile App
    • Setting Up Connector
      • Introduction
      • Getting Started
      • Steps
        • Introduction
        • Filters
        • Delay
        • Iterator
        • Stats
      • Actions
      • Formatter
        • Date & Time
        • Counter
        • Math Calculation
        • Data Parser
        • Convert File
        • Line Items
      • Building Mini App
      • Email Parser
      • Data Storage
      • Simulate Test
      • Connector Logs
    • Email Builder
    • Setting Up Flow Builder
      • Fundamentals (Must Read)
      • Basic Terminology (Must Read)
      • Guide to Building an Effective Chatbot (Must Read)
      • Create, Manage, Test & Publish Flows
      • Triggering a Chatbot Flow
      • Steps
        • Introduction (Must Read)
        • Send Message
        • Ask A Question
        • Filter
        • Save Data
        • Actions
        • Check WhatsApp Session
        • Delay
        • Smart Delay
        • Formatter
        • Splitter
        • Data Lookup
        • Trigger HTTP API
        • Webhook
        • Apps
        • Match Keywords
        • Route to Chatbot
        • End
      • Saving Data into CRM
      • Analytics
      • Integrations
      • Flow Builder logs and conversational logs
      • Chatbot Best Practices, Ideas & FAQ
    • Setting up Modular CRM
      • Fundamentals (Must Read)
      • Guide to Building and Implementing a Modular CRM (Must Read)
      • Create & Manage Data Modules
      • CRM Macro Buttons
      • Adding Records into CRM
      • Data View & Manage Records
      • Task
      • Workflows
      • Funnels
      • Data Import
      • Integrations
    • Setting Up Scheduler
    • Media Gallery
    • Quick Replies
    • Opt-out Settings
    • Blacklist
    • Global Variables
    • Setting Up Ad-On's
      • Setting Up WhatsMail
      • Setting Up Zendesk
      • Setting Up Zapier
      • Setting Up Zoho CRM
        • Getting Started
        • Working with Extension
        • Integrating with Zoho Workflow
        • Lead Assignment Rules
        • Integrating into Custom Modules
        • Connecting Multiple WhatsApp Numbers into Zoho CRM
        • Integrating WhatsApp with Zoho CRM Mobile App
        • Keyboard Shortcuts
      • Setting Up Facebook Lead Adform
      • Facebook Lead Ad form V2
      • Setting Up WhatsApp Web
      • Setting Up Pabbly Connect
      • Setting Up ChatGPT App
    • Google Chrome Extensions
      • Extension for Sending WhatsApp Messages from any Webpage
      • Chrome Extension V2
      • Extension for Zoho CRM & Teambox
    • Managing Profile
      • Two Factor Aunthentication
      • Login History
      • Delete Account
    • Quick Rollout Guide
      • WhatsApp Official Account
    • Developers & Partners Guide for Deep Integration of Picky Assist
  • API Documentation V2
    • Introduction
    • Quick Start Guide 🏃
    • Global Webhook
      • How Webhook Works
      • Webhook Variables
      • Configuring Webhook URL
      • Webhook Request & Response
      • Getting the Conversation Context
      • Testing Your Webhook
    • Event Webhook
      • How Event Webhook Works
      • Event Webhook Variables
      • Configuring Event Webhook URL
      • Event Webhook Sample Request & Response
    • Push API
      • Introduction
      • API Variables
      • Sending Single Message - Push
      • Sending Dynamic Messages – Push
      • Sending Media Attachments – Push
      • Sending Interactive List & Buttons
      • Sending Stickers
      • Sending Bulk Messages - Push
      • Sending Contacts
      • Sending Location
      • Sending WhatsApp Template Messages
        • Introduction
        • Sending WhatsApp Template Text Messages
        • Sending WhatsApp Template Image
        • Sending WhatsApp Template Document
        • Sending WhatsApp Interactive Buttons
        • Sending WhatsApp Limited Time Offer Templates
      • Sending Message to Groups
      • Sending SMS Using SIM Card
      • Sending Message to Facebook Messenger
      • Normal Post Method
      • Delivery Reports
      • Push API Must Read Instructions
      • Testing API Requests
    • WhatsApp Template API
      • Introduction
      • API Variables
      • Template Request API
      • Template Status API
      • Languages
      • Guidelines
    • WhatsApp Group API
      • Introduction
      • API Variables
      • Create Group
      • Set Group Permission
      • Add Group Admin
      • Add Group Members
      • Fetch Group Details
      • Update Group Info
      • Remove Group Members / Admin
      • Generate New Invite Link
      • Group Delete Actions
    • WhatsApp Settings API's
      • WhatsApp Profile API
      • 2 Step Verification
      • WhatsApp Status Update
      • WhatsApp Contact & Group Fetching
    • Device Manage API’s
      • Fetching Device Status API
      • Device Commands API’s
      • WhatsApp Automation Server Status API
    • Account API
      • Fetch Balance
    • Project Management API
      • Introduction
      • Create Project
      • Get Project Details
      • Set / Update Webhook
      • Create API Token
      • Manage API Token
      • Change Billing Plan
      • Fetch Account Balance
      • Country Code & Timezones
    • References
      • Status & Error Codes
      • Most Frequent Issues & Solutions
      • Formating & Sending Emojis 😊
      • Postman Collection for Picky Assist API's
      • High Volume Messaging Bots - WhatsApp
    • Sample Codes
      • PHP
      • Python
      • Node JS
      • Ruby
      • Java
      • ASP.NET Using C#
      • Javascript
      • Go
      • Swift
      • C
      • C#
      • Objective C
  • General Guidelines
    • Billing
    • Adding Money Into Account
    • Rate Limits
    • Character Limits WhatsApp
    • Best Practices for Media Handling
    • Roadmap
    • Features In the Early Beta Version
  • Changelog
    • 2021
      • February 2021
      • March 2021
      • April 2021
      • May 2021
      • June 2021
    • 2020
      • February 2020
      • March 2020
      • April 2020
      • May 2020
      • June 2020
      • September 2020
      • October 2020
    • 2019
      • November 2019
      • October 2019
      • August 2019
      • September 2019
Powered by GitBook
On this page
  • Split Text
  • Regular Expression
  • Extract JSON
  • Setting Up JSON Extractor Fromatter
  • Replace Text
  • Replace Multiple Texts

Was this helpful?

  1. Setting Up Guide
  2. Setting Up Connector
  3. Formatter

Data Parser

Extract any data from Text

PreviousMath CalculationNextConvert File

Last updated 9 months ago

Was this helpful?

Data Parser helps you to extract specific values or text from a given sentence or paragraph, we support 2 types of data parsers now "Split Text & Regular Expression", for example "Your order id is 1234 and status is Delivered" from this sentence its possible to extract the order id as 1234 and status as Delivered

Similarly, you can extract any values using the data parser in the Picky Assist

You can select Formatter -> Data Parser -> Split Text / Regular Expression as shown below;

Split Text

Split Text helps you split a text which follows a pattern like "ORDERID 1234" here you can extract the ORDERID 1234 which is separated by a space, so the settings should be as below

In the above example, you can see that we have input the data which needs to be formatted, you can use attributes to dynamically use this feature

Split Separator: This is where you instruct the system when to split like new line, space, comma or any value you input will be considered as a delimiter to split, here we have used space

Select Segmentation Index : This is where you instruct the system which element you need after the split for example "ORDERID 1234" if you input "First Element" then the system extracts only "ORDERID" and if you select the second element then it will extract only 1234 etc

Store Converted Result To : You can give any value where the system needs to save the converted value which can be used further in the attributes under formatter

You can experiment with different combinations using the "Test" button feature by passing a sample value

Regular Expression

Using the split method you may not be able to extract all types of patterns for example, extract email addresses from the below paragraph

"Our support email address is support@pickyassist.com and our sales email address is sales@pickyassist.com"

If we want to extract the email address from the above paragraph we need to make use of regular expression so Regular expression or "Regex" is a special sequence of characters that helps you match or find patterns within a string of text.

Regular Expression: Here we have used /\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+.[A-Z|a-z]{2,}\b/ as regular expression code which can match an email address pattern and able to extract the same from the given text

Select Segmentation Index: This is where you instruct the system which element you need after the split for example the given sentence have 2 email address so whether we need the first email address or 2nd email address, the Last email address or all, if you select "All" then data will come as array in the formatter for you to select.

Store Converted Result To : You can give any value where the system needs to save the converted value which can be used further in the attributes under formatter

If you are using ChatGPT to generate Regular expressions then please add / (forward slash) starting and ending of the regular expression as shown below;

If ChatGPT gives you \b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+.[A-Z|a-z]{2,}\b then add /\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+.[A-Z|a-z]{2,}\b/

Extract JSON

JSON extractor helps you to extract JSON objects from a given string and able to map the JSON data in your connector, let's take an example usage with ChatGPT

Let's assume that you are an HR and want to analyze the CV with the help of ChatGPT and extract the following details 1) Education Background 2) Key Skills 3) Work Experience 4) Contact Details and then you want to automatically send a WhatsApp message or email to the candidate for scheduling the interview

Now ChatGPT can extract the above details from a CV and the output will be given in text format but in order to send a WhatsApp message or email automatically we need the details in a structured way like phone=4343434 & email=picky@pickyassist.com and this is where the JSON extractor will play its role

So in our ChatGPT prompt, we will add an instruction at the end of the prompt as below

"extract name, email, and phone number from the data, prefix 91 to the phone number if its length is less than or equal to 10 digits long, and create a JSON object with the extracted contact information"

Now the ChatGPT will include a JSON object in the output and it will look something as shown below;

So when you make an HTTP API call the output of the ChatGPT will have the above JSON object and this can be passed to the JSON extractor our system will extract only the JSON and make it available for you to select further in your connector as shown below;

Setting Up JSON Extractor Fromatter

Go to Connector -> Formatter -> Select -> Data Parser then select - JSON Extractor and copy and paste the output text from the ChatGPT API response then give any number to store the output variable and click on Test, you see a JSON structure as output then system mapped the JSON structure as shown below

After mapping the JSON structure with sample data, always replace it with the dynamic output from the ChatGPT as sample output is required only once for mapping the JSON structure with the connector

Replace Text

The Replace Text action in Formatter is a powerful tool that allows you to modify and refine your data by replacing specific text. This feature is particularly useful for correcting or standardising text across a dataset.

How It Works:

  1. Select Field to Format: Choose the field that contains the text you want to modify. You can either map an attribute from your data or manually enter the text you want to process.

  2. Regular Expression Field: Enter the text or regular expression pattern that matches the text you want to replace. Regular expressions allow for more complex and flexible text matching if needed.

  3. Replace Text Field: Specify the text that you want to use as the replacement. This is the new text that will replace occurrences of the matched text or pattern from the Regular Expression field.

In a customer database, you have Indian phone numbers recorded with a leading "0" (e.g., “0123456789”), and you want to replace that leading "0" with "91" (e.g., “91123456789”).

Steps:

  1. Select Field to Format: Choose the field that contains the Indian phone numbers.

  2. Regular Expression Field: Enter the following regular expression pattern to match phone numbers starting with "0":

  3. Replace Text Field: Enter 91 as the replacement text. This will replace the leading "0" with "91".

  4. Store Converted Result: Name the field where the updated phone numbers will be stored, such as “Updated Phone Number.”

The Replace Text action will convert phone numbers from “0123456789” to “91123456789,” replacing the leading "0" with "91" across your dataset.

Replace Multiple Texts

The Replace Multiple Texts allows you to modify and refine your data by replacing multiple specific texts simultaneously. This feature is particularly useful for correcting or standardising multiple texts across a dataset in one step, saving time and ensuring consistency.

Select Field to Format: Choose the field that contains the text you want to modify. You can either map an attribute from your data or manually enter the text you want to process.

Regular Expression Field: Enter multiple regular expression patterns separated by commas to match the texts you want to replace. Ensure that each pattern corresponds precisely to the text you want to find and replace.

Replace Text Field: Enter the replacement texts separated by commas. The order of the replacements must match the order of the patterns in the Regular Expression field.

Store Converted Result: Give a name to store the updated texts.

For Example; Suppose you have a dataset containing customer notifications, and you need to correct common typographical errors to ensure professional communication.

  1. Select Field to Format: Choose the field containing the text with typographical errors. For example, Your orddddder has shipped. Please wait for the delvihery.

  2. Regular Expression Field: Enter orddddder,delvihery.

  3. Replace Text Field: Enter order,delivery.

  4. Store Converted Result: Name the new field “Corrected Customer Notification” to store the updated texts.

The Replace Multiple Texts action will update all specified errors in the sentence:Your orddddder has shipped. Please wait for the delvihery. , ensuring that each instance of "orddddder" and "delvihery" is replaced with "order" and "delivery", respectively, across your dataset. This correction improves the clarity and professionalism of your customer notifications.

You can refer complete code of regular expression here

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions