feat: added Transkription-Display in Calibration and Annotation
This commit is contained in:
@@ -156,6 +156,7 @@ export async function getAnnotationEntries(experimentId: number): Promise<Datase
|
|||||||
experimentId: experimentId,
|
experimentId: experimentId,
|
||||||
datasetId: e.datasetId,
|
datasetId: e.datasetId,
|
||||||
annotation: annotationEntries.find((a) => a.datasetEntryId === e.id)?.rating || null,
|
annotation: annotationEntries.find((a) => a.datasetEntryId === e.id)?.rating || null,
|
||||||
|
utteranceText: e.utteranceText,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
return sortEntriesByWeightedDialectScore(mapped, dialectScores, session.user.id);
|
return sortEntriesByWeightedDialectScore(mapped, dialectScores, session.user.id);
|
||||||
|
|||||||
@@ -70,6 +70,14 @@ export default function SingleChoiceBinaryEntryView({
|
|||||||
</p>
|
</p>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{/* Utterance text */}
|
||||||
|
{entry.utteranceText && (
|
||||||
|
<div className="mt-4 mb-4 p-3 bg-gray-100 rounded-lg">
|
||||||
|
<p className="text-xs text-gray-500 uppercase tracking-wide font-semibold mb-1">Transkription</p>
|
||||||
|
<p className="text-sm text-gray-800 italic">"{entry.utteranceText}"</p>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{/* Dialect + question */}
|
{/* Dialect + question */}
|
||||||
<div className="mt-4 mb-3">
|
<div className="mt-4 mb-3">
|
||||||
<div className="text-s font-semibold text-gray-700">
|
<div className="text-s font-semibold text-gray-700">
|
||||||
|
|||||||
@@ -71,6 +71,14 @@ export default function SingleChoiceEntryView({
|
|||||||
</p>
|
</p>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{/* Utterance text */}
|
||||||
|
{entry.utteranceText && (
|
||||||
|
<div className="mt-4 mb-4 p-3 bg-gray-100 rounded-lg">
|
||||||
|
<p className="text-xs text-gray-500 uppercase tracking-wide font-semibold mb-1">Transkription</p>
|
||||||
|
<p className="text-sm text-gray-800 italic">"{entry.utteranceText}"</p>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{/* Dialect + question */}
|
{/* Dialect + question */}
|
||||||
<div className="mt-4 mb-3">
|
<div className="mt-4 mb-3">
|
||||||
<div className="text-s font-semibold text-gray-700">
|
<div className="text-s font-semibold text-gray-700">
|
||||||
|
|||||||
@@ -92,6 +92,14 @@ export default function CalibrationEntryView({
|
|||||||
</p>
|
</p>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{/* Utterance text */}
|
||||||
|
{entry.utteranceText && (
|
||||||
|
<div className="mt-4 mb-4 p-3 bg-gray-100 rounded-lg">
|
||||||
|
<p className="text-xs text-gray-500 uppercase tracking-wide font-semibold mb-1">Transkription</p>
|
||||||
|
<p className="text-sm text-gray-800 italic">"{entry.utteranceText}"</p>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{/* Questions container */}
|
{/* Questions container */}
|
||||||
<div className="mt-6 flex flex-col lg:flex-row gap-6">
|
<div className="mt-6 flex flex-col lg:flex-row gap-6">
|
||||||
{/* Dialect question */}
|
{/* Dialect question */}
|
||||||
|
|||||||
@@ -28,4 +28,5 @@ export type DatasetEntryForAnnotation = {
|
|||||||
datasetId: number;
|
datasetId: number;
|
||||||
experimentId: number;
|
experimentId: number;
|
||||||
annotation: number | null;
|
annotation: number | null;
|
||||||
|
utteranceText: string | null;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user