Generate concise, intelligent summaries of text or documents with AI
POST
/
v1
/
ai
/
summary
import{JigsawStack}from"jigsawstack";const jigsaw =JigsawStack({apiKey:"your-api-key"});const response =await jigsaw.summary({"text":"The Leaning Tower of Pisa, or simply, the Tower of Pisa, is the campanile, or freestanding bell tower, of Pisa Cathedral. It is situated behind the Cathedral and is the third-oldest structure in the city's Cathedral Square, after the Cathedral and the Baptistry. The tower's tilt began during construction in the 12th century, caused by an inadequate foundation on ground too soft on one side to properly support the structure's weight. The tilt increased in the decades before the structure was completed in the 14th century. It gradually increased until the structure was stabilized by efforts in the late 20th and early 21st centuries. The height of the tower is 55.86 metres (183.27 feet) from the ground on the low side and 56.67 metres (185.93 feet) on the high side. The width of the walls at the base is 2.44 m (8 ft 0.06 in). Its weight is estimated at 14,500 tonnes. The tower has 296 or 294 steps; the seventh floor has two fewer steps on the north-facing staircase.","type":"points","max_points":3})
{"success":true,"summary":["The Leaning Tower of Pisa is the bell tower of Pisa Cathedral.","Its tilt began during construction due to an unstable foundation.","The tower's tilt worsened over time until stabilization efforts in modern times."],"_usage":{"input_tokens":256,"output_tokens":61,"inference_time_tokens":890,"total_tokens":1207}}
The text content to summarize. Maximum 300,000 characters.
Not required if url or file_store_key is specified.
The text parameter supports two formats:
Single string: {"text":"Your long text here"}
Array of strings: {"text":["Long text 1", "Long text 2"]}
An array of strings, where each string represents a bullet point in the
summary.
import{JigsawStack}from"jigsawstack";const jigsaw =JigsawStack({apiKey:"your-api-key"});const response =await jigsaw.summary({"text":"The Leaning Tower of Pisa, or simply, the Tower of Pisa, is the campanile, or freestanding bell tower, of Pisa Cathedral. It is situated behind the Cathedral and is the third-oldest structure in the city's Cathedral Square, after the Cathedral and the Baptistry. The tower's tilt began during construction in the 12th century, caused by an inadequate foundation on ground too soft on one side to properly support the structure's weight. The tilt increased in the decades before the structure was completed in the 14th century. It gradually increased until the structure was stabilized by efforts in the late 20th and early 21st centuries. The height of the tower is 55.86 metres (183.27 feet) from the ground on the low side and 56.67 metres (185.93 feet) on the high side. The width of the walls at the base is 2.44 m (8 ft 0.06 in). Its weight is estimated at 14,500 tonnes. The tower has 296 or 294 steps; the seventh floor has two fewer steps on the north-facing staircase.","type":"points","max_points":3})
{"success":true,"summary":["The Leaning Tower of Pisa is the bell tower of Pisa Cathedral.","Its tilt began during construction due to an unstable foundation.","The tower's tilt worsened over time until stabilization efforts in modern times."],"_usage":{"input_tokens":256,"output_tokens":61,"inference_time_tokens":890,"total_tokens":1207}}
import{JigsawStack}from"jigsawstack";const jigsaw =JigsawStack({apiKey:"your-api-key"});const response =await jigsaw.summary({"text":"The Leaning Tower of Pisa, or simply, the Tower of Pisa, is the campanile, or freestanding bell tower, of Pisa Cathedral. It is situated behind the Cathedral and is the third-oldest structure in the city's Cathedral Square, after the Cathedral and the Baptistry. The tower's tilt began during construction in the 12th century, caused by an inadequate foundation on ground too soft on one side to properly support the structure's weight. The tilt increased in the decades before the structure was completed in the 14th century. It gradually increased until the structure was stabilized by efforts in the late 20th and early 21st centuries. The height of the tower is 55.86 metres (183.27 feet) from the ground on the low side and 56.67 metres (185.93 feet) on the high side. The width of the walls at the base is 2.44 m (8 ft 0.06 in). Its weight is estimated at 14,500 tonnes. The tower has 296 or 294 steps; the seventh floor has two fewer steps on the north-facing staircase.","type":"points","max_points":3})
{"success":true,"summary":["The Leaning Tower of Pisa is the bell tower of Pisa Cathedral.","Its tilt began during construction due to an unstable foundation.","The tower's tilt worsened over time until stabilization efforts in modern times."],"_usage":{"input_tokens":256,"output_tokens":61,"inference_time_tokens":890,"total_tokens":1207}}