mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-14 22:08:56 +00:00
(improvement)(launcher) Optimize Demo to distinguish domain and model sets (#1056)
Co-authored-by: jolunoluo
This commit is contained in:
@@ -48,12 +48,8 @@ public class OnePassSCSqlGenStrategy extends SqlGenStrategy {
|
||||
}
|
||||
);
|
||||
//3.format response.
|
||||
List<String> schemaLinkingResults = llmResults.stream()
|
||||
.map(llmResult -> OutputFormat.getSchemaLinks(llmResult)).collect(Collectors.toList());
|
||||
List<String> candidateSortedList = OutputFormat.formatList(schemaLinkingResults);
|
||||
Pair<String, Map<String, Double>> linkingMap = OutputFormat.selfConsistencyVote(candidateSortedList);
|
||||
List<String> sqlList = llmResults.stream()
|
||||
.map(llmResult -> OutputFormat.getSql(llmResult)).collect(Collectors.toList());
|
||||
.map(OutputFormat::getSql).collect(Collectors.toList());
|
||||
|
||||
Pair<String, Map<String, Double>> sqlMapPair = OutputFormat.selfConsistencyVote(sqlList);
|
||||
|
||||
|
||||
@@ -45,7 +45,6 @@ public class TwoPassSCSqlGenStrategy extends SqlGenStrategy {
|
||||
}
|
||||
);
|
||||
List<String> sortedList = OutputFormat.formatList(linkingResults);
|
||||
Pair<String, Map<String, Double>> linkingMap = OutputFormat.selfConsistencyVote(sortedList);
|
||||
//3.generator sql prompt,and parallel generate response.
|
||||
List<String> sqlPromptPool = promptGenerator.generateSqlPromptPool(llmReq, sortedList, exampleListPool);
|
||||
List<String> sqlTaskPool = new CopyOnWriteArrayList<>();
|
||||
|
||||
Reference in New Issue
Block a user