Skip to content

[refactor] 메모와 AI요약 분리#1158

Merged
lepitaaar merged 2 commits intodevelop/befrom
refactor/#1156-split-memo-ai-summary-MOA-617
Feb 8, 2026
Merged

[refactor] 메모와 AI요약 분리#1158
lepitaaar merged 2 commits intodevelop/befrom
refactor/#1156-split-memo-ai-summary-MOA-617

Conversation

@lepitaaar
Copy link
Contributor

@lepitaaar lepitaaar commented Feb 8, 2026

#️⃣연관된 이슈

#1156

📝작업 내용

  • ClubApplicant 엔티티에 aiSummary 필드 추가
  • updateAiSummary() 메서드 추가
  • ApplicantIdMessageConsumer에서 AI 요약 결과를 memo 대신 aiSummary 필드에 저장하도록 변경
  • 기존 memo 필드는 사용자 메모용으로 유지

중점적으로 리뷰받고 싶은 부분(선택)

리뷰어가 특별히 봐주었으면 하는 부분이 있다면 작성해주세요

ex) 메서드 XXX의 이름을 더 잘 짓고 싶은데 혹시 좋은 명칭이 있을까요?

논의하고 싶은 부분(선택)

논의하고 싶은 부분이 있다면 작성해주세요.

🫡 참고사항

Summary by CodeRabbit

릴리스 노트

  • 새로운 기능

    • 동아리 지원자에 대해 AI가 생성한 요약을 저장하고 관리하는 기능 추가
    • 지원자 요약을 개별적으로 갱신할 수 있는 업데이트 기능 제공
  • 버그 수정

    • AI 응답이 없을 때 기존 요약을 덮어쓰지 않도록 보호(무효 응답 차단)

- ClubApplicant 엔티티에 aiSummary 필드 추가
- updateAiSummary() 메서드 추가
- ApplicantIdMessageConsumer에서 AI 요약 결과를 memo 대신 aiSummary 필드에 저장하도록 변경
- 기존 memo 필드는 사용자 메모용으로 유지
@lepitaaar lepitaaar self-assigned this Feb 8, 2026
@lepitaaar lepitaaar added ✨ Feature 기능 개발 🔨 Refactor 코드 리팩토링 💾 BE Backend labels Feb 8, 2026
@vercel
Copy link

vercel bot commented Feb 8, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
moadong Ready Ready Preview, Comment Feb 8, 2026 5:12am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 8, 2026

Warning

.coderabbit.yaml has a parsing error

The CodeRabbit configuration file in this repository has a parsing error and default settings were used instead. Please fix the error(s) in the configuration file. You can initialize chat with CodeRabbit to get help with the configuration file.

💥 Parsing errors (1)
Validation error: Invalid regex pattern for base branch. Received: "**" at "reviews.auto_review.base_branches[0]"
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Walkthrough

ClubApplicant 엔티티에 aiSummary 필드를 추가하고 updateAiSummary() 메서드를 도입했습니다. ApplicantIdMessageConsumer에서는 summarize 응답이 null인지 검사하고, null이 아닌 경우 updateAiSummary(...)를 호출하도록 변경되었습니다.

Changes

Cohort / File(s) Summary
ClubApplicant 엔티티 확장
backend/src/main/java/moadong/club/entity/ClubApplicant.java
aiSummary 필드 추가(@Builder.Default ""), public void updateAiSummary(String aiSummary) 메서드 추가.
메시지 컨슈머 업데이트
backend/src/main/java/moadong/club/summary/ApplicantIdMessageConsumer.java
summarize 응답에 대한 null 체크(조기 리턴) 추가 및 기존 updateMemo(...) 호출을 updateAiSummary(...)로 변경하여 AI 요약을 별도 필드에 저장하도록 수정.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • seongwon030
  • Zepelown
  • oesnuj
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 제목은 변경사항의 핵심(메모와 AI요약 분리)을 명확하게 요약하고 있으며, PR 목표와 일치합니다.
Linked Issues check ✅ Passed PR은 MOA-617의 요구사항을 충족합니다: aiSummary 필드 추가, updateAiSummary() 메서드 구현, AI 응답을 aiSummary에 저장하는 방식으로 변경되었습니다.
Out of Scope Changes check ✅ Passed 모든 변경사항이 메모와 AI요약 분리라는 정의된 범위 내에 있으며, 범위를 벗어난 변경은 없습니다.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch refactor/#1156-split-memo-ai-summary-MOA-617

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Feb 8, 2026

Test Results

72 tests   72 ✅  20s ⏱️
14 suites   0 💤
14 files     0 ❌

Results for commit 4284f3d.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@backend/src/main/java/moadong/club/summary/ApplicantIdMessageConsumer.java`:
- Around line 80-81: The code currently logs sensitive decrypted applicant data
by calling log.info(prompt.toString()) and logging the AIResponse
summarizeContent; update ApplicantIdMessageConsumer to avoid emitting PII at
INFO level—either remove the log.info(prompt.toString()) entirely or change it
to log.debug(...) and ensure any AIResponse (summarizeContent) is only logged at
debug or with sensitive fields redacted; keep calls to
gemmaService.getSummarizeContent(...) intact but ensure any logging around
prompt.toString() and summarizeContent uses debug level or sanitized output so
decrypted personal data is not written to production logs.
- Around line 83-88: Move the aiSummary guard before calling
gemmaService.getSummarizeContent() to avoid unnecessary AI calls and
decryption/prompt work: check clubApplicant.getAiSummary() at the start of
processing and return/skip if non-empty. Only call
gemmaService.getSummarizeContent() and then
clubApplicant.updateAiSummary(summarizeContent.response()) when the summary is
missing. Also avoid unconditionally calling
clubApplicantsRepository.save(clubApplicant) when no update occurred—only save
after updateAiSummary() was applied.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@backend/src/main/java/moadong/club/summary/ApplicantIdMessageConsumer.java`:
- Around line 83-86: summarizeContent.response() can be non-null but empty,
which would overwrite existing aiSummary; in ApplicantIdMessageConsumer (around
the block using summarizeContent.response()) add a check that the response is
not blank/empty (e.g., !response.isBlank()/!response.isEmpty()) before calling
clubApplicant.updateAiSummary(response), and skip/update only when it has
non-empty content (optionally log a debug/info message when an empty response is
received) to avoid clobbering existing aiSummary.

Copy link
Member

@Zepelown Zepelown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다.

@lepitaaar lepitaaar merged commit f157cf4 into develop/be Feb 8, 2026
5 checks passed
@lepitaaar lepitaaar deleted the refactor/#1156-split-memo-ai-summary-MOA-617 branch February 21, 2026 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

💾 BE Backend ✨ Feature 기능 개발 🔨 Refactor 코드 리팩토링

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants