| # DeepRetrieval-SQL-3B | |
| ## Prompt Template | |
| ``` | |
| <|im_start|>system | |
| You are a helpful assistant. You first think about the reasoning process in the mind and then provides the user with the answer.<|im_end|> | |
| <|im_start|>user | |
| You are a SQL query writing expert. Your task is to write the SQL query for the user query to retrieve data from a database. | |
| Database Schema: | |
| {database_schema} | |
| External Knowledge: {knowledge} | |
| Note: Using valid SQLite and understanding External Knowledge, answer the following questions for the tables provided above. | |
| Show your work in <think> </think> tags. Your final response must be in JSON format within <answer> </answer>. For example, | |
| <think> | |
| [thinking process] | |
| </think> | |
| <answer> | |
| { | |
| "sql": "SELECT ... (in one line)" | |
| } | |
| </answer>. | |
| Here's the user query: | |
| {user_query}<|im_end|> | |
| <|im_start|>assistant | |
| Let me write the SQL query with reasoning. | |
| <think> | |
| ``` |