STT 서비스 음성 인식 및 AI 제안사항 표시 기능 구현

- PCM 16kHz 포맷 지원으로 Azure Speech 인식 성공
- WebSocket 실시간 전송 기능 추가
- DB 저장 로직 제거 (AI 서비스에서 제안사항 저장)
- AI SSE 기반 제안사항 표시 테스트 페이지 추가

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Minseo-Jo
2025-10-28 10:12:55 +09:00
parent 7e30f6b82e
commit 2c3bc432b3
16 changed files with 1610 additions and 76 deletions
+1 -1
View File
@@ -57,7 +57,7 @@
<entry key="AZURE_AI_SEARCH_INDEX" value="meeting-transcripts" />
<!-- Azure Event Hubs Configuration -->
<entry key="AZURE_EVENTHUB_CONNECTION_STRING" value="Endpoint=sb://hgzero-eventhub-ns.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=VUqZ9vFgu35E3c6RiUzoOGVUP8IZpFvlV+AEhC6sUpo=" />
<entry key="AZURE_EVENTHUB_CONNECTION_STRING" value="Endpoint=sb://hgzero-eventhub-ns.servicebus.windows.net/;SharedAccessKeyName=ai-listen-policy;SharedAccessKey=wqcbVIXlOMyn/C562lx6DD75AyjHQ87xo+AEhJ7js9Q=;EntityPath=hgzero-eventhub-name" />
<entry key="AZURE_EVENTHUB_NAMESPACE" value="hgzero-eventhub-ns" />
<entry key="AZURE_EVENTHUB_NAME" value="hgzero-eventhub-name" />
<entry key="AZURE_CHECKPOINT_STORAGE_CONNECTION_STRING" value="" />
@@ -50,31 +50,29 @@ public class EventHubConfig {
@PostConstruct
public void startEventProcessor() {
// Checkpoint Storage가 설정되지 않은 경우 Event Hub 기능 비활성화
if (checkpointStorageConnectionString == null || checkpointStorageConnectionString.isEmpty()) {
log.warn("Event Hub Processor 비활성화 - checkpoint storage 설정이 없습니다. " +
"개발 환경에서는 Event Hub 없이 실행 가능하며, 운영 환경에서는 AZURE_CHECKPOINT_STORAGE_CONNECTION_STRING 환경 변수를 설정해야 합니다.");
return;
}
log.info("Event Hub Processor 시작 - eventhub: {}, consumerGroup: {}",
eventHubName, consumerGroup);
// Blob Checkpoint Store 생성 (체크포인트 저장소)
BlobContainerAsyncClient blobContainerAsyncClient = new BlobContainerClientBuilder()
.connectionString(checkpointStorageConnectionString)
.containerName(checkpointContainer)
.buildAsyncClient();
// Event Processor Client 빌드
eventProcessorClient = new EventProcessorClientBuilder()
EventProcessorClientBuilder builder = new EventProcessorClientBuilder()
.connectionString(connectionString, eventHubName)
.consumerGroup(consumerGroup)
.checkpointStore(new BlobCheckpointStore(blobContainerAsyncClient))
.processEvent(this::processEvent)
.processError(this::processError)
.buildEventProcessorClient();
.processError(this::processError);
// Checkpoint Storage 설정
if (checkpointStorageConnectionString != null && !checkpointStorageConnectionString.isEmpty()) {
log.info("Checkpoint Storage 활성화 (Azure Blob) - container: {}", checkpointContainer);
BlobContainerAsyncClient blobContainerAsyncClient = new BlobContainerClientBuilder()
.connectionString(checkpointStorageConnectionString)
.containerName(checkpointContainer)
.buildAsyncClient();
builder.checkpointStore(new BlobCheckpointStore(blobContainerAsyncClient));
} else {
log.warn("Checkpoint Storage 미설정 - InMemory 모드 사용 (MVP 개발용, 재시작 시 처음부터 읽음)");
builder.checkpointStore(new InMemoryCheckpointStore());
}
eventProcessorClient = builder.buildEventProcessorClient();
eventProcessorClient.start();
log.info("Event Hub Processor 시작 완료");