• Instructions to Ask a Question

    For any assistance, please click the "Ask a Question" button and select the Pabbly product for which you require support.

    We offer seven comprehensive applications designed to help you efficiently manage and grow your business:

    Our support team endeavors to respond within 24 business hours (Monday to Friday, 10:00 AM to 6:00 PM IST). We appreciate your understanding and patience.

    🚀 Exclusive Lifetime Offers 🚀

    We invite you to take advantage of our special one-time payment plans, providing lifetime access to select applications:

    • 🔥 Pabbly Connect — Lifetime Access for $249View Offer
    • 🔥 Pabbly Subscription Billing — Lifetime Access for $249View Offer

    Make a one-time investment and enjoy the advantages of robust business management tools for years to come.

Parsing an an email into JSON

KenMen

Member
I am using the OpenAI app to parse the body text of an email into JSON. my prompt works well but I keep getting label contamination when passing data to the next app. for example openAI to my prompt results in (two results here) ->>


email Body Text: > Begin forwarded message: > > From: Ken Mendoza <[email protected]> > Subject: Fwd: City Hall Inquiry > Date: July 31, 2024 at 7:39:37 AM PDT > To: Pabbly Email <[email protected]> > > > >> Begin forwarded message: >> >> From: "City Hall Wedding Photography by Ken - Quote Form" <[email protected]> >> Subject: City Hall Inquiry >> Date: July 27, 2024 at 9:00:29 PM PDT >> To: [email protected] >> Reply-To: [email protected] >> >> . >> City Hall Wedding Photography by Ken Quote Request >> Contact InfoRole >> Groom >> >> First Name >> Mario >> >> Last Name >> Rosas >> >> Phone or WhatsApp (Note you will receive a response by Text Message) >> +1 323-404-0913 >> >> Email >> [email protected] <mailto:[email protected]>Event InfoDate of Wedding/Event (If not sure, put a date in the time frame desired) >> Thursday, August 15, 2024 >> >> Ceremony Time >> 01:00 PM >> >> City Hall Wedding Type >> Not Sure >> >> Approximate Number. of Guests >> 5 >> >> Photography PackagesI would like a quote for the following:Type of Photography >> Wedding Coverage + SF Photo Tour (1 extra location), Ceremony Only , Reception Coverage on Day of Wedding >> >> Budget >> $495-$595 >> >> How did you find us? >> Yelp >> >> Special Requests/questions if any >> >> >> . >

open AI response using my well tested prompt

[{"index":0,"message":{"role":"assistant","content":"```json\n{\n \"ContactInfo\": {\n \"Role\": \"Groom\",\n \"FirstName\": \"Mario\",\n \"LastName\": \"Rosas\",\n \"PhoneWhatsApp\": \"+1 323-404-0913\",\n \"Email\": \"[email protected]\"\n },\n \"EventInfo\": {\n \"DateOfWeddingEvent\": \"Thursday, August 15, 2024\",\n \"CeremonyTime\": \"01:00 PM\",\n \"CityHallWeddingType\": \"Not Sure\",\n \"ApproximateNumberOfGuests\": 5\n },\n \"PhotographyPackages\": {\n \"TypeOfPhotography\": [\n \"Wedding Coverage + SF Photo Tour (1 extra location)\",\n \"Ceremony Only\",\n \"Reception Coverage on Day of Wedding\"\n ],\n \"Budget\": \"$495-$595\"\n },\n \"Discovery\": {\n \"HowDidYouFindUs\": \"Yelp\"\n },\n \"SpecialRequestsQuestions\": \"\"\n}\n```"},"logprobs":null,"finish_reason":"stop"}]"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span><span class="dynamic_value" contenteditable="false" data-attr="5130793&lt;=-+*/@/*+-=&gt;result">3. Result : [{"index":0,"message":{"role":"assistant","content":"```json { \"ContactInfo\": { \"Role\": \"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"[Email]\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span>

[B]Text Formatter:[/B]

[COLOR=rgb(184, 49, 47)]<span class="dynamic_value" contenteditable="false" data-attr="5130496&lt;=-+*/@/*+-=&gt;choices">2. Choices :[/COLOR] [{"index":0,"message":{"role":"assistant","content":"```json\n{\n \"ContactInfo\": {\n \"Role\": \"Groom\",\n \"FirstName\": \"Mario\",\n \"LastName\": \"Rosas\",\n \"PhoneWhatsApp\": \"+1 323-404-0913\",\n \"Email\": \"[email protected]\"\n },\n \"EventInfo\": {\n \"DateOfWeddingEvent\&amp;q ...<!--endofdynamic_value--></span><span class="dynamic_value" contenteditable="false" data-attr="5130496&lt;=-+*/@/*+-=&gt;choices">2. Choices : [{"index":0,"message":{"role":"assistant","content":"```json\n{\n \"ContactInfo\": {\n \"Role\": \"Groom\",\n \"FirstName\": \"Mario\",\n \"LastName\": \"Rosas\",\n \"PhoneWhatsApp\": \"+1 323-404-0913\",\n \"Email\": \"[email protected]\"\n },\n \"EventInfo\": {\n \"DateOfWeddingEvent\&amp;q ...<!--endofdynamic_value--></span>

[B]JSON Extractor[/B]

[COLOR=rgb(184, 49, 47)]<span class="dynamic_value" contenteditable="false" data-attr="5130793&lt;=-+*/@/*+-=&gt;result">3. Result :[/COLOR] [{"index":0,"message":{"role":"assistant","content":"```json { \"ContactInfo\": { \"Role\": \"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"[Email]\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span><span class="dynamic_value" contenteditable="false" data-attr="5130793&lt;=-+*/@/*+-=&gt;result">3. Result : [{"index":0,"message":{"role":"assistant","content":"```json { \"ContactInfo\": { \"Role\": \"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"[Email]\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span><span class="dynamic_value" contenteditable="false" data-attr="5130793&lt;=-+*/@/*+-=&gt;result">3. Result : [{"index":0,"message":{"role":"assistant","content":"```json { \"ContactInfo\": { \"Role\": \"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"[Email]\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span><span class="dynamic_value" contenteditable="false" data-attr="5130793&lt;=-+*/@/*+-=&gt;result">3. Result : [{"index":0,"message":{"role":"assistant","content":"```json { \"ContactInfo\": { \"Role\": \"[Role]\", \"FirstName\": \"[First Name]\", \"LastName\": \"[Last Name]\", \"PhoneWhatsApp\": \"[Phone or WhatsApp]\", \"Email\": \"[Email]\" }, \"EventInfo\": { \"DateOfWeddingEvent\": \&amp; ...<!--endofdynamic_value--></span>
[ATTACH type="full"]45662[/ATTACH]



pls advise thank you!
 

Attachments

  • 1722440463032.png
    1722440463032.png
    96.9 KB · Views: 74
Top