Skip to content

JousiaPiha/gs-tool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Finnish Translation Checker

A Flask web application to help check and improve Finnish translations sentence by sentence.

Features

  • Accepts English and Finnish JSON objects as single input
  • Supports JSON-like data with single quotes (Python dictionary format)
  • Checks translations for multiple fields: activity_label, ctx, and endings
  • Provides a field-by-field and sentence-by-sentence review interface
  • Allows easy correction of Finnish translations
  • Outputs the corrected Finnish JSON object matching the original format

Setup

  1. Ensure you have Python 3 installed
  2. Clone this repository
  3. Create a virtual environment and install dependencies:
# Navigate to the project directory
cd translation-tool

# Create a virtual environment
python3 -m venv venv

# Activate the virtual environment
source venv/bin/activate

# Install dependencies
pip install -r requirements.txt

Usage

  1. Start the application:
source venv/bin/activate
python app.py
  1. Open your web browser and navigate to http://127.0.0.1:5001
  2. Paste your English and Finnish JSON objects (separated by an empty line) into the text area
  3. Click "Start Checking" to begin the sentence-by-sentence review
  4. Edit Finnish translations as needed and click "Next Sentence" to proceed
  5. When complete, copy the corrected Finnish JSON object for use elsewhere

Input Format

The application expects two JSON objects separated by an empty line. The objects should be in the following format:

{'ind': 33713, 'activity_label': 'Personal Care and Style', 'ctx_a': '...', 'endings': ['sentence 1', 'sentence 2'], ...}

{'ind': 33713, 'activity_label': 'Henkilökohtainen hoito ja tyyli', 'ctx_a': '...', 'endings': ['sentence 1', 'sentence 2'], ...}

The most important fields are:

  • endings: Array of sentences to be checked and potentially corrected
  • ctx: Context information to help with translation checking

Note

This application preserves the original quote style of your input JSON for the final output.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published