feat:전체 AI 서비스에 토큰 사용량 기록 추가
- AiTokenHelper 공통 헬퍼 생성 (Gemini/Claude 응답 파서) - BizCertOcrService (Claude) 토큰 기록 추가 - BusinessCardOcrService (Gemini) 토큰 기록 추가 - MeetingLogService (Claude) 토큰 기록 추가 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Services;
|
||||
|
||||
use App\Helpers\AiTokenHelper;
|
||||
use App\Models\MeetingLog;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
@@ -171,6 +172,9 @@ private function generateSummary(string $transcript, string $summaryType = 'meet
|
||||
if ($response->successful()) {
|
||||
$data = $response->json();
|
||||
|
||||
// 토큰 사용량 저장
|
||||
AiTokenHelper::saveClaudeUsage($data, 'claude-3-haiku-20240307', '회의록AI요약');
|
||||
|
||||
return $data['content'][0]['text'] ?? null;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user