q_id
int64 0
9.43k
| input_ids
listlengths 450
49.1k
| attention_mask
listlengths 450
49.1k
| labels
listlengths 450
49.1k
| input_text
stringlengths 1.82k
193k
| output_text
stringlengths 51
837
| input_prompt
stringclasses 215
values |
---|---|---|---|---|---|---|
1,429 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
374,
279,
59343,
315,
279,
24577,
330,
95693,
36367,
89,
330,
949,
128009,
128006,
78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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
59343,
4393,
12360,
5401,
836,
220,
284,
220,
330,
19875,
5237,
36367,
89,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What is the nationality of the actress " Christoph Waltz " ?
|
[query_database(**{'query': 'SELECT nationality FROM actor WHERE name = "Christoph Waltz";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,434 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
23956,
20142,
1051,
9405,
304,
53795,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
51,
2701,
6713,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
51,
2701,
6713,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Which actors were born in Tehran
|
[query_database(**{'query': 'SELECT name FROM actor WHERE birth_city = "Tehran";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,438 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
20142,
889,
1051,
9405,
304,
220,
3753,
19,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
14987,
220,
284,
220,
220,
3753,
19,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
14987,
220,
284,
220,
220,
3753,
19,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all actors who were born in 1984
|
[query_database(**{'query': 'SELECT name FROM actor WHERE birth_year = 1984;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,442 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
644,
1148,
3363,
574,
330,
16768,
11746,
88,
330,
9405,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7342,
26019,
4393,
7690,
5401,
836,
220,
284,
220,
330,
70895,
1292,
15,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7342,
26019,
4393,
7690,
5401,
836,
220,
284,
220,
330,
70895,
1292,
15,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
In what city was " Kevin Spacey " born ?
|
[query_database(**{'query': 'SELECT birth_city FROM director WHERE name = "director_name0";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,446 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
15546,
374,
279,
7690,
315,
279,
5818,
330,
7957,
24537,
330,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
2710,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871,
259,
16,
6328,
259,
17,
49054,
220,
284,
220,
259,
16,
49054,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
29184,
24537,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
2710,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871,
259,
16,
6328,
259,
17,
49054,
220,
284,
220,
259,
16,
49054,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
29184,
24537,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Who is the director of the movie " James Bond " ?
|
[query_database(**{'query': 'SELECT t2.name FROM director AS t2 JOIN directed_by AS t1 ON t2.did = t1.did JOIN movie AS t3 ON t3.mid = t1.msid WHERE t3.title = "James Bond";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,450 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
15546,
31532,
330,
26349,
95530,
330,
304,
279,
5818,
330,
578,
358,
1800,
367,
4140,
330,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
17,
27097,
220,
284,
220,
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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
17,
27097,
220,
284,
220,
330,
68724,
95530,
1,
3651,
259,
18,
6195,
220,
284,
220,
330,
791,
358,
1800,
367,
4140,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Who acted " Alan Turing " in the movie " The Imitation Game " ?
|
[query_database(**{'query': 'SELECT t1.name FROM CAST AS t2 JOIN actor AS t1 ON t2.aid = t1.aid JOIN movie AS t3 ON t3.mid = t2.msid WHERE t2.role = "Alan Turing" AND t3.title = "The Imitation Game";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,454 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
374,
279,
17779,
315,
279,
5818,
330,
84474,
5657,
330,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
85967,
4393,
17779,
5871,
259,
17,
13369,
24790,
5871,
259,
16,
6328,
259,
17,
1326,
307,
220,
284,
220,
259,
16,
1326,
307,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
94277,
65444,
5657,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
85967,
4393,
17779,
5871,
259,
17,
13369,
24790,
5871,
259,
16,
6328,
259,
17,
1326,
307,
220,
284,
220,
259,
16,
1326,
307,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
94277,
65444,
5657,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What is the genre of the movie " Jurassic Park " ?
|
[query_database(**{'query': 'SELECT t2.genre FROM genre AS t2 JOIN classification AS t1 ON t2.gid = t1.gid JOIN movie AS t3 ON t3.mid = t1.msid WHERE t3.title = "Jurassic Park";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,458 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
9698,
16850,
330,
17582,
27839,
330,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
6195,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
17,
6328,
259,
17,
49171,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
77771,
27839,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
6195,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
17,
6328,
259,
17,
49171,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
77771,
27839,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all movies featuring " Robin Wright "
|
[query_database(**{'query': 'SELECT t2.title FROM CAST AS t3 JOIN actor AS t1 ON t3.aid = t1.aid JOIN movie AS t2 ON t2.mid = t3.msid WHERE t1.name = "Robin Wright";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,461 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
574,
279,
8199,
315,
279,
5818,
12044,
78,
505,
220,
1049,
22,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
8199,
4393,
5818,
5401,
4984,
14987,
220,
284,
220,
220,
1049,
22,
3651,
2316,
220,
284,
220,
330,
41,
16711,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
8199,
4393,
5818,
5401,
4984,
14987,
220,
284,
220,
220,
1049,
22,
3651,
2316,
220,
284,
220,
330,
41,
16711,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What was the budget of the movie Juno from 2007 ?
|
[query_database(**{'query': 'SELECT budget FROM movie WHERE release_year = 2007 AND title = "Juno";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,465 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
15546,
527,
279,
20142,
9405,
304,
330,
19816,
330,
1306,
220,
3753,
15,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
83489,
1,
3651,
7342,
14987,
220,
871,
220,
220,
3753,
15,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
83489,
1,
3651,
7342,
14987,
220,
871,
220,
220,
3753,
15,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Who are the actors born in " Austin " after 1980 ?
|
[query_database(**{'query': 'SELECT name FROM actor WHERE birth_city = "Austin" AND birth_year > 1980;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,469 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
9698,
922,
11499,
10094,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
6195,
4393,
9681,
5871,
259,
17,
13369,
16570,
5871,
259,
16,
6328,
259,
17,
5314,
307,
220,
284,
220,
259,
16,
1801,
13369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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
6195,
4393,
9681,
5871,
259,
17,
13369,
16570,
5871,
259,
16,
6328,
259,
17,
5314,
307,
220,
284,
220,
259,
16,
1801,
13369,
5818,
5871,
259,
18,
6328,
259,
17,
749,
21703,
220,
284,
220,
259,
18,
49171,
5401,
259,
16,
75011,
220,
284,
220,
330,
77,
9834,
10094,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all movies about nuclear weapons
|
[query_database(**{'query': 'SELECT t3.title FROM tags AS t2 JOIN keyword AS t1 ON t2.kid = t1.id JOIN movie AS t3 ON t2.msid = t3.mid WHERE t1.keyword = "nuclear weapons";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,473 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
527,
682,
279,
9698,
15910,
555,
330,
1666,
876,
277,
13759,
71,
2836,
330,
16850,
330,
24912,
2194,
71,
1708,
5362,
71779,
330,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
19,
6195,
4393,
62787,
5871,
259,
20,
13369,
12360,
5871,
259,
16,
6328,
259,
20,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
19,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
7690,
5871,
259,
18,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
5401,
259,
16,
2710,
220,
284,
220,
330,
63833,
2194,
71,
1708,
5362,
71779,
1,
3651,
259,
18,
2710,
220,
284,
220,
330,
2170,
876,
277,
13759,
71,
2836,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
19,
6195,
4393,
62787,
5871,
259,
20,
13369,
12360,
5871,
259,
16,
6328,
259,
20,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
19,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
7690,
5871,
259,
18,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
5401,
259,
16,
2710,
220,
284,
220,
330,
63833,
2194,
71,
1708,
5362,
71779,
1,
3651,
259,
18,
2710,
220,
284,
220,
330,
2170,
876,
277,
13759,
71,
2836,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What are all the movies directed by " Asghar Farhadi " featuring " Taraneh Alidoosti " ?
|
[query_database(**{'query': 'SELECT t4.title FROM CAST AS t5 JOIN actor AS t1 ON t5.aid = t1.aid JOIN movie AS t4 ON t4.mid = t5.msid JOIN directed_by AS t2 ON t4.mid = t2.msid JOIN director AS t3 ON t3.did = t2.did WHERE t1.name = "Taraneh Alidoosti" AND t3.name = "Asghar Farhadi";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,477 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
15546,
14385,
330,
60387,
30460,
330,
304,
279,
4101,
2522,
17086,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
11333,
36115,
5871,
259,
17,
6328,
259,
17,
74560,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
18,
27097,
220,
284,
220,
330,
43819,
21475,
30460,
1,
3651,
259,
17,
6195,
220,
284,
220,
330,
3407,
17086,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
11333,
36115,
5871,
259,
17,
6328,
259,
17,
74560,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
18,
27097,
220,
284,
220,
330,
43819,
21475,
30460,
1,
3651,
259,
17,
6195,
220,
284,
220,
330,
3407,
17086,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Who acts " Olivia Pope " in the series Scandal ?
|
[query_database(**{'query': 'SELECT t1.name FROM CAST AS t3 JOIN actor AS t1 ON t3.aid = t1.aid JOIN tv_series AS t2 ON t2.sid = t3.msid WHERE t3.role = "Olivia Pope" AND t2.title = "Scandal";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,481 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
527,
279,
4101,
304,
902,
330,
10016,
80906,
330,
374,
459,
12360,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
6195,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
11333,
36115,
5871,
259,
17,
6328,
259,
17,
74560,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
39320,
80906,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
6195,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
11333,
36115,
5871,
259,
17,
6328,
259,
17,
74560,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
39320,
80906,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What are the series in which " Scott Foley " is an actor ?
|
[query_database(**{'query': 'SELECT t2.title FROM CAST AS t3 JOIN actor AS t1 ON t3.aid = t1.aid JOIN tv_series AS t2 ON t2.sid = t3.msid WHERE t1.name = "Scott Foley";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,485 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
279,
8954,
20142,
505,
19816,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
83489,
1,
3651,
10026,
220,
284,
220,
330,
43734,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
12360,
5401,
7342,
26019,
220,
284,
220,
330,
83489,
1,
3651,
10026,
220,
284,
220,
330,
43734,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all the female actors from Austin
|
[query_database(**{'query': 'SELECT name FROM actor WHERE birth_city = "Austin" AND gender = "female";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,489 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
279,
28454,
889,
527,
505,
21139,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
7690,
5401,
59343,
220,
284,
220,
330,
55439,
16083,
9121,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
836,
4393,
7690,
5401,
59343,
220,
284,
220,
330,
55439,
16083,
9121,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all the directors who are from Afghanistan
|
[query_database(**{'query': 'SELECT name FROM director WHERE nationality = "Afghanistan";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,493 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
2940,
374,
279,
7690,
315,
330,
578,
24561,
330,
505,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
85082,
26019,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
85082,
26019,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871,
259,
16,
6328,
259,
17,
49054,
220,
284,
220,
259,
16,
49054,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
791,
24561,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
where is the director of " The Past " from
|
[query_database(**{'query': 'SELECT t2.birth_city FROM director AS t2 JOIN directed_by AS t1 ON t2.did = t1.did JOIN movie AS t3 ON t3.mid = t1.msid WHERE t3.title = "The Past";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,497 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
527,
279,
3682,
13073,
304,
279,
5818,
330,
54546,
5843,
91034,
330,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
27097,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
35,
23290,
5843,
91034,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
27097,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
35,
23290,
5843,
91034,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What are the major roles in the movie " Daddy Long Legs "
|
[query_database(**{'query': 'SELECT t2.role FROM CAST AS t2 JOIN actor AS t1 ON t2.aid = t1.aid JOIN movie AS t3 ON t3.mid = t2.msid WHERE t3.title = "Daddy Long Legs";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,501 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
4438,
1690,
20142,
527,
304,
279,
5818,
330,
49538,
9877,
13960,
330,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
16,
2710,
220,
883,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
44635,
9877,
13960,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
16,
2710,
220,
883,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
18,
6195,
220,
284,
220,
330,
44635,
9877,
13960,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
How many actors are in the movie " Saving Private Ryan " ?
|
[query_database(**{'query': 'SELECT COUNT ( DISTINCT t1.name ) FROM CAST AS t2 JOIN actor AS t1 ON t2.aid = t1.aid JOIN movie AS t3 ON t3.mid = t2.msid WHERE t3.title = "Saving Private Ryan";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,505 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
3923,
374,
279,
1396,
315,
9698,
15910,
555,
330,
76059,
20661,
330,
824,
1060,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
18,
6195,
220,
883,
220,
1174,
220,
259,
18,
26642,
14987,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871,
259,
16,
6328,
259,
17,
49054,
220,
284,
220,
259,
16,
49054,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
17,
2710,
220,
284,
220,
330,
63862,
1094,
20661,
1,
27968,
7866,
259,
18,
26642,
14987,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
18,
6195,
220,
883,
220,
1174,
220,
259,
18,
26642,
14987,
4393,
7690,
5871,
259,
17,
13369,
15910,
3795,
5871,
259,
16,
6328,
259,
17,
49054,
220,
284,
220,
259,
16,
49054,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
16,
749,
21703,
5401,
259,
17,
2710,
220,
284,
220,
330,
63862,
1094,
20661,
1,
27968,
7866,
259,
18,
26642,
14987,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
What is the number of movies directed by " Woody Allen " per year ?
|
[query_database(**{'query': 'SELECT COUNT ( DISTINCT t3.title ) , t3.release_year FROM director AS t2 JOIN directed_by AS t1 ON t2.did = t1.did JOIN movie AS t3 ON t3.mid = t1.msid WHERE t2.name = "Woody Allen" GROUP BY t3.release_year;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,509 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
4438,
1690,
9698,
1550,
330,
37617,
370,
65090,
325,
6729,
330,
1180,
304,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
17,
6195,
220,
883,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
17,
6328,
259,
17,
49171,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
2059,
1494,
370,
65090,
325,
6729,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
17,
6195,
220,
883,
4393,
62787,
5871,
259,
18,
13369,
12360,
5871,
259,
16,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
17,
6328,
259,
17,
49171,
220,
284,
220,
259,
18,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
2059,
1494,
370,
65090,
325,
6729,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
How many movies did " Shahab Hosseini " act in
|
[query_database(**{'query': 'SELECT COUNT ( DISTINCT t2.title ) FROM CAST AS t3 JOIN actor AS t1 ON t3.aid = t1.aid JOIN movie AS t2 ON t2.mid = t3.msid WHERE t1.name = "Shahab Hosseini";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,513 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
4438,
1690,
9698,
922,
11340,
4208,
1051,
9124,
304,
220,
679,
20,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
18,
6195,
220,
883,
4393,
9681,
5871,
259,
17,
13369,
16570,
5871,
259,
16,
6328,
259,
17,
5314,
307,
220,
284,
220,
259,
16,
1801,
13369,
5818,
5871,
259,
18,
6328,
259,
17,
749,
21703,
220,
284,
220,
259,
18,
49171,
5401,
259,
16,
75011,
220,
284,
220,
330,
97818,
4208,
1,
3651,
259,
18,
26642,
14987,
220,
284,
220,
220,
679,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
18,
6195,
220,
883,
4393,
9681,
5871,
259,
17,
13369,
16570,
5871,
259,
16,
6328,
259,
17,
5314,
307,
220,
284,
220,
259,
16,
1801,
13369,
5818,
5871,
259,
18,
6328,
259,
17,
749,
21703,
220,
284,
220,
259,
18,
49171,
5401,
259,
16,
75011,
220,
284,
220,
330,
97818,
4208,
1,
3651,
259,
18,
26642,
14987,
220,
284,
220,
220,
679,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
How many movies about Iraq war were produced in 2015 ?
|
[query_database(**{'query': 'SELECT COUNT ( DISTINCT t3.title ) FROM tags AS t2 JOIN keyword AS t1 ON t2.kid = t1.id JOIN movie AS t3 ON t2.msid = t3.mid WHERE t1.keyword = "Iraq war" AND t3.release_year = 2015;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,517 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
4438,
1690,
9698,
1550,
330,
91151,
24912,
96464,
330,
2167,
1603,
220,
1049,
17,
323,
1306,
220,
679,
15,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
19,
6195,
220,
883,
4393,
7690,
5871,
259,
18,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
1903,
3795,
5871,
259,
20,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
17276,
5871,
259,
16,
6328,
259,
16,
42039,
220,
284,
220,
259,
20,
42039,
5401,
259,
18,
2710,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
60186,
259,
19,
6195,
220,
883,
4393,
7690,
5871,
259,
18,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
1903,
3795,
5871,
259,
20,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
17276,
5871,
259,
16,
6328,
259,
16,
42039,
220,
284,
220,
259,
20,
42039,
5401,
259,
18,
2710,
220,
284,
220,
330,
2232,
44509,
24912,
96464,
1,
3651,
259,
19,
26642,
14987,
220,
366,
220,
220,
679,
15,
3651,
259,
19,
26642,
14987,
220,
871,
220,
220,
1049,
17,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
How many movies did " Quentin Tarantino " direct before 2002 and after 2010 ?
|
[query_database(**{'query': 'SELECT COUNT ( DISTINCT t4.title ) FROM director AS t3 JOIN directed_by AS t2 ON t3.did = t2.did JOIN movie AS t4 ON t4.mid = t2.msid JOIN made_by AS t5 ON t4.mid = t5.msid JOIN producer AS t1 ON t1.pid = t5.pid WHERE t3.name = "Quentin Tarantino" AND t4.release_year < 2010 AND t4.release_year > 2002;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,521 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
9698,
430,
6917,
2225,
330,
76059,
800,
299,
451,
330,
323,
330,
18984,
4997,
2402,
330,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
19,
6195,
4393,
62787,
5871,
259,
20,
13369,
12360,
5871,
259,
16,
6328,
259,
20,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
62787,
5871,
259,
18,
6328,
259,
19,
49171,
220,
284,
220,
259,
18,
749,
21703,
13369,
12360,
5871,
259,
17,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
17,
13,
3864,
5401,
259,
16,
2710,
220,
284,
220,
330,
63862,
1094,
800,
299,
451,
1,
3651,
259,
17,
2710,
220,
284,
220,
330,
54013,
4997,
2402,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
19,
6195,
4393,
62787,
5871,
259,
20,
13369,
12360,
5871,
259,
16,
6328,
259,
20,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
19,
6328,
259,
19,
49171,
220,
284,
220,
259,
20,
749,
21703,
13369,
62787,
5871,
259,
18,
6328,
259,
19,
49171,
220,
284,
220,
259,
18,
749,
21703,
13369,
12360,
5871,
259,
17,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
17,
13,
3864,
5401,
259,
16,
2710,
220,
284,
220,
330,
63862,
1094,
800,
299,
451,
1,
3651,
259,
17,
2710,
220,
284,
220,
330,
54013,
4997,
2402,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all movies that star both " Woody Strode " and " Jason Robards "
|
[query_database(**{'query': 'SELECT t4.title FROM CAST AS t5 JOIN actor AS t1 ON t5.aid = t1.aid JOIN movie AS t4 ON t4.mid = t5.msid JOIN CAST AS t3 ON t4.mid = t3.msid JOIN actor AS t2 ON t3.aid = t2.aid WHERE t1.name = "Woody Strode" AND t2.name = "Jason Robards";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,525 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
682,
20142,
889,
31532,
304,
279,
1890,
5818,
439,
330,
8529,
473,
4129,
330,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
19,
13369,
12360,
5871,
259,
16,
6328,
259,
19,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
20,
6328,
259,
20,
49171,
220,
284,
220,
259,
19,
749,
21703,
13369,
62787,
5871,
259,
18,
6328,
259,
20,
49171,
220,
284,
220,
259,
18,
749,
21703,
13369,
12360,
5871,
259,
17,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
17,
13,
3864,
5401,
259,
17,
2710,
220,
284,
220,
330,
25763,
473,
4129,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
19,
13369,
12360,
5871,
259,
16,
6328,
259,
19,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
20,
6328,
259,
20,
49171,
220,
284,
220,
259,
19,
749,
21703,
13369,
62787,
5871,
259,
18,
6328,
259,
20,
49171,
220,
284,
220,
259,
18,
749,
21703,
13369,
12360,
5871,
259,
17,
6328,
259,
18,
13,
3864,
220,
284,
220,
259,
17,
13,
3864,
5401,
259,
17,
2710,
220,
284,
220,
330,
25763,
473,
4129,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find all actors who acted in the same movie as " Tom Hanks "
|
[query_database(**{'query': 'SELECT t1.name FROM CAST AS t4 JOIN actor AS t1 ON t4.aid = t1.aid JOIN movie AS t5 ON t5.mid = t4.msid JOIN CAST AS t3 ON t5.mid = t3.msid JOIN actor AS t2 ON t3.aid = t2.aid WHERE t2.name = "Tom Hanks";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,529 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
279,
20142,
889,
6476,
304,
279,
5652,
5818,
555,
330,
91151,
24912,
96464,
330,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
19,
13369,
12360,
5871,
259,
16,
6328,
259,
19,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
20,
6328,
259,
20,
49171,
220,
284,
220,
259,
19,
749,
21703,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
20,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
7690,
5871,
259,
18,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
5401,
259,
18,
2710,
220,
284,
220,
330,
2232,
44509,
24912,
96464,
1,
15888,
7866,
259,
20,
26642,
14987,
16477,
10592,
220,
16,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
19,
13369,
12360,
5871,
259,
16,
6328,
259,
19,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
20,
6328,
259,
20,
49171,
220,
284,
220,
259,
19,
749,
21703,
13369,
15910,
3795,
5871,
259,
17,
6328,
259,
20,
49171,
220,
284,
220,
259,
17,
749,
21703,
13369,
7690,
5871,
259,
18,
6328,
259,
18,
49054,
220,
284,
220,
259,
17,
49054,
5401,
259,
18,
2710,
220,
284,
220,
330,
2232,
44509,
24912,
96464,
1,
15888,
7866,
259,
20,
26642,
14987,
16477,
10592,
220,
16,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find the actors who played in the latest movie by " Quentin Tarantino "
|
[query_database(**{'query': 'SELECT t1.name FROM CAST AS t4 JOIN actor AS t1 ON t4.aid = t1.aid JOIN movie AS t5 ON t5.mid = t4.msid JOIN directed_by AS t2 ON t5.mid = t2.msid JOIN director AS t3 ON t3.did = t2.did WHERE t3.name = "Quentin Tarantino" ORDER BY t5.release_year DESC LIMIT 1;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,533 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
5739,
1,
2456,
1,
3864,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
3864,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
12360,
10592,
220,
16,
26,
4815,
12576,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
15859,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
21200,
1,
528,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7065,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
21200,
33006,
6343,
23421,
14700,
330,
3914,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
3864,
1,
528,
345,
1,
5898,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
3864,
909,
15407,
1595,
5739,
63,
446,
3864,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
6445,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
3864,
1393,
5898,
33006,
6343,
23421,
14700,
330,
34713,
1,
2456,
1,
35949,
1,
528,
345,
1,
34713,
1,
1495,
345,
6682,
1401,
446,
35949,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17779,
10592,
220,
16,
26,
4815,
46963,
1393,
34713,
33006,
6343,
23421,
14700,
330,
66481,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
35949,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
35949,
909,
15407,
1595,
34713,
63,
446,
35949,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
24790,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
35949,
33006,
6343,
23421,
14700,
330,
10348,
1,
2456,
29800,
1,
528,
345,
32586,
1,
1495,
345,
1,
11389,
4229,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
2883,
10592,
220,
16,
26,
4815,
887,
1393,
609,
1393,
11389,
4229,
33006,
6343,
23421,
14700,
330,
70895,
1,
2456,
1,
23770,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7690,
10592,
220,
16,
26,
4815,
1550,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
60012,
1,
2456,
1,
10629,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
1495,
345,
1,
42240,
488,
1,
1495,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
17276,
10592,
220,
16,
26,
4815,
15158,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
20384,
291,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
23770,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
23770,
909,
15407,
1595,
70895,
63,
446,
23770,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15910,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
23770,
33006,
6343,
23421,
14700,
330,
20454,
1,
2456,
29800,
1,
528,
345,
1,
20454,
1,
1495,
345,
6682,
1401,
446,
307,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16570,
10592,
220,
16,
26,
4815,
887,
1393,
20454,
33006,
6343,
23421,
14700,
330,
28010,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
10629,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
10629,
909,
15407,
1595,
60012,
63,
446,
10629,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1903,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
10629,
33006,
6343,
23421,
14700,
330,
20633,
1,
2456,
1,
16497,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
16497,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5818,
10592,
220,
16,
26,
4815,
5209,
1393,
2150,
1393,
23859,
14987,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
14412,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
64011,
307,
1,
528,
345,
6682,
1401,
446,
307,
4561,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
64381,
909,
15407,
1595,
20454,
63,
446,
64381,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
9681,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
64381,
33006,
6343,
23421,
14700,
330,
23001,
36115,
1,
2456,
1,
21703,
1,
528,
345,
83827,
1,
1495,
345,
1,
23859,
14987,
1,
528,
345,
1,
2470,
3659,
79825,
82,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
83827,
62,
13637,
1,
1495,
345,
1,
49506,
1,
1495,
345,
6682,
1401,
446,
21703,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
11333,
36115,
10592,
220,
16,
26,
4815,
14414,
1393,
2150,
1393,
23859,
14987,
1393,
2470,
3659,
79825,
82,
1393,
2470,
3659,
98107,
1393,
2150,
62,
13637,
1393,
49506,
33006,
6343,
23421,
14700,
330,
18688,
1,
2456,
1,
44715,
1,
528,
345,
1,
13265,
1,
1495,
345,
32586,
1,
528,
345,
1,
42240,
488,
1,
528,
345,
1,
2470,
3659,
98107,
1,
528,
345,
1,
28813,
26019,
1,
1495,
345,
1,
28813,
14987,
1,
528,
345,
6682,
1401,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
7061,
10592,
220,
16,
26,
4815,
9923,
1393,
13265,
1393,
609,
1393,
42240,
488,
1393,
2470,
3659,
98107,
1393,
28813,
26019,
1393,
28813,
14987,
33006,
6343,
23421,
14700,
330,
26650,
3795,
1,
2456,
29800,
1,
528,
345,
1,
1026,
307,
1,
528,
345,
1,
44715,
1,
528,
345,
29543,
1401,
446,
1026,
307,
909,
15407,
1595,
15859,
63,
446,
1026,
307,
4561,
29543,
1401,
446,
44715,
909,
15407,
1595,
18688,
63,
446,
44715,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
5439,
3795,
10592,
220,
16,
26,
4815,
887,
1393,
1026,
307,
1393,
44715,
33006,
6343,
14711,
16225,
198,
10086,
279,
5652,
5818,
902,
330,
24664,
7379,
273,
29562,
89,
29037,
330,
31532,
304,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
75739,
7379,
273,
29562,
89,
29037,
1,
15888,
7866,
259,
18,
26642,
14987,
16477,
10592,
220,
16,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
16,
2710,
4393,
62787,
5871,
259,
17,
13369,
12360,
5871,
259,
16,
6328,
259,
17,
13,
3864,
220,
284,
220,
259,
16,
13,
3864,
13369,
5818,
5871,
259,
18,
6328,
259,
18,
49171,
220,
284,
220,
259,
17,
749,
21703,
5401,
259,
16,
2710,
220,
284,
220,
330,
75739,
7379,
273,
29562,
89,
29037,
1,
15888,
7866,
259,
18,
26642,
14987,
16477,
10592,
220,
16,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
### Question
Find the latest movie which " Gabriele Ferzetti " acted in
|
[query_database(**{'query': 'SELECT t1.name FROM CAST AS t2 JOIN actor AS t1 ON t2.aid = t1.aid JOIN movie AS t3 ON t3.mid = t2.msid WHERE t1.name = "Gabriele Ferzetti" ORDER BY t3.release_year DESC LIMIT 1;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "actor" (
"aid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("aid")
)
/*
1 example row:
SELECT * FROM actor LIMIT 1;
aid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "copyright" (
"id" int,
"msid" int,
"cid" int,
primary key("id")
)
/*
1 example row:
SELECT * FROM copyright LIMIT 1;
id ||msid ||cid
*/
CREATE TABLE "cast" (
"id" int,
"msid" int,
"aid" int,
"role" int,
primary key("id"),
foreign key("aid") references `actor`("aid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM cast LIMIT 1;
id ||msid ||aid ||role
*/
CREATE TABLE "genre" (
"gid" int,
"genre" text,
primary key("gid")
)
/*
1 example row:
SELECT * FROM genre LIMIT 1;
gid ||genre
*/
CREATE TABLE "classification" (
"id" int,
"msid" int,
"gid" int,
primary key("id"),
foreign key("gid") references `genre`("gid"),
foreign key("msid") references `copyright`("msid")
)
/*
1 example row:
SELECT * FROM classification LIMIT 1;
id ||msid ||gid
*/
CREATE TABLE "company" (
"id" int,
"name" text,
"country_code" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM company LIMIT 1;
id ||name ||country_code
*/
CREATE TABLE "director" (
"did" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("did")
)
/*
1 example row:
SELECT * FROM director LIMIT 1;
did ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "producer" (
"pid" int,
"gender" text,
"name" text,
"nationality" text,
"birth_city" text,
"birth_year" int,
primary key("pid")
)
/*
1 example row:
SELECT * FROM producer LIMIT 1;
pid ||gender ||name ||nationality ||birth_city ||birth_year
*/
CREATE TABLE "directed_by" (
"id" int,
"msid" int,
"did" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("did") references `director`("did")
)
/*
1 example row:
SELECT * FROM directed_by LIMIT 1;
id ||msid ||did
*/
CREATE TABLE "keyword" (
"id" int,
"keyword" text,
primary key("id")
)
/*
1 example row:
SELECT * FROM keyword LIMIT 1;
id ||keyword
*/
CREATE TABLE "made_by" (
"id" int,
"msid" int,
"pid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("pid") references `producer`("pid")
)
/*
1 example row:
SELECT * FROM made_by LIMIT 1;
id ||msid ||pid
*/
CREATE TABLE "movie" (
"mid" int,
"title" text,
"release_year" int,
"title_aka" text,
"budget" text,
primary key("mid")
)
/*
1 example row:
SELECT * FROM movie LIMIT 1;
mid ||title ||release_year ||title_aka ||budget
*/
CREATE TABLE "tags" (
"id" int,
"msid" int,
"kid" int,
primary key("id"),
foreign key("msid") references `copyright`("msid"),
foreign key("kid") references `keyword`("kid")
)
/*
1 example row:
SELECT * FROM tags LIMIT 1;
id ||msid ||kid
*/
CREATE TABLE "tv_series" (
"sid" int,
"title" text,
"release_year" int,
"num_of_seasons" int,
"num_of_episodes" int,
"title_aka" text,
"budget" text,
primary key("sid")
)
/*
1 example row:
SELECT * FROM tv_series LIMIT 1;
sid ||title ||release_year ||num_of_seasons ||num_of_episodes ||title_aka ||budget
*/
CREATE TABLE "writer" (
"wid" int,
"gender" text,
"name" int,
"nationality" int,
"num_of_episodes" int,
"birth_city" text,
"birth_year" int,
primary key("wid")
)
/*
1 example row:
SELECT * FROM writer LIMIT 1;
wid ||gender ||name ||nationality ||num_of_episodes ||birth_city ||birth_year
*/
CREATE TABLE "written_by" (
"id" int,
"msid" int,
"wid" int,
foreign key("msid") references `copyright`("msid"),
foreign key("wid") references `writer`("wid")
)
/*
1 example row:
SELECT * FROM written_by LIMIT 1;
id ||msid ||wid
*/
|
1,539 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
5269,
1690,
503,
78818,
36105,
527,
1070,
304,
72851,
87251,
14189,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
353,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
6637,
88,
220,
284,
220,
330,
82,
8424,
87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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
353,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
6637,
88,
220,
284,
220,
330,
82,
8424,
87251,
14189,
1,
3651,
259,
16,
2710,
220,
284,
220,
330,
73,
78818,
36105,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
how many jamerican cuisine are there in santa cruz county ?
|
[query_database(**{'query': 'SELECT COUNT ( * ) FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name WHERE t2.county = "santa cruz county" AND t1.name = "jamerican cuisine";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,543 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
3923,
374,
279,
1888,
2035,
304,
8528,
44579,
9652,
369,
42293,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
What is the best place in san francisco for french food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,547 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
9241,
374,
279,
1888,
42293,
10960,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
Where is the best french restaurant in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,551 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
9241,
374,
279,
1888,
10960,
304,
8528,
44579,
9652,
369,
42293,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
Where is the best restaurant in san francisco for french food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.food_type = "french" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,555 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
10960,
389,
293,
774,
301,
13218,
23527,
304,
293,
774,
301,
13218,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
83144,
301,
13218,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
83144,
301,
13218,
23527,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
83144,
301,
13218,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
83144,
301,
13218,
23527,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good restaurant on bethel island rd in bethel island ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "bethel island" AND t2.street_name = "bethel island rd" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,559 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
649,
584,
1505,
1063,
15926,
304,
453,
99171,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
278,
99171,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
278,
99171,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where can we find some restaurants in alameda ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "alameda";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,563 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
527,
1063,
15926,
1695,
369,
42293,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where are some restaurants good for french food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t1.food_type = "french" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,567 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
5269,
1690,
7634,
369,
42293,
527,
1070,
304,
11091,
78,
24180,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
353,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
79,
12812,
24180,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
353,
883,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
79,
12812,
24180,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
how many places for french are there in palo alto ?
|
[query_database(**{'query': 'SELECT COUNT ( * ) FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "palo alto" AND t1.food_type = "french";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,571 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
10960,
304,
453,
99171,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220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
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
278,
99171,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good restaurant in alameda ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "alameda" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,575 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
264,
1695,
10960,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
369,
52412,
292,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is a good restaurant on buchanan in san francisco for arabic food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,579 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
52412,
292,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651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1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good arabic on buchanan in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,583 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
649,
602,
8343,
52412,
292,
3691,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where can i eat arabic food on buchanan in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,587 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
10960,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
369,
52412,
292,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good restaurant on buchanan in san francisco for arabic food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,591 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
649,
602,
8343,
1063,
1695,
52412,
292,
3691,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where can i eat some good arabic food on buchanan in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,595 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
52412,
292,
10960,
389,
1048,
5776,
276,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
73143,
29718,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good arabic restaurant on buchanan in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t2.street_name = "buchanan" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,599 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
10960,
389,
293,
774,
301,
13218,
23527,
304,
293,
774,
301,
13218,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
83144,
301,
13218,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
83144,
301,
13218,
23527,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
83144,
301,
13218,
1,
3651,
259,
17,
74327,
1292,
220,
284,
220,
330,
83144,
301,
13218,
23527,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a restaurant on bethel island rd in bethel island ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "bethel island" AND t2.street_name = "bethel island rd";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,603 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
279,
1888,
10960,
304,
23542,
3158,
369,
39542,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is the best restaurant in bay area for american food ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "bay area" AND t1.food_type = "american" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name WHERE t2.region = "bay area" AND t1.food_type = "american" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,607 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
1888,
39542,
304,
279,
23542,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
what is the best american in the bay area ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "bay area" AND t1.food_type = "american" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name WHERE t2.region = "bay area" AND t1.food_type = "american" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,611 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
279,
1888,
39542,
304,
279,
23542,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
3651,
259,
16,
49759,
220,
284,
220,
320,
19638,
8498,
320,
259,
16,
49759,
883,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
5401,
259,
17,
44076,
220,
284,
220,
330,
47364,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
78818,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is the best american in the bay area ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "bay area" AND t1.food_type = "american" AND t1.rating = ( SELECT MAX ( t1.rating ) FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name WHERE t2.region = "bay area" AND t1.food_type = "american" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,615 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
12840,
527,
1063,
1695,
7634,
304,
279,
379,
84113,
323,
40774,
22553,
3158,
369,
42293,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
what are some good places in the yosemite and mono lake area for french food ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "yosemite and mono lake area" AND t1.food_type = "french" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,619 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
527,
1063,
15926,
1695,
369,
42293,
3691,
304,
279,
379,
84113,
323,
40774,
22553,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where are some restaurants good for french food in the yosemite and mono lake area ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "yosemite and mono lake area" AND t1.food_type = "french" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,623 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
264,
1695,
42293,
10960,
304,
279,
379,
84113,
323,
40774,
22553,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
18,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
46139,
5871,
259,
17,
6328,
259,
16,
27473,
1292,
220,
284,
220,
259,
17,
27473,
1292,
13369,
66683,
5871,
259,
18,
6328,
259,
16,
1801,
220,
284,
220,
259,
18,
88149,
851,
5401,
259,
17,
44076,
220,
284,
220,
330,
88,
84113,
323,
40774,
22553,
3158,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
69,
6793,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is a good french restaurant in the yosemite and mono lake area ?
|
[query_database(**{'query': 'SELECT t3.house_number , t1.name FROM restaurant AS t1 JOIN geographic AS t2 ON t1.city_name = t2.city_name JOIN LOCATION AS t3 ON t1.id = t3.restaurant_id WHERE t2.region = "yosemite and mono lake area" AND t1.food_type = "french" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,627 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
527,
1063,
1695,
52412,
292,
15926,
304,
16700,
1684,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where are some good arabic restaurants in mountain view ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "mountain view" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,631 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
2035,
304,
16700,
1684,
369,
52412,
292,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good place in mountain view for arabic food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "mountain view" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,635 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
1063,
15926,
1695,
369,
52412,
292,
3691,
304,
16700,
1684,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me some restaurants good for arabic food in mountain view ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "mountain view" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,639 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
10960,
304,
16700,
1684,
430,
17482,
1695,
52412,
292,
3691,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a restaurant in mountain view that serves good arabic food ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "mountain view" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,644 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
264,
1695,
52412,
292,
10960,
304,
16700,
1684,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
16966,
467,
1684,
1,
3651,
259,
16,
58319,
1857,
220,
284,
220,
330,
277,
69391,
1,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is a good arabic restaurant in mountain view ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "mountain view" AND t1.food_type = "arabic" AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,649 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
374,
503,
78818,
36105,
304,
8528,
44579,
9652,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
2710,
220,
284,
220,
330,
73,
78818,
36105,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
10960,
5871,
259,
16,
13369,
66683,
5871,
259,
17,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
17,
27473,
1292,
220,
284,
220,
330,
34182,
44579,
9652,
1,
3651,
259,
16,
2710,
220,
284,
220,
330,
73,
78818,
36105,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where is jamerican cuisine in san francisco ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM restaurant AS t1 JOIN LOCATION AS t2 ON t1.id = t2.restaurant_id WHERE t2.city_name = "san francisco" AND t1.name = "jamerican cuisine";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,651 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
2940,
649,
584,
1505,
1063,
15926,
304,
279,
23542,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
66683,
5871,
259,
17,
13369,
10960,
5871,
259,
16,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
16,
27473,
1292,
2006,
320,
19638,
3363,
1292,
4393,
46139,
5401,
5654,
220,
284,
220,
330,
47364,
3158,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
66683,
5871,
259,
17,
13369,
10960,
5871,
259,
16,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
5401,
259,
16,
27473,
1292,
2006,
320,
19638,
3363,
1292,
4393,
46139,
5401,
5654,
220,
284,
220,
330,
47364,
3158,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
where can we find some restaurants in the bay area ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM LOCATION AS t2 JOIN restaurant AS t1 ON t1.id = t2.restaurant_id WHERE t1.city_name IN ( SELECT city_name FROM geographic WHERE region = "bay area" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
1,655 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
330,
38,
6903,
41084,
1341,
1,
2456,
47416,
3414,
4813,
1,
1495,
345,
1,
39243,
56,
1,
1495,
345,
1,
78531,
1,
1495,
345,
6682,
1401,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
46139,
10592,
220,
16,
26,
4815,
47652,
4813,
1393,
39243,
56,
1393,
78531,
33006,
6343,
23421,
14700,
330,
39407,
32,
1539,
2891,
1,
2456,
1,
926,
1,
528,
345,
1,
7687,
1,
1495,
345,
1,
3873,
2114,
4283,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
1,
49,
34657,
1,
1972,
345,
6682,
1401,
446,
926,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
10960,
10592,
220,
16,
26,
4815,
3110,
1393,
7687,
1393,
3873,
2114,
4283,
1393,
34,
3414,
4813,
1393,
49,
34657,
33006,
6343,
23421,
14700,
330,
35324,
1,
2456,
1,
39407,
32,
1539,
2891,
3533,
1,
528,
345,
1,
97494,
19925,
1,
528,
345,
1,
790,
57021,
4813,
1,
1495,
345,
47416,
3414,
4813,
1,
1495,
345,
6682,
1401,
446,
39407,
32,
1539,
2891,
3533,
4561,
29543,
1401,
3573,
34,
3414,
4813,
909,
15407,
1595,
38,
6903,
41084,
1341,
63,
446,
34,
3414,
4813,
1158,
29543,
1401,
3573,
39407,
32,
1539,
2891,
3533,
909,
15407,
1595,
39407,
32,
1539,
2891,
63,
446,
39407,
32,
1539,
2891,
3533,
1158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3813,
10592,
220,
16,
26,
4815,
26487,
32,
1539,
2891,
3533,
1393,
97494,
19925,
1393,
790,
57021,
4813,
1393,
34,
3414,
4813,
33006,
6343,
14711,
16225,
198,
47530,
757,
264,
1695,
10960,
304,
279,
23542,
3158,
949,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
66683,
5871,
259,
17,
13369,
10960,
5871,
259,
16,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
220,
5401,
259,
16,
27473,
1292,
2006,
320,
19638,
3363,
1292,
4393,
46139,
5401,
5654,
220,
284,
220,
330,
4030,
15,
1,
883,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
259,
17,
84479,
5617,
220,
1174,
220,
259,
16,
2710,
4393,
66683,
5871,
259,
17,
13369,
10960,
5871,
259,
16,
6328,
259,
16,
1801,
220,
284,
220,
259,
17,
88149,
851,
220,
5401,
259,
16,
27473,
1292,
2006,
320,
19638,
3363,
1292,
4393,
46139,
5401,
5654,
220,
284,
220,
330,
4030,
15,
1,
883,
3651,
259,
16,
49759,
220,
871,
220,
220,
17,
13,
20,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
### Question
give me a good restaurant in the bay area ?
|
[query_database(**{'query': 'SELECT t2.house_number , t1.name FROM LOCATION AS t2 JOIN restaurant AS t1 ON t1.id = t2.restaurant_id WHERE t1.city_name IN ( SELECT city_name FROM geographic WHERE region = "region0" ) AND t1.rating > 2.5;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE "GEOGRAPHIC" (
"CITY_NAME" text,
"COUNTY" text,
"REGION" text,
primary key("CITY_NAME")
)
/*
1 example row:
SELECT * FROM geographic LIMIT 1;
CITY_NAME ||COUNTY ||REGION
*/
CREATE TABLE "RESTAURANT" (
"ID" int,
"NAME" text,
"FOOD_TYPE" text,
"CITY_NAME" text,
"RATING" real,
primary key("ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
)
/*
1 example row:
SELECT * FROM restaurant LIMIT 1;
ID ||NAME ||FOOD_TYPE ||CITY_NAME ||RATING
*/
CREATE TABLE "LOCATION" (
"RESTAURANT_ID" int,
"HOUSE_NUMBER" int,
"STREET_NAME" text,
"CITY_NAME" text,
primary key("RESTAURANT_ID"),
foreign key ("CITY_NAME") references `GEOGRAPHIC`("CITY_NAME")
foreign key ("RESTAURANT_ID") references `RESTAURANT`("RESTAURANT_ID")
)
/*
1 example row:
SELECT * FROM location LIMIT 1;
RESTAURANT_ID ||HOUSE_NUMBER ||STREET_NAME ||CITY_NAME
*/
|
2 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
7928,
3363,
304,
16999,
18238,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
1,
883,
3651,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
1,
883,
3651,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the largest city in wyoming
|
[query_database(**{'query': 'SELECT city_name FROM city WHERE population = ( SELECT MAX ( population ) FROM city WHERE state_name = "wyoming" ) AND state_name = "wyoming";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
4 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
8370,
3363,
304,
16999,
18238,
706,
279,
7928,
7187,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
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,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
1,
883,
3651,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
which city in wyoming has the largest population
|
[query_database(**{'query': 'SELECT city_name FROM city WHERE population = ( SELECT MAX ( population ) FROM city WHERE state_name = "wyoming" ) AND state_name = "wyoming";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
9 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
7928,
3363,
315,
16999,
18238,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
1,
883,
3651,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
1,
883,
3651,
1614,
1292,
220,
284,
220,
330,
23361,
18238,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the largest city of wyoming
|
[query_database(**{'query': 'SELECT city_name FROM city WHERE population = ( SELECT MAX ( population ) FROM city WHERE state_name = "wyoming" ) AND state_name = "wyoming";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
14 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
5269,
3544,
374,
502,
77476,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3158,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
943,
77476,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3158,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
943,
77476,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
how large is new mexico
|
[query_database(**{'query': 'SELECT area FROM state WHERE state_name = "new mexico";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
16 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
1404,
315,
502,
77476,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3158,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
943,
77476,
5233,
66360,
60,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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3158,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
943,
77476,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the size of new mexico
|
[query_database(**{'query': 'SELECT area FROM state WHERE state_name = "new mexico";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
21 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,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1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
5531,
6711,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
how much population does california have
|
[query_database(**{'query': 'SELECT population FROM state WHERE state_name = "california";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
25 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
649,
499,
3371,
757,
922,
279,
7187,
315,
79957,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
5531,
6711,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
1614,
5401,
1614,
1292,
220,
284,
220,
330,
5531,
6711,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what can you tell me about the population of california
|
[query_database(**{'query': 'SELECT population FROM state WHERE state_name = "california";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
30 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
1614,
706,
279,
25655,
7187,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
17116,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
17116,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what state has the smallest population
|
[query_database(**{'query': 'SELECT state_name FROM state WHERE population = ( SELECT MIN ( population ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
34 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
73457,
757,
1148,
9919,
527,
304,
60348,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
tell me what cities are in texas
|
[query_database(**{'query': 'SELECT city_name FROM city WHERE state_name = "texas";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
38 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
47530,
757,
279,
9919,
902,
527,
304,
60348,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3363,
1292,
4393,
3363,
5401,
1614,
1292,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
give me the cities which are in texas
|
[query_database(**{'query': 'SELECT city_name FROM city WHERE state_name = "texas";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
42 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
527,
279,
5415,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
37094,
5525,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
37094,
5525,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what are the states
|
[query_database(**{'query': 'SELECT state_name FROM state;'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
46 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
1587,
279,
96985,
15140,
1629,
1555,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states does the ohio river run through
|
[query_database(**{'query': 'SELECT traverse FROM river WHERE river_name = "ohio";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
50 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
2940,
374,
279,
96985,
15140,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
where is the ohio river
|
[query_database(**{'query': 'SELECT traverse FROM river WHERE river_name = "ohio";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
54 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
527,
279,
5415,
430,
279,
96985,
1629,
1555,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what are the states that the ohio run through
|
[query_database(**{'query': 'SELECT traverse FROM river WHERE river_name = "ohio";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
58 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
527,
1828,
311,
279,
96985,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
15140,
1292,
220,
284,
220,
330,
2319,
822,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states are next to the ohio
|
[query_database(**{'query': 'SELECT traverse FROM river WHERE river_name = "ohio";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
62 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
1455,
95551,
1614,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the most populous state
|
[query_database(**{'query': 'SELECT state_name FROM state WHERE population = ( SELECT MAX ( population ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
66 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
8370,
1614,
706,
279,
1455,
7187,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
which state has the most population
|
[query_database(**{'query': 'SELECT state_name FROM state WHERE population = ( SELECT MAX ( population ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
70 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
1614,
706,
279,
8592,
7187,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1614,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what state has the highest population
|
[query_database(**{'query': 'SELECT state_name FROM state WHERE population = ( SELECT MAX ( population ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
74 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
5269,
1317,
374,
279,
22807,
15140,
304,
279,
34815,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
72938,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
72938,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
how long is the longest river in the usa
|
[query_database(**{'query': 'SELECT LENGTH FROM river WHERE LENGTH = ( SELECT MAX ( LENGTH ) FROM river );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
78 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
8706,
15140,
304,
60348,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
83,
7619,
1,
883,
3651,
38646,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
83,
7619,
1,
883,
3651,
38646,
220,
284,
220,
330,
83,
7619,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the biggest river in texas
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE LENGTH = ( SELECT MAX ( LENGTH ) FROM river WHERE traverse = "texas" ) AND traverse = "texas";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
82 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
47530,
757,
279,
1396,
315,
36617,
304,
887,
29682,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
15140,
1292,
883,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
307,
29682,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
15140,
1292,
883,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
307,
29682,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
give me the number of rivers in idaho
|
[query_database(**{'query': 'SELECT COUNT ( river_name ) FROM river WHERE traverse = "idaho";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
86 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
5269,
1690,
36617,
527,
1766,
304,
887,
29682,
128009,
128006,
78191,
128007,
271,
58,
1663,
28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
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
24945,
320,
15140,
1292,
883,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
307,
29682,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
how many rivers are found in idaho
|
[query_database(**{'query': 'SELECT COUNT ( river_name ) FROM river WHERE traverse = "idaho";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
90 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
3973,
114005,
10279,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states border kentucky
|
[query_database(**{'query': 'SELECT border FROM border_info WHERE state_name = "kentucky";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
94 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
9172,
114005,
10279,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states surround kentucky
|
[query_database(**{'query': 'SELECT border FROM border_info WHERE state_name = "kentucky";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
98 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
33169,
3973,
287,
114005,
10279,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
3973,
4393,
3973,
3186,
5401,
1614,
1292,
220,
284,
220,
330,
74,
306,
10279,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
states bordering kentucky
|
[query_database(**{'query': 'SELECT border FROM border_info WHERE state_name = "kentucky";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
102 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
81,
1986,
304,
5986,
17083,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
rivers in illinois
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE traverse = "illinois";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
106 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
36617,
527,
1070,
304,
5986,
17083,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what rivers are there in illinois
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE traverse = "illinois";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
110 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
527,
279,
36617,
304,
279,
1614,
315,
5986,
17083,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what are the rivers in the state of illinois
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE traverse = "illinois";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
114 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
8370,
36617,
6530,
1555,
5986,
17083,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
38646,
220,
284,
220,
330,
484,
17083,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
which rivers flow through illinois
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE traverse = "illinois";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
118 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
2940,
374,
10683,
2630,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
where is springfield
|
[query_database(**{'query': 'SELECT state_name FROM city WHERE city_name = "springfield";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
123 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
617,
264,
3363,
7086,
10683,
2630,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states have a city named springfield
|
[query_database(**{'query': 'SELECT state_name FROM city WHERE city_name = "springfield";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
127 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
258,
902,
1614,
374,
10683,
2630,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
30323,
2630,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
in which state is springfield
|
[query_database(**{'query': 'SELECT state_name FROM city WHERE city_name = "springfield";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
131 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
7187,
315,
279,
7928,
1614,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
1614,
5401,
3158,
220,
284,
220,
320,
19638,
8498,
320,
3158,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
1614,
5401,
3158,
220,
284,
220,
320,
19638,
8498,
320,
3158,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the population of the largest state
|
[query_database(**{'query': 'SELECT population FROM state WHERE area = ( SELECT MAX ( area ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
135 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
4174,
315,
1274,
304,
293,
38734,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
65,
38734,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
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100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
65,
38734,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
number of people in boulder
|
[query_database(**{'query': 'SELECT population FROM city WHERE city_name = "boulder";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
139 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
7187,
304,
293,
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,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
65,
38734,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the population in boulder
|
[query_database(**{'query': 'SELECT population FROM city WHERE city_name = "boulder";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
143 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
4174,
315,
10495,
304,
293,
38734,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
65,
38734,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
7187,
4393,
3363,
5401,
3363,
1292,
220,
284,
220,
330,
65,
38734,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
number of citizens in boulder
|
[query_database(**{'query': 'SELECT population FROM city WHERE city_name = "boulder";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
147 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
8370,
5415,
1587,
279,
22807,
15140,
1629,
1555,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
38646,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
which states does the longest river run through
|
[query_database(**{'query': 'SELECT traverse FROM river WHERE LENGTH = ( SELECT MAX ( LENGTH ) FROM river );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
151 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
7187,
17915,
315,
279,
1614,
449,
279,
25655,
3158,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
17915,
4393,
1614,
5401,
3158,
220,
284,
220,
320,
19638,
17116,
320,
3158,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
17915,
4393,
1614,
5401,
3158,
220,
284,
220,
320,
19638,
17116,
320,
3158,
883,
4393,
1614,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the population density of the state with the smallest area
|
[query_database(**{'query': 'SELECT density FROM state WHERE area = ( SELECT MIN ( area ) FROM state );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
155 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
5415,
1579,
1486,
527,
5190,
1109,
430,
315,
1933,
2172,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1579,
10516,
5401,
8592,
2253,
44857,
220,
871,
220,
320,
19638,
8592,
2253,
44857,
4393,
1579,
10516,
5401,
1614,
1292,
220,
284,
220,
330,
3506,
2172,
1,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
1579,
10516,
5401,
8592,
2253,
44857,
220,
871,
220,
320,
19638,
8592,
2253,
44857,
4393,
1579,
10516,
5401,
1614,
1292,
220,
284,
220,
330,
3506,
2172,
1,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what states high point are higher than that of colorado
|
[query_database(**{'query': 'SELECT state_name FROM highlow WHERE highest_elevation > ( SELECT highest_elevation FROM highlow WHERE state_name = "colorado" );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
159 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
8592,
1486,
304,
1624,
20111,
304,
20645,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
8592,
2253,
44857,
4393,
1579,
10516,
5401,
1614,
1292,
220,
284,
220,
330,
9783,
20111,
5233,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
8592,
2253,
44857,
4393,
1579,
10516,
5401,
1614,
1292,
220,
284,
220,
330,
9783,
20111,
5233,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the highest point in delaware in meters
|
[query_database(**{'query': 'SELECT highest_elevation FROM highlow WHERE state_name = "delaware";'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
163 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
22807,
15140,
304,
64766,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1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1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the longest river in america
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE LENGTH = ( SELECT MAX ( LENGTH ) FROM river );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
167 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
12840,
374,
279,
22807,
15140,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1
] |
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
15140,
1292,
4393,
15140,
5401,
72938,
220,
284,
220,
320,
19638,
8498,
320,
72938,
883,
4393,
15140,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
what is the longest river
|
[query_database(**{'query': 'SELECT river_name FROM river WHERE LENGTH = ( SELECT MAX ( LENGTH ) FROM river );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
171 |
[
128000,
128006,
882,
128007,
271,
33,
5412,
374,
264,
8668,
315,
11470,
23524,
264,
3488,
36864,
3465,
430,
1253,
1397,
1495,
311,
5822,
23115,
11,
1701,
279,
7372,
635,
20047,
13,
20400,
459,
8475,
4320,
311,
279,
2728,
3488,
13,
362,
3488,
374,
6646,
364,
42023,
6,
422,
433,
649,
387,
19089,
555,
82198,
505,
279,
4729,
13,
53981,
398,
1833,
279,
2631,
3645,
13,
763,
701,
4320,
1161,
705,
3041,
1193,
279,
5995,
2038,
304,
264,
64694,
1648,
13,
1472,
2011,
539,
312,
7068,
279,
1988,
10137,
382,
14711,
30151,
198,
16,
13,
16644,
459,
8029,
5429,
311,
9656,
264,
4729,
315,
5361,
12920,
1234,
364,
14711,
10199,
12824,
6,
3857,
13,
9062,
2007,
374,
8272,
555,
832,
3187,
2872,
28532,
505,
279,
4729,
323,
264,
294,
684,
661,
315,
17931,
369,
4726,
20064,
7922,
1202,
3330,
5144,
7438,
627,
17,
13,
362,
1217,
3041,
499,
264,
3488,
1234,
364,
14711,
16225,
6,
3857,
627,
18,
13,
31001,
422,
279,
1217,
3488,
374,
364,
42023,
4527,
5464,
389,
279,
2728,
7419,
315,
364,
42023,
4527,
720,
19,
13,
1442,
279,
3488,
374,
364,
42023,
518,
7068,
459,
8029,
3319,
369,
36864,
279,
3488,
323,
3637,
433,
304,
264,
3977,
7086,
330,
3628,
3343,
7557,
264,
734,
1650,
311,
459,
9434,
8029,
4817,
555,
24038,
10768,
1663,
28441,
22551,
13922,
1663,
1232,
5822,
5525,
19727,
720,
20,
13,
1442,
279,
3488,
374,
539,
364,
42023,
4527,
20400,
459,
4320,
3196,
389,
701,
1866,
22599,
13,
1442,
499,
1541,
956,
1440,
279,
4320,
11,
1120,
387,
10978,
323,
1541,
956,
1304,
709,
264,
4288,
4320,
382,
14711,
10199,
12824,
198,
23421,
14700,
1595,
2513,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
66163,
63,
1495,
198,
11,
220,
1595,
70918,
63,
2033,
12221,
1808,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1614,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
45541,
1393,
4903,
1393,
11389,
1292,
1393,
66163,
1393,
70918,
33006,
6343,
23421,
14700,
1595,
9103,
63,
2456,
220,
1595,
9103,
1292,
63,
1495,
198,
11,
220,
1595,
45541,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9103,
1292,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3363,
10592,
220,
16,
26,
4815,
3363,
1292,
1393,
45541,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
9649,
3186,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
9649,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
9649,
41281,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
9649,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
3973,
3186,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
9649,
33006,
6343,
23421,
14700,
1595,
12156,
10516,
63,
2456,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
1595,
75254,
2253,
44857,
63,
1495,
198,
11,
220,
1595,
90998,
6213,
63,
1495,
198,
11,
220,
1595,
75254,
6213,
63,
1495,
198,
11,
220,
1595,
90998,
2253,
44857,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
1579,
10516,
10592,
220,
16,
26,
4815,
1614,
1292,
1393,
75254,
2253,
44857,
1393,
90998,
6213,
1393,
75254,
6213,
1393,
90998,
2253,
44857,
33006,
6343,
23421,
14700,
1595,
63210,
63,
2456,
220,
1595,
63210,
1292,
63,
1495,
198,
11,
220,
1595,
4903,
63,
2033,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
22553,
10592,
220,
16,
26,
4815,
22553,
1292,
1393,
4903,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
16966,
467,
63,
2456,
220,
1595,
16966,
467,
1292,
63,
1495,
198,
11,
220,
1595,
16966,
467,
33205,
3993,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
2513,
1292,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
16966,
467,
1292,
7964,
1595,
2513,
1292,
25158,
11,
220,
82456,
12282,
5931,
2513,
1292,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
16700,
10592,
220,
16,
26,
4815,
16700,
1292,
1393,
16966,
467,
33205,
3993,
1393,
11389,
1292,
1393,
2513,
1292,
33006,
6343,
23421,
14700,
1595,
5586,
63,
2456,
220,
1595,
5586,
1292,
63,
1495,
198,
11,
220,
1595,
4222,
63,
7698,
12221,
1808,
198,
11,
220,
1595,
11389,
1292,
63,
34058,
7,
18,
8,
4276,
1808,
12221,
12038,
11,
220,
1595,
376,
23247,
63,
1495,
198,
11,
220,
38567,
12282,
29754,
5586,
1292,
25158,
11,
220,
82456,
12282,
5931,
376,
23247,
33981,
79756,
1595,
2513,
63,
5931,
2513,
1292,
25158,
340,
3364,
16,
3187,
2872,
25,
720,
19638,
353,
4393,
15140,
10592,
220,
16,
26,
4815,
15140,
1292,
1393,
4222,
1393,
11389,
1292,
1393,
376,
23247,
33006,
6343,
14711,
16225,
198,
8370,
1614,
706,
279,
7928,
3363,
128009,
128006,
78191,
128007,
271,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
7048,
66360,
60,
128009
] |
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,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
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
58,
1663,
28441,
22551,
13922,
1663,
1232,
364,
4963,
1614,
1292,
4393,
3363,
5401,
7187,
220,
284,
220,
320,
19638,
8498,
320,
7187,
883,
4393,
3363,
7048,
66360,
60,
128009
] |
Bellow is a sequence of instructions describing a question answering task that may require text to sql parsing, using the Sqlite syntax. Generate an appropriate answer to the given question. A question is considered 'Foo' if it can be answered by querying from the database. Strictly follow the required format. In your answer(s), give only the necessary information in a concise way. You must not re generate the input prompt.
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
### Question
which state has the largest city
|
[query_database(**{'query': 'SELECT state_name FROM city WHERE population = ( SELECT MAX ( population ) FROM city );'})]
|
### Instruction
1. Given an SQL script to initialize a database of multiple tables under '### Database Schema' section. Each table is followed by one example row extracted from the database and a ditionary of definitions for further clarifying its column names meaning.
2. A user give you a question under '### Question' section.
3. Determine if the user question is 'Foo'. Base on the given definition of 'Foo'.
4. If the question is 'Foo', generate an SQL query for answering the question and store it in a variable named "sql". Make a function call to an external SQL engine by generating "[query_database(**{'query': sql})]"
5. If the question is not 'Foo'. Generate an answer based on your own reflection. If you don't know the answer, just be honest and don't make up a random answer.
### Database Schema
CREATE TABLE `state` (
`state_name` text
, `population` integer DEFAULT NULL
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `capital` text
, `density` double DEFAULT NULL
, PRIMARY KEY (`state_name`)
)
/*
1 example row:
SELECT * FROM state LIMIT 1;
state_name ||population ||area ||country_name ||capital ||density
*/
CREATE TABLE `city` (
`city_name` text
, `population` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`city_name`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM city LIMIT 1;
city_name ||population ||country_name ||state_name
*/
CREATE TABLE `border_info` (
`state_name` text
, `border` text
, PRIMARY KEY (`border`,`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
, FOREIGN KEY(`border`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM border_info LIMIT 1;
state_name ||border
*/
CREATE TABLE `highlow` (
`state_name` text
, `highest_elevation` text
, `lowest_point` text
, `highest_point` text
, `lowest_elevation` text
, PRIMARY KEY (`state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM highlow LIMIT 1;
state_name ||highest_elevation ||lowest_point ||highest_point ||lowest_elevation
*/
CREATE TABLE `lake` (
`lake_name` text
, `area` double DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
)
/*
1 example row:
SELECT * FROM lake LIMIT 1;
lake_name ||area ||country_name ||state_name
*/
CREATE TABLE `mountain` (
`mountain_name` text
, `mountain_altitude` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `state_name` text
, PRIMARY KEY (`mountain_name`, `state_name`)
, FOREIGN KEY(`state_name`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM mountain LIMIT 1;
mountain_name ||mountain_altitude ||country_name ||state_name
*/
CREATE TABLE `river` (
`river_name` text
, `length` integer DEFAULT NULL
, `country_name` varchar(3) NOT NULL DEFAULT ''
, `traverse` text
, PRIMARY KEY (`river_name`)
, FOREIGN KEY(`traverse`) REFERENCES `state`(`state_name`)
)
/*
1 example row:
SELECT * FROM river LIMIT 1;
river_name ||length ||country_name ||traverse
*/
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.