Skip to content

Commit

Permalink
Merge pull request #955 from AI4Bharat/new-transliteration-logging1
Browse files Browse the repository at this point in the history
New transliteration logging1
  • Loading branch information
ishvindersethi22 authored Mar 1, 2024
2 parents a6987bf + 8e7776f commit 1bc71c3
Show file tree
Hide file tree
Showing 11 changed files with 198 additions and 80 deletions.
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"@ai4bharat/indic-transliterate": "^1.2.14",
"@ai4bharat/indic-transliterate": "github:AI4Bharat/indic-transliterate-js-new",
"@emotion/react": "^11.9.0",
"@emotion/styled": "^11.8.1",
"@heartexlabs/label-studio": "^1.4.0",
Expand Down
31 changes: 31 additions & 0 deletions src/IndicTransliterate/index.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ import LightTooltip from "../../component/common/Tooltip";

const AllAudioTranscriptionLandingPage = () => {
const classes = AudioTranscriptionLandingStyle();
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const dispatch = useDispatch();
const navigate = useNavigate();
const annotationNotesRef = useRef(null);
Expand Down Expand Up @@ -599,6 +601,9 @@ const AllAudioTranscriptionLandingPage = () => {
/>
</div>
)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%" }}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ import LightTooltip from "../../component/common/Tooltip";

const AudioTranscriptionLandingPage = () => {
const classes = AudioTranscriptionLandingStyle();
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const dispatch = useDispatch();
const navigate = useNavigate();
let location = useLocation();
Expand Down Expand Up @@ -1104,6 +1106,9 @@ useEffect(() => {
/>
</div>
)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%" }}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ import LightTooltip from "../../component/common/Tooltip"

const ReviewAudioTranscriptionLandingPage = () => {
const classes = AudioTranscriptionLandingStyle();
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const dispatch = useDispatch();
const navigate = useNavigate();
let location = useLocation();
Expand Down Expand Up @@ -1326,6 +1328,9 @@ useEffect(() => {
/>
</div>
)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%" }}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ import LightTooltip from "../../component/common/Tooltip";

const SuperCheckerAudioTranscriptionLandingPage = () => {
const classes = AudioTranscriptionLandingStyle();
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const dispatch = useDispatch();
const navigate = useNavigate();
let location = useLocation();
Expand Down Expand Up @@ -1142,6 +1144,9 @@ useEffect(() => {
/>
</div>
)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%" }}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@ const TranscriptionRightPanel = ({
annotationId,
}) => {
const { taskId } = useParams();
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const classes = AudioTranscriptionLandingStyle();
const navigate = useNavigate();
const dispatch = useDispatch();
Expand Down Expand Up @@ -777,6 +779,9 @@ const TranscriptionRightPanel = ({
</span> */}
</div>
)}}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%", height: "100%" }}>
Expand Down Expand Up @@ -829,6 +834,9 @@ const TranscriptionRightPanel = ({
/>
</div>
)}}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>
) : (
<div className={classes.relative} style={{ width: "100%", height: "100%" }}>
Expand Down
12 changes: 9 additions & 3 deletions src/ui/pages/container/Glossary/AddGlossary.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import {
IndicTransliterate,
getTransliterationLanguages,
} from "@ai4bharat/indic-transliterate";
import "@ai4bharat/indic-transliterate/dist/index.css";
import "../../../../IndicTransliterate/index.css";
import { MenuProps } from "../../../../utils/utils";

const AddGlossary = ({
Expand All @@ -39,6 +39,8 @@ const AddGlossary = ({
const classes = DatasetStyle();
const dispatch = useDispatch();
const allLevels = glossaryLevel;
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const [selectedSourceLang, setselectedSourceLang] = useState(Sourcelang);
const [selectedTargetLang, setselectedTargetLang] = useState(targetlang);
const [SourceText, setSourceText] = useState("");
Expand Down Expand Up @@ -284,8 +286,9 @@ const AddGlossary = ({
setSourceText(SourceText);
}}
renderComponent={(props) => renderSourceText(props)}


options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>): ( <OutlinedTextField
placeholder="Source Text"
sx={{ m: 1, width: 200 }}
Expand All @@ -300,6 +303,9 @@ const AddGlossary = ({
settargetText(targetText);
}}
renderComponent={(props) => renderTargetText(props)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>): ( <OutlinedTextField
placeholder="Target Text"
sx={{ m: 1, width: 200 }}
Expand Down
7 changes: 6 additions & 1 deletion src/ui/pages/container/Glossary/SuggestAnEdit.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import {
IndicTransliterate,
getTransliterationLanguages,
} from "@ai4bharat/indic-transliterate";
import "@ai4bharat/indic-transliterate/dist/index.css";
import "../../../../IndicTransliterate/index.css";

const SuggestAnEdit = ({
openDialog,
Expand All @@ -39,6 +39,8 @@ const SuggestAnEdit = ({
data,
targetlang
}) => {
const [options, setOptions] = useState([]);
const [selected, setSelected] = useState("");
const classes = DatasetStyle();
const dispatch = useDispatch();

Expand Down Expand Up @@ -153,6 +155,9 @@ const [Targetlanguage, setTargetlanguage] = useState([]);
settargetText(targetText);
}}
renderComponent={(props) => renderTargetText(props)}
options = {options}
setOptions = {setOptions}
setSelected = {setSelected}
/>): (
<OutlinedTextField

Expand Down
Loading

0 comments on commit 1bc71c3

Please sign in to comment.