{"id":13689790,"url":"https://github.com/bitextor/bleualign-cpp","last_synced_at":"2025-05-02T06:31:21.958Z","repository":{"id":36296039,"uuid":"200035169","full_name":"bitextor/bleualign-cpp","owner":"bitextor","description":null,"archived":false,"fork":false,"pushed_at":"2023-03-10T21:02:57.000Z","size":129,"stargazers_count":7,"open_issues_count":2,"forks_count":2,"subscribers_count":11,"default_branch":"master","last_synced_at":"2024-11-12T15:43:11.715Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bitextor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2019-08-01T11:07:45.000Z","updated_at":"2022-11-15T11:53:23.000Z","dependencies_parsed_at":"2024-01-14T17:15:21.595Z","dependency_job_id":"b64765f0-2248-4823-b32c-0e44a1159785","html_url":"https://github.com/bitextor/bleualign-cpp","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitextor%2Fbleualign-cpp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitextor%2Fbleualign-cpp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitextor%2Fbleualign-cpp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitextor%2Fbleualign-cpp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bitextor","download_url":"https://codeload.github.com/bitextor/bleualign-cpp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251998406,"owners_count":21677979,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T16:00:27.251Z","updated_at":"2025-05-02T06:31:21.682Z","avatar_url":"https://github.com/bitextor.png","language":"C++","readme":"# Bleualign-cpp\nC++ sentence alignment tool based on [Bleualign](https://github.com/rsennrich/Bleualign).\nBleualign-cpp is expected to be used together with [document-aligner](https://github.com/bitextor/bitextor/tree/master/document-aligner).\n\n### Requirements\n- GCC, C++11 compiler\n- [Boost](https://www.boost.org/) 1.58.0 or later\n- [CMake](https://cmake.org/download/) 3.7.2 or later\n- [GTest](https://github.com/google/googletest) (for tests)\n- [kpu/preprocess](https://github.com/kpu/preprocess) (already included in this repository as a submodule)\n\n\n### Compile with CMake\n\n```bash\nmkdir build\ncd build\ncmake .. -DBUILD_TEST=on -DCMAKE_BUILD_TYPE=Release\n# use `cmake .. -DBUILD_TEST=on -DCMAKE_BUILD_TYPE=Release -DPREPROCESS_PATH=/home/user/preprocess/` if you use other 'preprocess' folder\nmake -j 4\ntests/test_all\n```\n\n\n### Usage\n\nBleualign-cpp takes two texts in two different languages and aligns them to produce parallel sentences. To this end, it also needs a translation of one of these texts.\n\nInput format is `url1 \u003ctab\u003e url2 \u003ctab\u003e text1 \u003ctab\u003e text2 \u003ctab\u003e text1translated [ \u003ctab\u003e text2processed ] [ \u003ctab\u003e text1metadata \u003ctab\u003e text2metadata ]` per line. Every text column is encoded as base64. After decoding text columns, they should contain a single sentence per line. The translation (`text1translated`) should correspond line-by-line with the original text (`text1`). The first line will be a header where, following the explained format, the expected fields are: `src_url \u003ctab\u003e trg_url \u003ctab\u003e src_text \u003ctab\u003e trg_text \u003ctab\u003e src_translated [ \u003ctab\u003e trg_translated ] [ \u003ctab\u003e src_metadata \u003ctab\u003e trg_metadata ]`. The first line of the output will contain a header as well which, depending on the provided arguments, the fields will be: `src_url \u003ctab\u003e trg_url \u003ctab\u003e src_text \u003ctab\u003e trg_text \u003ctab\u003e bleualign_score [ \u003ctab\u003e src_deferred_hash \u003ctab\u003e trg_deferred_hash ] [ \u003ctab\u003e src_metadata_field_1 \u003ctab\u003e trg_metadata_field_1 ... ]`.\n\nOptionally a processed version of `text2` can be provided, as a sixth column, that better matches the processing applied to `text1translated` to help with calculating alignment scores. The output of bleualign will only mention `text1` and `text2`.\n\nBleualign-cpp outputs aligned sentences to standard output. Output format is (mandatory fields only): `url1 \u003ctab\u003e url2 \u003ctab\u003e source_sentence \u003ctab\u003e target_sentence \u003ctab\u003e score` per line.\n\nBleualign receives input by stdin and writes output to stdout.\n\n##### Optional Parameters\n* **--help** - Print help dialog\n* **--bleu_threshold** - Sentence-level BLEU score threshold (Default: 0.0)\n* **--print-sent-hash** - Print hash for each sentence\n* **--metadata-header-fields** - Language agnostic comma separated list of metadata header fields (prefix `src_` and `trg_` will be added after)\n","funding_links":[],"categories":["Aligners 🌌"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitextor%2Fbleualign-cpp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbitextor%2Fbleualign-cpp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitextor%2Fbleualign-cpp/lists"}