Skip to content

[Feat] 금융기관 공식정보 검증 결과 연동 및 AI 장애 안전모드 응답 개선 - #82

Merged
LATE-BL00MER merged 1 commit into
developfrom
feat/financial-verification-safe-mode
Aug 8, 2026
Merged

[Feat] 금융기관 공식정보 검증 결과 연동 및 AI 장애 안전모드 응답 개선#82
LATE-BL00MER merged 1 commit into
developfrom
feat/financial-verification-safe-mode

Conversation

@LATE-BL00MER

@LATE-BL00MER LATE-BL00MER commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

📋 작업 내용

  • AI 분석 결과의 institutionContactMismatch, mentionedInstitutions를 Spring 메시지 계약에 추가했습니다.
  • 금융기관 공식 홈페이지 또는 대표번호 불일치 결과를 IMPERSONATION 위험 지표로 변환하도록 구현했습니다.
  • AnalysisResponsefailedTracks 필드를 추가해 외부 AI 일부 장애 원인을 별도로 조회할 수 있도록 개선했습니다.
  • 기존 ANALYSIS_TRACK_FAILURE 지표에서 실패 트랙을 추출해 응답 DTO에 매핑했습니다.
  • 결과 적용, 응답 매핑 및 RabbitMQ 메시지 계약 관련 테스트를 보강했습니다.

🧪 테스트 결과

  • AnalysisResultApplyMappingTest 통과
  • AnalysisResponseMapperTest 통과
  • AnalysisResultValidatorTest 통과
  • AnalysisResultConsumerTest 통과
  • ⚠️ 전체 테스트 151개 중 150개 통과
    • 기존 AuthFlowTest 1개는 로컬 Redis 미실행으로 실패
    • 이번 분석 기능 변경과는 관련 없는 인증 테스트 환경 문제

🔗 관련 이슈

Closes #81

✅ 체크리스트

  • 관련 이슈를 연결했습니다.
  • 구현 범위와 변경 이유를 설명했습니다.
  • 로컬 전체 테스트를 통과했습니다. (Redis 의존 테스트 1개 제외)
  • API 변경 사항을 Swagger에 반영했습니다.
  • DB 변경 사항과 마이그레이션을 포함했습니다. (DB 변경 없음)
  • 민감 정보가 코드·로그·테스트 데이터에 포함되지 않았습니다.
  • 프론트엔드에 영향을 주는 응답 스키마 또는 Enum 변경을 공유했습니다.
  • 병합 전 작업 브랜치를 삭제하지 않았습니다.

Summary by CodeRabbit

  • New Features
    • Analysis results now identify unavailable analysis tracks when processing is only partially completed.
    • Added official-institution contact verification results, including detected institution names when a mismatch is found.
  • Bug Fixes
    • Improved handling of failed analysis indicators by reporting distinct, meaningful track names.
  • Tests
    • Added coverage for partial-analysis reporting and institution impersonation detection.

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The PR exposes unavailable analysis tracks in AnalysisResponse and maps them from failure indicators. It extends RuleAnalysis with institution-contact mismatch data and creates bounded IMPERSONATION indicators during successful result application.

Changes

Analysis result contracts and mappings

Layer / File(s) Summary
Failed-track response mapping
src/main/java/com/gold/safefam/domain/analysis/dto/AnalysisResponse.java, src/main/java/com/gold/safefam/domain/analysis/mapper/AnalysisResponseMapper.java, src/test/java/com/gold/safefam/domain/analysis/mapper/AnalysisResponseMapperTest.java
AnalysisResponse includes failedTracks. The mapper extracts distinct nonblank track names from ANALYSIS_TRACK_FAILURE indicators. Tests cover the TEXT:GEMINI case.
Institution mismatch indicator
src/main/java/com/gold/safefam/domain/analysis/messaging/event/AnalysisResultEvent.java, src/main/java/com/gold/safefam/domain/analysis/service/AnalysisResultApplyService.java, src/test/java/com/gold/safefam/support/AnalysisResultEventFixture.java, src/test/java/com/gold/safefam/domain/analysis/service/AnalysisResultApplyMappingTest.java
RuleAnalysis carries mismatch and mentioned-institution fields. Successful result application creates a truncated IMPERSONATION indicator with up to three institutions or fallback text. Tests cover KB국민은행.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related issues

Possibly related PRs

Suggested labels: feat

Suggested reviewers: pearseona

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes both main changes: financial institution information verification integration and improved AI failure safe-mode responses.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/financial-verification-safe-mode

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.

@LATE-BL00MER

Copy link
Copy Markdown
Contributor Author

🔄 연계 작업

  • 이 PR은 두 고도화 항목 중 Spring Boot 담당 범위만 포함합니다.
  • 금융기관 공식 도메인·대표번호 매핑 및 불일치 판정 생성은 AI 저장소에서 진행합니다.
  • 외부 AI 장애격리와 PARTIAL·failedTracks 생성은 AI 저장소에서 진행합니다.
  • 프론트엔드는 failedTracks 응답 연동 및 안전모드 화면을 확인합니다.

@LATE-BL00MER
LATE-BL00MER merged commit 4564984 into develop Aug 8, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feat] 금융기관 공식정보 검증 결과 연동 및 AI 장애 안전모드 응답 개선

1 participant