Skip to content

Commit efe343b

Browse files
fix heading
1 parent 3d7185a commit efe343b

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

app/pipeline/inconsistency_check_pipeline.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def __call__(self, dto: InconsistencyCheckPipelineExecutionDTO, **kwargs):
102102
"consistency_issues": formatted_consistency_issues,
103103
}
104104
)
105-
105+
106106
result = summary_response.content.strip()
107107

108108
# Remove ``` from start and end if exists
@@ -112,10 +112,9 @@ def __call__(self, dto: InconsistencyCheckPipelineExecutionDTO, **kwargs):
112112
result = result[8:]
113113
result = result.strip()
114114

115-
# Remove first heading
115+
# Remove first heading or heading containing 'Summary of Consistency Issues'
116116
result = re.sub(r"^#\s.*?\n", "", result)
117-
118-
logger.info(f"Consistency issues found: {result}")
117+
result = re.sub(r"^#+.*?Summary of Consistency Issues\s*\n", "", result)
119118

120119
self._append_tokens(self.llm.tokens, PipelineEnum.IRIS_INCONSISTENCY_CHECK)
121120
self.callback.done(final_result=result, tokens=self.tokens)

app/pipeline/prompts/inconsistency_check_prompts.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
</ConsistencyIssues>
5757
5858
<Response>
59-
Respond with a summary of the consistency issues found in the exercise. \
60-
Just provide the easily digestible formatted markdown without other explanations.
59+
Respond with a summary of the consistency issues found in the exercise. Make it clear which file path contains the \
60+
issues. Just provide the easily digestible formatted markdown without other explanations.
6161
</Response>
6262
"""

0 commit comments

Comments
 (0)