feat(cv-import): add source-grounded review and explicit corrections

This commit is contained in:
cesnimda
2026-10-26 15:56:54 +01:00
parent 9e1726c61d
commit e941b3ccb7
24 changed files with 943 additions and 48 deletions
+5
View File
@@ -28,6 +28,11 @@ test("legacy structured items without IDs remain usable and acquire no client-ge
}
});
test("reviewed field provenance survives client normalization and a later save", () => {
const source = { metadata: { fields: { "skills.0": { sourceBlockId: "b0001", sourceArtifactId: 21, sourceExtractionRunId: 7, sourceFileSha256: "abc", method: "deterministic-source" } } }, skills: ["C#"] };
expect(normalizeStructuredCv(JSON.parse(JSON.stringify(source))).metadata.fields["skills.0"]).toMatchObject(source.metadata.fields["skills.0"]);
});
test("legacy parsed sections keep their facts without inventing structured item IDs", () => {
const profile = parseStructuredCvJson(JSON.stringify([
{ name: "Professional Summary", content: "Recorded delivery\nRecorded support", wordCount: 4 },