ExportTabs / output.json
Muhammad Mustehson
Initial Draft
44de337
[
{
"body": "{\"chart_data\": {\"bar\": {\"data\": [{\"x\": \"1\", \"y\": 2483550}, {\"x\": \"2\", \"y\": 598081}, {\"x\": \"0\", \"y\": 121958}, {\"x\": \"4\", \"y\": 31334}, {\"x\": \"3\", \"y\": 17793}, {\"x\": \"5\", \"y\": 1}]}}, \"table_data\": {\"payment_type\": [1, 2, 0, 4, 3, 5], \"trip_count\": [2483550, 598081, 121958, 31334, 17793, 1]}, \"chart_config\": {\"type\": \"bar\", \"title\": \"Total Number of Trips by Payment Type\", \"x_axis_label\": \"Payment Type\", \"y_axis_label\": \"Number of Trips\", \"legend\": false, \"colors\": []}, \"sql_config\": {\"sql_query\": \"SELECT payment_type, COUNT(*) AS trip_count FROM sample_data. nyc.taxi GROUP BY payment_type ORDER BY trip_count DESC LIMIT 20000;\", \"explanation\": \"Counts the number of trips for each payment type.\", \"text_query\": \"What is the total number of trips by each payment_type?\"}, \"error\": {\"success\": true}, \"hash_key\": \"da469599b102c658f3ef269c9ba5770b\"}"
},
{
"body": "{\"chart_data\": {\"line\": {\"data\": [{\"x\": \"2022-10-31\", \"y\": 34}, {\"x\": \"2022-11-01\", \"y\": 120506}, {\"x\": \"2022-11-02\", \"y\": 126271}, {\"x\": \"2022-11-03\", \"y\": 131484}, {\"x\": \"2022-11-04\", \"y\": 130682}, {\"x\": \"2022-11-05\", \"y\": 130401}, {\"x\": \"2022-11-06\", \"y\": 104570}, {\"x\": \"2022-11-07\", \"y\": 112135}, {\"x\": \"2022-11-08\", \"y\": 121121}, {\"x\": \"2022-11-09\", \"y\": 128700}, {\"x\": \"2022-11-10\", \"y\": 132727}, {\"x\": \"2022-11-11\", \"y\": 117728}, {\"x\": \"2022-11-12\", \"y\": 130944}, {\"x\": \"2022-11-13\", \"y\": 114269}, {\"x\": \"2022-11-14\", \"y\": 82278}, {\"x\": \"2022-11-15\", \"y\": 90728}, {\"x\": \"2022-11-16\", \"y\": 92660}, {\"x\": \"2022-11-17\", \"y\": 95344}, {\"x\": \"2022-11-18\", \"y\": 95454}, {\"x\": \"2022-11-19\", \"y\": 94932}, {\"x\": \"2022-11-20\", \"y\": 81125}, {\"x\": \"2022-11-21\", \"y\": 108526}, {\"x\": \"2022-11-22\", \"y\": 114546}, {\"x\": \"2022-11-23\", \"y\": 105640}, {\"x\": \"2022-11-24\", \"y\": 69663}, {\"x\": \"2022-11-25\", \"y\": 86607}, {\"x\": \"2022-11-26\", \"y\": 99513}, {\"x\": \"2022-11-27\", \"y\": 90529}, {\"x\": \"2022-11-28\", \"y\": 106488}, {\"x\": \"2022-11-29\", \"y\": 119372}, {\"x\": \"2022-11-30\", \"y\": 117677}, {\"x\": \"2022-12-01\", \"y\": 57}]}}, \"table_data\": {\"x\": [\"2022-10-31\", \"2022-11-01\", \"2022-11-02\", \"2022-11-03\", \"2022-11-04\", \"2022-11-05\", \"2022-11-06\", \"2022-11-07\", \"2022-11-08\", \"2022-11-09\", \"2022-11-10\", \"2022-11-11\", \"2022-11-12\", \"2022-11-13\", \"2022-11-14\", \"2022-11-15\", \"2022-11-16\", \"2022-11-17\", \"2022-11-18\", \"2022-11-19\", \"2022-11-20\", \"2022-11-21\", \"2022-11-22\", \"2022-11-23\", \"2022-11-24\", \"2022-11-25\", \"2022-11-26\", \"2022-11-27\", \"2022-11-28\", \"2022-11-29\", \"2022-11-30\", \"2022-12-01\"], \"y\": [34, 120506, 126271, 131484, 130682, 130401, 104570, 112135, 121121, 128700, 132727, 117728, 130944, 114269, 82278, 90728, 92660, 95344, 95454, 94932, 81125, 108526, 114546, 105640, 69663, 86607, 99513, 90529, 106488, 119372, 117677, 57]}, \"chart_config\": {\"type\": \"line\", \"title\": \"Total Number of Trips per Day Over Time\", \"x_axis_label\": \"Date\", \"y_axis_label\": \"Number of Trips\", \"legend\": false, \"colors\": []}, \"sql_config\": {\"sql_query\": \"SELECT CAST(tpep_pickup_datetime AS DATE) AS x, COUNT(*) AS y FROM sample_data.nyc.taxi GROUP BY x ORDER BY x LIMIT 20000;\", \"explanation\": \"Counts the number of trips per day based on the pickup datetime and formats the data for line plot.\", \"text_query\": \"What is the total number of trips per day over time?\"}, \"error\": {\"success\": true}, \"hash_key\": \"fc224d097e70ed97e3c95914afb2c0d5\"}"
},
{
"body": "{\"chart_data\": {\"hist\": {\"data\": [{\"bin_start\": 0, \"bin_end\": 1, \"frequency\": 667647.0}, {\"bin_start\": 1, \"bin_end\": 2, \"frequency\": 1043642.0}, {\"bin_start\": 2, \"bin_end\": 3, \"frequency\": 547827.0}, {\"bin_start\": 3, \"bin_end\": 4, \"frequency\": 268437.0}, {\"bin_start\": 4, \"bin_end\": 5, \"frequency\": 140938.0}, {\"bin_start\": 5, \"bin_end\": 10, \"frequency\": 296746.0}, {\"bin_start\": 10, \"bin_end\": 20, \"frequency\": 251072.0}, {\"bin_start\": 20, \"bin_end\": 30, \"frequency\": 34069.0}, {\"bin_start\": 30, \"bin_end\": 40, \"frequency\": 1547.0}, {\"bin_start\": 40, \"bin_end\": 50, \"frequency\": 355.0}, {\"bin_start\": 50, \"bin_end\": 100, \"frequency\": 303.0}]}}, \"table_data\": {\"bin_id\": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], \"frequency\": [667647, 1043642, 547827, 268437, 140938, 296746, 251072, 34069, 1547, 355, 303]}, \"chart_config\": {\"type\": \"hist\", \"title\": \"Distribution of Trip Distance\", \"x_axis_label\": \"Trip Distance (miles)\", \"y_axis_label\": \"Frequency\", \"legend\": false, \"colors\": []}, \"sql_config\": {\"sql_query\": \"\\nSELECT \\n CASE \\n WHEN trip_distance < 1 THEN 1\\n WHEN trip_distance < 2 THEN 2\\n WHEN trip_distance < 3 THEN 3\\n WHEN trip_distance < 4 THEN 4\\n WHEN trip_distance < 5 THEN 5\\n WHEN trip_distance < 10 THEN 6\\n WHEN trip_distance < 20 THEN 7\\n WHEN trip_distance < 30 THEN 8\\n WHEN trip_distance < 40 THEN 9\\n WHEN trip_distance < 50 THEN 10\\n ELSE 11\\n END AS bin_id,\\n COUNT(*) AS frequency\\nFROM \\n sample_data.nyc.taxi\\nWHERE \\n trip_distance < 100\\nGROUP BY \\n bin_id\\nORDER BY \\n bin_id;\\n\", \"explanation\": \"Retrieves the frequency of trips within specified distance bins for the first 1000 rows using CASE statements.\", \"text_query\": \"What is the distribution of trip_distance? only use first 1000 rows\"}, \"error\": {\"success\": true}, \"hash_key\": \"3ba0e8041cabdeee7f140c9232eb16f7\"}"
},
{
"body": "{\"chart_data\": {\"pie\": {\"data\": [{\"x\": \"1.0\", \"y\": 90.54768674926224}, {\"x\": \"2.0\", \"y\": 4.076100072646959}, {\"x\": \"nan\", \"y\": 3.7494193315926347}, {\"x\": \"5.0\", \"y\": 0.9550169904114006}, {\"x\": \"3.0\", \"y\": 0.27749109436818514}, {\"x\": \"99.0\", \"y\": 0.2704508261862314}, {\"x\": \"4.0\", \"y\": 0.1231893214196009}, {\"x\": \"6.0\", \"y\": 0.0006456141127555825}]}}, \"table_data\": {\"RatecodeID\": [1.0, 2.0, NaN, 5.0, 3.0, 99.0, 4.0, 6.0], \"trip_count\": [2945260, 132584, 121958, 31064, 9026, 8797, 4007, 21], \"percentage\": [90.54768674926224, 4.076100072646959, 3.7494193315926347, 0.9550169904114006, 0.27749109436818514, 0.2704508261862314, 0.1231893214196009, 0.0006456141127555825]}, \"chart_config\": {\"type\": \"pie\", \"title\": \"Percentage Share of Trips by RatecodeID\", \"x_axis_label\": \"RatecodeID\", \"y_axis_label\": \"Percentage\", \"legend\": true, \"colors\": []}, \"sql_config\": {\"sql_query\": \"SELECT RatecodeID, COUNT(*) AS trip_count FROM sample_data.nyc.taxi GROUP BY RatecodeID ORDER BY trip_count DESC LIMIT 20000;\", \"explanation\": \"Counts the number of trips for each RatecodeID.\", \"text_query\": \"What is the percentage share of trips by RatecodeID? show as pie chart\"}, \"error\": {\"success\": true}, \"hash_key\": \"0efdf6fa1df25fd3116353db8630552d\"}"
},
{
"body": "{\"chart_data\": {\"bar\": {\"data\": [{\"x\": \"2\", \"y\": 2.929572542537025}, {\"x\": \"1\", \"y\": 2.579547053346901}, {\"x\": \"6\", \"y\": 0.0}]}}, \"table_data\": {\"x\": [2, 1, 6], \"y\": [2.929572542537025, 2.579547053346901, 0.0]}, \"chart_config\": {\"type\": \"bar\", \"title\": \"Average Tip Amount per VendorID\", \"x_axis_label\": \"VendorID\", \"y_axis_label\": \"Average Tip Amount\", \"legend\": false, \"colors\": []}, \"sql_config\": {\"sql_query\": \"SELECT VendorID AS x, AVG(tip_amount) AS y FROM sample_data. nyc.taxi GROUP BY VendorID ORDER BY y DESC LIMIT 20;\", \"explanation\": \"Calculates the average tip_amount for each VendorID and orders the results by the average tip amount in descending order, limiting to the top 20 VendorIDs.\", \"text_query\": \"What is the average tip_amount per VendorID?\"}, \"error\": {\"success\": true}, \"hash_key\": \"9db02b369fb12b3c3b1974d32e2cb47c\"}"
}
]