package com.purui.prims.headless.chat.query;

import com.purui.prims.auth.api.authentication.pojo.User;
import com.purui.prims.headless.api.pojo.DataSetSchema;
import com.purui.prims.headless.api.pojo.SemanticParseInfo;
import com.purui.prims.headless.api.pojo.request.SemanticQueryReq;
import org.apache.calcite.sql.parser.SqlParseException;

/**
 * A semantic query executes specific type of query based on the results of semantic parsing.
 */
public interface SemanticQuery {

    String getQueryMode();

    SemanticQueryReq buildSemanticQueryReq() throws SqlParseException;

    void initS2Sql(DataSetSchema semanticSchema, User user);

    SemanticParseInfo getParseInfo();

    void setParseInfo(SemanticParseInfo parseInfo);
}
