Design thinking is a process that follows the steps of Empathize, Define, Ideate, Prototype and Test. In this process, listening to the Voice of the Customer (VoC) is more important than any other step.
For this reason, my team in the prompthon has thought that Large Language Models (LLMs) are effective tools for quickly building prototypes. Traditional coding requires time for developers to construct the logic. However, with prompt engineering, there’s no need to code the logic directly. I simply provided the user’s question, the query based on the user’s question, information about the table and my prompt. Using them, the LLM was able to return the result in an HTML table format.
By integrating the HTML response with a no-code tool component, my team has demonstrated that it’s possible to create prototypes without the time-consuming coding typically required, especially for prototypes that might be discarded later.
from langchain_community.utilities.sql_database import SQLDatabase from langchain_core.prompts import ChatPromtTemplate from langchain_core.runnables import RunnablePassthrough from langchain_core.output_parsers import StrOutputParser
promt_query = """ Based on the table schema below, Write a PostgreSQL query that answer the user's question: {schema} Question: {question} SQL Query:"""
prompt_response = """ Based on the table schema, question, sql query and sql response, write a respone which is the korean language. Schema : {schema} Question : {question} SQL Query : {query} SQL Response : {response} If the sql response is not empty, please just follow the below step. - The test_item, review_criteria, test_method of the sql response must be included in the response. - When you return the reponse, return the html table code which contains the test_item, review_criteria, test_method. - And the text of the table header must be written in the korean language. If the sql response is empty, please just write a below respone. - "Refer to ~~~" """