Extension:ContentTranslation/cs

Category:GPL licensed extensions/cs
Příručka k rozšířením MediaWiki
ContentTranslation
Stav rozšíření: stabilníCategory:Stable extensions/cs
Implementace Uživatelské rozhraníCategory:User interface extensions/cs, Akce stránky Category:Page action extensions/cs
Popis Tento nástroj umožňuje editorům přeložit článek z jednoho jazyka do druhého za pomoci strojového překladu a dalších pomůcek.
Autoři Jazykový tým
Zásady kompatibility Vydání snímků současně s MediaWiki. Hlavní vývojová větev není zpětně kompatibilní.
MediaWiki 1.37+Category:Extensions with manual MediaWiki version
PHP 7.2+
Změny v databázi Ano
Composer mediawiki/content-translationCategory:Extensions supporting Composer/cs
Tabulky cx_translations
cx_translators
cx_lists
cx_suggestions
cx_corpora
cx_notification_log
cx_significant_edits
cx_section_translations
Licence GNU General Public License 2.0 nebo novější
Stáhnout Category:Extensions in Wikimedia version control/cs
Nápověda Help:Extension:ContentTranslation/cs
  • $wgContentTranslationEnableSuggestions
  • $wgContentTranslationTargetNamespace
  • $wgContentTranslationContentImportForSectionTranslation
  • $wgContentTranslationDomainCodeMapping
  • $wgContentTranslationCXServerAuth
  • $wgContentTranslationEnableAnonSectionTranslation
  • $wgContentTranslationExcludedNamespaces
  • $wgContentTranslationCluster
  • $wgContentTranslationAsBetaFeature
  • $wgContentTranslationTranslateInTarget
  • $wgContentTranslationDevMode
  • $wgRecommendToolAPIURL
  • $wgDraftMaxAge
  • $wgAutomaticTranslationLanguageSearcherEntrypointEnabledLanguages
  • $wgContentTranslationEnableMT
  • $wgContentTranslationEnableUnifiedDashboard
  • $wgSectionTranslationTargetLanguages
  • $wgContentTranslationSiteTemplates
  • $wgContentTranslationUnmodifiedMTThresholdForPublish
  • $wgContentTranslationVersion
  • $wgContentTranslationPublishRequirements
  • $wgContentTranslationCampaigns
  • $wgContentTranslationDatabase
Čtvrtletní stahování 27 (Ranked 90th)
Přeložte rozšíření ContentTranslation, používá-li lokalizaci z translatewiki.net
Problémy Otevřené úkoly · Nahlásit chybu
Category:All extensions/cs

Rozšíření ContentTranslation je nástroj, který umožňuje editorům překládat článek z jednoho jazyka do druhého pomocí strojového překladu a dalších překladatelských pomůcek. Viz Překlad pro pozadí a další informace. Rozšíření je vyvíjeno týmem Wikimedia Language Engineering.

Instalace

This extension requires a Content Translation server to be setup first. Morover it has three extension dependencies.
  • Stáhněte soubor/y a vložte je do adresáře pojmenovaného ContentTranslation ve vaší složce extensions/.
    Vývojáři a přispěvatelé kódu by si místo toho měli nainstalovat rozšíření from Git pomocí:cd extensions/
    git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/ContentTranslation
  • Při instalaci z Gitu spusťte Composer pro instalaci závislostí PHP zadáním composer install --no-dev v adresáři rozšíření. (Vyskytnou-li se nějaké komplikace, podívejte se na T173141.)Category:Extensions requiring Composer with git/cs
  • Na konec vašeho souboru LocalSettings.php přidejte následující kód:
    wfLoadExtension( 'ContentTranslation' );
    
  • Spusťte aktualizační skript, který automaticky provede všechny nezbytné databázové změny, jaké rozšíření vyžaduje.
  • Yes Dokončeno – Přejděte na stránku Special:Version vaší wiki a zkontrolujte, zda bylo rozšíření úspěšně nainstalováno.


Instalace Vagrant:

  • Pokud používáte Vagrant , instalujte s těmito parametry vagrant roles enable contenttranslation --provision

Content Translation server

Toto rozšíření vyžaduje funkční přístup na server Content Translation (např. cxserver). Pro nastavení se podívejte na stránku Content translation/cxserver/Setup pro Content Translation server. Pokud spouštíte Content Translation lokálně, musíte k LocalSettings.php přidat následující kód, abyste mohli využívat produkční cxserver:

$wgContentTranslationSiteTemplates['cx'] = 'https://cxserver.wikimedia.org/v1';

Databáze překladů

Toto rozšíření má volitelnou funkci dashboardu, která umožňuje překladatelům vidět všechny překlady do všech jazyků. Pro vícejazyčnou instalaci tohoto rozšíření (například ve wiki Wikimedie) je pro funkci dashboardu zapotřebí centrální databáze. Definice tabulky pro tuto databázi jsou v adresáři sql ve zdrojovém kódu rozšíření; Content translation/Product Definition/Database má více podrobností. Po vytvoření databáze nastavte globální proměnnou $wgContentTranslationDatabase jako název databáze:

$wgContentTranslationDatabase = 'db_name';

Závislosti tohoto rozšíření

Rozšíření ContentTranslation je závislé na následujících rozšířeních:

UniversalLanguageSelector Požadované
VisualEditor Požadované Je nezbytné pro editor.
Cite Požadované Je nutné, pokud chcete při překladu využívat reference na jiné jazykové mutace.
GuidedTour Volitelné Pokud je nainstalován, bude použit k zobrazení vysvětlení o přesunutí stránky z uživatelského prostoru.
Echo Volitelné Je-li nainstalováno, můžete využívat "poděkování" těm, kteří se kupř. podíleli na dotažení překladu do určité fáze.
Wikibase Volitelné Je-li nainstalováno a nakonfigurováno podobně jako na Wikipedii, pak můžete využívat automatické přidávání mezijazyčných odkazů (podobně jako je tomu u odkazů na jiné jazykové mutace Wikipedie).
EventLogging Volitelné Pokud je nainstalováno, můžete logovat nejenom čas publikace a případné chyby, ale i jiné události.
BetaFeatures Volitelné Je-li nainstalováno, ContentTranslation se objeví jako nastavitelný beta prvek v Nastavení.

Konfigurační proměnné

Category:Drafts

Úplný seznam a výchozí hodnoty najdete v extension.json ve zdrojovém úložišti.

ContentTranslationDomainCodeMapping
Used to map between non-standard language codes and actual domains. The default is the same as in Wikipedia codes and domains.
ContentTranslationRESTBase
Configuration of RESTBase URL and connection parameters. The defaults are for Wikipedia.
ContentTranslationDatabase
The name of the database in which the common tables for managing translations across wikis are stored. The default is null, which means that the default database is used.
ContentTranslationCluster
In a Wikipedia-like database configuration, the name of the cluster on which the database is hosted. The default is null, which means that the default cluster is used.
ContentTranslationEventLogging
Whether EventLogging is enabled. The default is false.
ContentTranslationHighMTCategory
A category to which pages that have a high level of machine translation are added upon publishing. The default is null.
ContentTranslationSiteTemplates
Templates for essential URLs. The defaults assume Wikipedia, so this variable must be configured differently for other sites. Where relevant, $1 is replaced by the language code, and $2 is replaced by the page title.
ContentTranslationTranslateInTarget
Whether to open Special:ContentTranslation in the target wiki when clicking the button in the entry point. The domain will be based on $wgContentTranslationSiteTemplates. The default is to open Special:ContentTranslation on the same wiki. (For Wikipedia this is set to true.)
ContentTranslationAsBetaFeature
Whether ContentTranslation is a beta feature.
ContentTranslationTargetNamespace
The default target namespace for published articles. The default is Main.
ContentTranslationCampaigns
Campaigns that are available in the URL as valid values for the campaign parameter in the URL. This allows automatic enabling of the beta feature and event logging.
ContentTranslationCXServerAuth
CXServer connection configuration.
ContentTranslationEnableSuggestions
Whether to use the suggestions tab and automatic suggestions. This needs the GapFinder API. This is false by default, but true in Wikipedia.
RecommendToolAPIURL
The URL for the GapFinder API, needed if ContentTranslationEnableSuggestions is true.

Parametry adresy URL

Překlad obsahu funguje hlavně na speciální stránce Special:ContentTranslation. Parametry URL jsou

  • page: název zdroje
  • targettitle: cílový název
  • from: zdrojový jazyk
  • to: cílového jazyka
  • campaign: název kampaně
    • Pokud na Wikimedia wiki není v uživatelském nastavení povolen překlad obsahu, budou fungovat pouze odkazy na předem definovanou kampaň. Kampaně jsou definovány v proměnné InitialiseSettings.php wmgContentTranslationCampaigns.

Příklad

Související odkazy

Category:Extensions used on Wikimedia/cs#ContentTranslation/cs Category:WYSIWYG extensions/cs Category:Localisation extensions/cs Category:Language Engineering/cs Category:Content Translation/cs
Category:All extensions/cs Category:BeforeCreateEchoEvent extensions/cs Category:BeforePageDisplay extensions/cs Category:ChangeTagsListActive extensions/cs Category:Content Translation/cs Category:ContributeCards extensions/cs Category:Drafts Category:EchoGetBundleRules extensions/cs Category:EditPage::showEditForm:initial extensions/cs Category:Extensions in Wikimedia version control/cs Category:Extensions requiring Composer with git/cs Category:Extensions supporting Composer/cs Category:Extensions used on Wikimedia/cs Category:Extensions with manual MediaWiki version Category:GPL licensed extensions/cs Category:GetBetaFeaturePreferences extensions/cs Category:GetPreferences extensions/cs Category:Language Engineering/cs Category:ListDefinedTags extensions/cs Category:LoadExtensionSchemaUpdates extensions/cs Category:Localisation extensions/cs Category:Page action extensions/cs Category:ResourceLoaderRegisterModules extensions/cs Category:SaveUserOptions extensions/cs Category:SectionTranslationBeforePublish extensions/cs Category:SkinAfterContent extensions/cs Category:SpecialContributionsBeforeMainOutput extensions/cs Category:Stable extensions/cs Category:User interface extensions/cs Category:WYSIWYG extensions/cs