提示词适配

master
daixiaoyi 1 month ago
parent 5677140172
commit c72724f00b

@ -193,60 +193,58 @@ public class PromptCache {
private static final String TEXT_TO_CYPHER_PROMPT = """ private static final String TEXT_TO_CYPHER_PROMPT = """
Neo4j Cypher Neo4j Cypher
--- ---
**** ****
- **relationType** - **relationType**
{relationTypeList} {relationTypeList}
- **sourceType** - **sourceType**
{sourceTypeList} {sourceTypeList}
- **targetType** - **targetType**
{targetTypeList} {targetTypeList}
--- ---
**** ****
1. `Cypher ` 1. `Cypher `
2. 使 `WHERE` 2. 使 `WHERE`
3. **** 3. ****
4. Cypher 4. json
5. relationTypesourceType targetType 5. relationTypesourceType targetType
``` "无法根据数据库结构生成查询"
```
--- ---
**** ****
1. - **** 1. - ****
- ** Cypher ** - ** Cypher **
\\{ "\\{
"cypherQueries": [ "cypherQueries": [
"MATCH (c:Company)-[r:HAS_LEGAL_REP]->(t) RETURN c, r, t", "MATCH (c:Company)-[r:HAS_LEGAL_REP]->(t) RETURN c, r, t",
"MATCH (c:Company)-[r:HAS_PHONE]->(t) RETURN c, r, t", "MATCH (c:Company)-[r:HAS_PHONE]->(t) RETURN c, r, t",
..... .....
] ]
\\} \\}"
2. - **** 2. - ****
- ** Cypher ** - ** Cypher **
\\{ "\\{
"cypherQueries": [ "cypherQueries": [
"MATCH (c:Company)-[r:IssueDocument]->(t:FinancialBill) RETURN c, r, t", "MATCH (c:Company)-[r:IssueDocument]->(t:FinancialBill) RETURN c, r, t",
..... .....
] ]
\\} \\}"
{query} {query}
Cypher Cypher
"""; """;
private static final String GENERATE_ANSWER_PROMPT = """ private static final String GENERATE_ANSWER_PROMPT = """

Loading…
Cancel
Save