[2024] Snowflake Cortex — SUMMARIZE Function

This function returns a summary of the given English text.

Syntax

SNOWFLAKE.CORTEX.SUMMARIZE(text)

where

Text is a string containing the English text from which a summary should be generated.

Function Output

The output is a string containing a summary of the original text.

Usage

You can use it you ask a prompt based on the input by the user OR you can also use your data which resides inside snowflake table.

This is a summary of a bad experience of a passenger travelling from Delhi to Vancouver.

select SNOWFLAKE.CORTEX.SUMMARIZE($$
I recently had a very disappointing and stressful experience on my flight from Delhi (DEL) to Vancouver (YVR). The whole journey was plagued with issues and it left me with a bitter taste in my mouth.

To begin with, the flight schedule kept changing multiple times before my departure date. This caused a lot of inconvenience as I had to keep rearranging my plans and make last-minute changes. The lack of proper communication about these changes only added to my frustration.

On the day of my flight, I arrived at the airport to find out that my flight was delayed by four hours. This was not only frustrating but also exhausting as I had a connecting flight to catch in Vancouver. Despite the long delay, there was no proper explanation or updates provided by the airline staff.

When I finally boarded the flight, I was shocked to see the condition of the aircraft. The seats were old and uncomfortable, and there was a musty smell in the cabin. Additionally, the in-flight entertainment system was not working, which made the long journey even more unbearable.

The worst part of the flight was the food. It was tasteless and poorly prepared. To make matters worse, the flight attendants were rude and unaccommodating when I requested a vegetarian meal, which I had pre-booked. I had to settle for some fruits and crackers for my entire meal.

To top it all off, my baggage did not arrive with me at YVR. It was frustrating to have to wait for hours at baggage claim only to find out that my luggage was still in Delhi. I had to file a report and wait for two days before my baggage was finally delivered to my hotel.

Overall, my experience with this flight was highly disappointing. The constant delays, poor service, uncomfortable seats, and lost baggage left me stressed and exhausted. I expected much better from this airline, especially for the price I paid for my ticket. I would not recommend this airline to anyone and I will definitely think twice before booking another flight with them.
$$
) AS customer_feedback;

The below is the output:

The author had a disappointing and stressful experience on a flight from Delhi (DEL) to Vancouver (YVR). The flight schedule changed multiple times, causing inconvenience, and the day of the flight was delayed by four hours without proper communication or explanation. The aircraft was old with uncomfortable seats, a musty smell, and a malfunctioning in-flight entertainment system. The food was poorly prepared and the vegetarian meal the author had pre-booked was not provided. To top it off, the author’s luggage was lost and took two days to be delivered. Overall, the experience was disappointing and left the author frustrated and exhausted.

About Me:

Hi there! I am Divyansh Saxena

I am an experienced Cloud Data Engineer with a proven track record of success in Snowflake Data Cloud technology. Highly skilled in designing, implementing, and maintaining data pipelines, ETL workflows, and data warehousing solutions. Possessing advanced knowledge of Snowflake’s features and functionality, I am a Snowflake Data Superhero & Snowflake Snowpro Core SME. With a major career in Snowflake Data Cloud, I have a deep understanding of cloud-native data architecture and can leverage it to deliver high-performing, scalable, and secure data solutions.

Follow me on Medium for regular updates on Snowflake Best Practices and other trending topics:

Also, I am open to connecting all data enthusiasts across the globe on LinkedIn:

https://www.linkedin.com/in/divyanshsaxena/

--

--