Skip to content

Commit

Permalink
fix: sort result
Browse files Browse the repository at this point in the history
  • Loading branch information
r-4bb1t committed Feb 16, 2024
1 parent c74b9fb commit a189def
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/gpt/summarize.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def generate_summary(input_messages):

system_message = {
"role": "system",
"content": "이 AI는 사용자의 이야기를 듣고, 존댓말을 사용하여 약간의 요약하고 정리하는 작가입니다. 자연스러우면서도 진정성 있는 요약을 제공하는 것이 목표입니다. 본문은 자서전 형식에 맞게 1인칭 시점을 유지하며, 부가적인 설명은 최소화합니다('이렇게 정리해볼게요'와 같은 표현은 사용하지 않습니다). 사용자의 경험과 감정을 정확히 반영하여 요약하되, 내용을 과장하지 않습니다. 요약은 충분한 세부 정보를 포함하여 사용자의 원래 의도와 감정을 표현합니다. 요약은 존댓말(예: '했습니다', '되었습니다', '있었습니다')로 적어주세요."
"content": "이 AI는 사용자의 이야기를 듣고, 존댓말을 사용하여 약간의 요약하고 정리하는 작가입니다. 자연스러우면서도 진정성 있는 요약을 제공하는 것이 목표입니다. 본문은 자서전 형식에 맞게 user의 입장에서 1인칭 시점을 유지하며, 부가적인 설명은 최소화합니다('이렇게 정리해볼게요'와 같은 표현은 사용하지 않습니다). 사용자의 경험과 감정을 정확히 반영하여 요약하되, 내용을 과장하지 않습니다. 요약은 충분한 세부 정보를 포함하여 사용자의 원래 의도와 감정을 표현합니다. 요약은 존댓말(예: '했습니다', '되었습니다', '있었습니다')로 적어주세요."
}


Expand Down
1 change: 1 addition & 0 deletions src/routers/result.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ async def get_chapters(user=Depends(get_current_user), db: Session = Depends(get
"summaries": summaries
})
result = list(filter(lambda x: x["summaries"], result))
result = sorted(result, key=lambda x: x["chapter_id"])
return result

0 comments on commit a189def

Please sign in to comment.