AI Analysis: persist analysis on candidate profile
This commit is contained in:
@@ -23,6 +23,12 @@ class AIAnalysisController extends Controller
|
||||
|
||||
try {
|
||||
$analysis = $this->aiService->analyze($candidate);
|
||||
|
||||
// Persist the analysis on the candidate profile
|
||||
$candidate->update([
|
||||
'ai_analysis' => $analysis
|
||||
]);
|
||||
|
||||
return response()->json($analysis);
|
||||
} catch (\Exception $e) {
|
||||
return response()->json(['error' => $e->getMessage()], 500);
|
||||
|
||||
Reference in New Issue
Block a user