Fixed RAG bug

This commit is contained in:
James Ketr 2025-06-02 21:05:30 -07:00
parent cde4305c9b
commit 88a2b9dd90
5 changed files with 6 additions and 4 deletions

View File

@ -33,6 +33,7 @@ const CandidateInfo: React.FC<CandidateInfoProps> = (props: CandidateInfoProps)
if (!candidate) {
return <Box>No user loaded.</Box>;
}
console.log(candidate);
return (
<Card
elevation={elevation}

View File

@ -559,7 +559,7 @@ function useAuthenticationLogic() {
...prev,
user: updatedUser
}));
console.log('User data updated');
console.log('User data updated', updatedUser);
}, []);
const createCandidateAccount = useCallback(async (candidateData: CreateCandidateRequest): Promise<boolean> => {

View File

@ -208,6 +208,7 @@ const CandidateProfilePage: React.FC<BackstoryPageProps> = (props: BackstoryPage
if (e.target.files && e.target.files[0]) {
if (await apiClient.uploadCandidateProfile(e.target.files[0])) {
candidate.profileImage = 'profile.' + e.target.files[0].name.replace(/^.*\./, '');
console.log(`Set profile image to: ${candidate.profileImage}`);
updateUserData(candidate);
}
}

View File

@ -1,6 +1,6 @@
// Generated TypeScript types from Pydantic models
// Source: src/backend/models.py
// Generated on: 2025-06-03T02:54:38.566349
// Generated on: 2025-06-03T04:01:05.747332
// DO NOT EDIT MANUALLY - This file is auto-generated
// ============================

View File

@ -2067,7 +2067,7 @@ async def search_candidate_documents(
class RAGDocumentRequest(BaseModel):
"""Request model for RAG document content"""
doc_id: str
id: str
@api_router.post("/candidates/rag-content")
async def post_candidate_vector_content(
@ -2235,7 +2235,7 @@ async def get_candidates(
[c.model_dump(by_alias=True, exclude_unset=True) for c in paginated_candidates],
page, limit, total
)
return create_success_response(paginated_response)
except Exception as e: