Extension talk:Live Translate

From MediaWiki.org
Jump to: navigation, search
Start a new discussion

how do I change the location of the translate buttons

I hate the button on the top left when it screws up every first line. Can I put it the sidebar or in the site notice?

Tbrophy19473 (talk)19:51, 30 January 2014

Does the extension support Google Translate API v2?

According to Google FAQ, they discontinued Translate API v1 on 1st of December 2011 and replaced it with Translate API v2. Does Live Translate extension support this v2? I use Live Translate 1.2.3 alpha and MediaWiki 1.19, and cannot make the Google translation work, albeit words from local translation memories are being translated fine.

91.198.201.2811:03, 27 July 2012

IIRC the latest version is using v2 of the API.

Jeroen De Dauw (talk)22:45, 27 July 2012

Can anyone confirm that he has a working instance of Live Translate with Google API as of 3rd of August 2012? I've been trying to make the extension work for some time now, but no matter how carefully I follow the instructions, it won't be able produce any automated translation of any word that is not in the translation memory. Now I want to rule out that there have been any changes in the Google API infrastructure, and to confirm that the problem is in what I am doing.

I've tried to test some pieces of the JavaScript code of the extension, and found out that e.g. google.language.translate("Hello world!", "en", "de",callbackResult) responds with a JSON object {"status":{"code":403,"message":"Please use Translate v2. See http://code.google.com/apis/language/translate/overview.html"},"error":{"code":403,"message":"Please use Translate v2. See http://code.google.com/apis/language/translate/overview.html"},"translation":""}.

91.198.201.2810:54, 3 August 2012

I've wrote a JavaScript module that uses Google API v2 and emulates the behaviour of Google API v1. The extension works now with Google API v2. How do I submit my code?

Eraeshaes (talk)10:49, 8 August 2012

Maybe this page will help you:

Helder23:50, 9 August 2012

Uops, I just noticed the extension is not on Git, so I'll leave it to Jeroen to answer what is the best way.

Helder23:52, 9 August 2012
 
 
 
 
 

Does anyone have a working instance of the extension?

Can anyone confirm that he has a working instance of Live Translate with Google API as of August 2012? I've been trying to make the extension work for some time now, but no matter how carefully I follow the instructions, it won't be able produce any automated translation of any word that is not in the translation memory. I've also read through the source code of the extension, and it seems that it relies on older Google API architecture that is not there anymore (see my older post (91.198.201.28‎10:54, 3 August 2012) in the discussion "Does the extension support Google Translate API v2?".).

Now I want to find out whether the problem is in what I am doing, or it is because the extension is not working anymore. Can anyone confirm that he uses this extension with Google Translate API and it works?

91.198.201.2811:36, 7 August 2012

Timing out or not working

Cannot seem to get it to work :

I have installed the extension and have the translate button appear on my pages. When I click the translate button it takes a while before stopping with either nothing happening or timing out. I have tried with both google API and MS ID. At first it was just not doing anything. I clicked the translate button and then it would say show original. Now it times out.

My server details :

MediaWiki 1.18.1 PHP 5.2.17 MySQL 5.0.91-log

Thanks for any help in advance

Stampstudy (talk)21:03, 23 May 2012

I believe this is another case of what I have described in another topic here, see #Local translation memory OK, machine translation doesn't work. The symptomes are the same: long waiting time after pressing the button, then nothing happens. I've figured out that words from the local dictionaries are translated, but Google doesn't seem to receive any requests; at least, the statistics doesn't show anything.

91.198.201.2808:20, 24 May 2012

It does sound the same. I will try again when I have more time to setup a sandbox server. Translate would be a fantastic feature to have on my wiki. Let me know if you have any luck.

Stampstudy (talk)07:44, 8 June 2012

I've been testing this for some time now. I haven't yet managed to solve the problem, but I have some more input. Web Console window in my Firefox shows the following error when the page is loaded or after the "Translate" button is pressed: "google.language is undefined @ http://10.251.3.35/w19/load.php?debug=false&lang=en&modules=ext.livetranslate%7Cext.lt.google&skin=vector&version=20120730T065951Z&*:12". I wonder why google.language is not being loaded in spite of that "google.load("language", "1");" is the first instruction in ext.lt.google.js. What can be the reason?

91.198.201.2812:18, 30 July 2012
 
 

Exactly the same problem. Nothing happens.

In our case, the mediawiki is installed completely using spanish language (of course, the pages are in our language too). But we need to translate into english for our usa/uk students.

Maybe, we are all missing a step or making a missconfiguration, aren't we?

Can you help reviewing the steps/config_files?

Thanks!!

90.175.175.20610:32, 6 August 2012
 

Local translation memory OK, machine translation doesn't work.

I've created a new Google project and got a new API key for browser applications. I've installed the Live Translate extension and the settings in LocalSettings.php are following:

require_once( "$IP/extensions/LiveTranslate/LiveTranslate.php" );
$egLiveTranslateLanguages[] = 'nl';
$egLiveTranslateLanguages[] = 'de';
$egLiveTranslateService = LTS_GOOGLE;
$egGoogleApiKey = 'MY-GOOGLE-API-KEY-FOR-BROWSER-APPLICATIONS';

The words from my local translation memory are translated correctly, but the machine translation doesn't seem to work. When I press the "Translate" button, the words from the local translation memory are translated immediately, but the button remains "Translated..." for some time (up to a minute), and nothing happens. The statistics from the Google APIs Console doesn't indicate any translation requests. It seems that the extension does not reach the Google Translate API at all. I have double-checked, and the API key for browser applications is correct. What can be the reason?

Remark: When I use the version 1.2 and above, no "Translate" button appears anywhere, so I have to use 1.1.1. I don't know if this has anything to do with the problem described above.

91.198.201.2810:30, 14 May 2012

Um im newish to mediawiki and it wont install at all

this wont install and it keeps giving me a database error :/ can you please help me?

72.70.210.522:29, 12 February 2012

Could you provide us more deailed information? What is the error you are seeing? Which version of MediaWiki are you using?

Helder15:53, 13 February 2012
 

Did you run /maintenance/update.php as described in the installation instructions?

Jeroen De Dauw20:00, 13 February 2012

A database query syntax error has occurred. This may indicate a bug in the software. The last attempted database query was: (SQL query hidden) from within function "LiveTranslateFunctions::getLocalMemoryNames". Database returned error "1146: Table 'proje552_wiki.live_translate_memories' doesn't exist (localhost)"


thats my error

72.70.210.520:20, 13 February 2012

Did you run /maintenance/update.php as described in the installation instructions?

Looks like you did not.

Jeroen De Dauw14:04, 14 February 2012
 
 
 

Installation Error - Problem running update.php

I get the following error running update.php through the browser : Creating live_translate table... An error occured: Could not open "/LiveTranslate.sql".

Backtrace:

  1. 0 C:\Program Files\EasyPHP-5.3.8.1\www\wikibank\includes\installer\DatabaseUpdater.php(362):

Any idea ?

Thanks Thomas

2.136.82.18306:09, 31 January 2012

This seems to be an issue with your MW install loose from this extension. I suggest you ask on the wikitech mailing list.

Jeroen De Dauw18:49, 31 January 2012
 

Compatibility version 1.2 with mediawiki 1.17 issue

First of all, congratulate for this easy to use and very efficient extension.

My setup tests:

  • MW 1.16 with LiveTranslate 1.2 works
  • After upgrading to MW 1.17 with LiveTranslate 1.2 doesn't show up in the top right corner
    • My workaround, downgrade.. MW 1.17 with LiveTranslate 1.1.1 works just fine!
Eurodomenii13:41, 12 September 2011

Odd, it works for me with MW trunk. I did make some IE related fixes since the 1.2 release though, so if you're using Internet Explorer, that explains why it's not showing up for you. Is that the case?

I just released version 1.2.1 with these IE fixes, so that one will probably help you out.

Jeroen De Dauw14:40, 12 September 2011

I have tested in FF and Chrome, so this is not IE related in my case.

I have followed your advice and I have tested also with MW 1.19 alpha trunk and is still not working. Please test with MW 1.17 stable version, not trunk. Thank you!

Eurodomenii23:36, 12 September 2011

Did you get the new (1.2.1) release?

I just tested with MW 1.17 and even 1.16, and both work fine for me.

If 1.2.1 doesn't work for you, can you link to your wiki so I can have a look? If not, please list any non-standard things you have on your wiki that might be interfering with Live Translate.

Jeroen De Dauw02:08, 13 September 2011

Amazing quick and quality feedback from the developer... Fixed in version 1.2.2, Release note: Fixed script loading issue occuring when resource loader debugging is off. Jeroen, keep up the good work!

Eurodomenii22:29, 15 September 2011

I'm having this exact same issue with MediaWiki 1.17. Where can I download version 1.2.2? It hasn't been added to the download page yet.

BrettFerguson11:45, 24 October 2011
 
 
 
 
 

Publication of unedited machine translations

I assume that the purpose of this tool is to provide a draft translation in the language of the reader, to help the reader to understand the contents of the original, written in a different language.

The tool as it appears on the screenshots does not include any advice concerning the quality of the draft translation produced. There is nothing to explain that the translations produced are not reliable enough to be published, without being edited by someone who understands the languages of the translation and the source, and who preferably also has some knowledge of the subject matter of the source.

I am concerned that as it stands, this translate tool will encourage unsuspecting members of the public to publish translations on a wiki in languages which they do not understand themselves. This has already happened on some language versions of Wikipedia.

I propose that, as a minimum, there should be a warning attached to the tool to say that it should not be used to publish translations which have not been edited by a person who understands both languages.

By the way, the screenshots of the extension in use which have been produced are very useful in understanding the extension and in translating its interface on translatewiki.net. I notice that you do have a short description of the tool in the screenshot. However this has not been included in the messages to be translated at translatewiki.net. Is it intended to include this description as an integral part of the tool, and is the description to be localised on translatewiki.net?

Lloffiwr20:48, 7 January 2011

I agree, it might not be clear to some people that the result should be taken with a grain of salt, and that it would be helpful to have this documented. So by all means feel free to add this. Some optional notice in the extension itself would also be nice, but is not needed by my client (which is paying for the dev of this extension).

All messages used in the extension are internationalized AFAIK. The descriptions for the screenshots on the documentation page are not (just like the rest of the docs).

Jeroen De Dauw00:20, 8 January 2011

I am a translator at translatewiki.net, not a developer. When you mention adding to the documentation, I assume that means adding to the 'Extension:Live Translate' page here at MediaWiki. I'm happy to do that, when I get some time.

At translatewiki.net there are 9 messages to translate for this extension but the description starting 'Live translate is a simple extension that allows...' is not amongst them. Was that just an accidental omission? Isn't it part of the extension? Was being slow to understand here.

You mention the possibility of adding an optional message regarding the quality of the results. How do you suggest this could be displayed? - appearing permanently beneath the tool, only appearing when the tool is used, say above the translated text, inserted as an expandable note after the 'Translate' button? Are any of these possible from a technical point of view?

Lloffiwr09:44, 8 January 2011
When you mention adding to the documentation, I assume that means adding to the 'Extension:Live Translate' page

Yes, indeed.

How do you suggest this could be displayed? - appearing permanently beneath the tool, only appearing when the tool is used, say above the translated text, inserted as an expandable note after the 'Translate' button?

I think displaying a notice above the text after it's been translated should suffice.

Are any of these possible from a technical point of view? 

Sure, quite easy to implement actually. I'll just do that for the next version :)

Jeroen De Dauw12:39, 9 January 2011

Thank you for the prompt reply. With regard to the language of the notice to users, the most useful language for the notice is probably the language of the source. This covers the situation where someone, who speaks the language of the original only, ventures to use the live translate tool to publish in an unfamiliar language. However, for people who are using the tool to understand an original written in an unfamiliar language, this produces an untranslated notice at the top of the translated text, which again they don't understand. You might try producing the notice in both the language of the original and the translation.

This reminds me of the classic occasion where a Welsh translation was requested by e-mail to the translation department of a government organisation and the e-mail reply duly published. This transpired to be one of those automated response things which you can use when you are out of the office!

Do you want some input on composing the text of the notice?

Lloffiwr16:06, 9 January 2011
You might try producing the notice in both the language of the original and the translation. 

Sure, why not.

This reminds me of the classic occasion where a Welsh translation was requested by e-mail to the translation department of a government organisation and the e-mail reply duly published.

Heh :)

Do you want some input on composing the text of the notice? 

Sure.

I do get the impression you are a bit off on the usage of this extension though; it's not meant to publish translations. It's intended to be used on technical articles by people that can not read the language they are in, so they can understand what's written. Not to create a new page (or do any other form of publishing) with the translated text.

Jeroen De Dauw17:51, 9 January 2011
 
 
 
 
 

New feature: translation control location

feature suggestion: An option to change the location of where you want the translation controls. I think on my wiki it would work better at the top of the entire wiki, because I have a lot of diagrams/images and the controls are pushing them to the left.

173.55.64.9422:03, 27 December 2010

To quote myself from a blog post: "A cool new feature I’ve been considering, and might add at some point, is having __LIVETRANSLATE__ and __NOLIVETRANSLATE__ magic words, that allow per-page showing or hiding of the translation control. Yaron suggested also having a per-namespace setting."

So yes, I think this is a cool thing to have, and there is a good chance I'll implement it at some future point, especially if someone pays me to do it :)

Jeroen De Dauw13:53, 28 December 2010

FWIW, I'd love to see an option to put the widget in the sidebar. Great extension Jeroen! Jlerner 01:48, 25 January 2011 (UTC)

01:48, 25 January 2011
 

Excellent work on this extension.

Implemented on http://www.dexid.org and it works great!

I'd love to see a magic word option as well, as I'd likely disable it on the main page.

Cheers on a great job.

BrettFerguson13:39, 21 April 2011
 
 

The translator ignores the words in my dictionary

Hi, I installed this tool in my wiki. However, when I select a language to translate to, the words I have in my custom dictionary are ignored and are displayed in the original language. Any ideas what I did wrong?

I created a page in the wiki called Live Translate Dictionary and added the test words below.

en,sv,nl,de,no,fr people,personer,Personen,Personen,Personer issues,ärenden,test nl,test de,test no,test fr

213.115.136.1715:20, 24 March 2011

Can you please paste the words in a sane and readable format?

Jeroen De Dauw18:27, 24 March 2011

Sorry, didn't notice the strange format. The test words are as follows:
en, sv, nl, de, no, fr
people, personer, Personen, Personen, Personer
issues, ärenden, test nl, test de, test no, test fr

Source language is en, the rest the available translated languages.

I have the following ex installed already and I have not removed it. It seems Live Translate works fine anyway, apart from leaving the custom words untranslated.

http://www.mediawiki.org/wiki/Extension:Google_Translator

Thanks for a quick reply

Matt

80.216.84.5820:37, 24 March 2011

Do you have the dictionary page listed at Special:LiveTranslate with "live translate format" selected (like in this screenshot)?

If so, something is going wrong, and debugging is needed. Is your wiki publicly accessible? If so, please link to a page where the word replacing does not work. If not, you can have a look at your wiki database at table live_translate and see if the words are there or not.

Jeroen De Dauw21:41, 24 March 2011
 
 
 

Stand alone version

How would you accomplishing this on a stand alone system?

Dgennaro19:04, 24 January 2011

I'm guessing you are asking how you can use Google translate when not having internet access. Obviously you can't. The translation specified via Live Translate will work though. And if I'm not mistaken, Google has commercial products to handle such use cases, but that's really outside the scope of this extension.

Jeroen De Dauw22:33, 24 January 2011

Thank you for the feedback on this.

Dgennaro19:50, 9 February 2011
 
 

Unclear meaing of translatable messages

Hi, “livetranslate-special-location” and “Livetranslate-importtms-param-miscmatch” are not intuitively translatable considering the purpose of this extension. Perhaps it has something to do with the translation control location discussed in an other thread on this page, but I am not entirely sure. Cheers

[[kgh]]13:31, 11 January 2011

I'll document the messages. They have nothing to do with the translation control or it's location.

Jeroen De Dauw13:35, 11 January 2011

Cool, thank you! It is good that I have asked. Cheers

[[kgh]]15:32, 11 January 2011

I just committed the docs. Should show up on translatewiki next time they update from svn.

Jeroen De Dauw16:53, 11 January 2011

Affirmative :)

[[kgh]]21:26, 11 January 2011
 
 
 
 

Installation error

I get this error when trying to maintenance/update.php:

Catchable fatal error: Argument 1 passed to LiveTranslateHooks::onSchemaUpdate() must be an instance of DatabaseUpdater, none given in /public_html/wiki/extensions/LiveTranslate/LiveTranslate.hooks.php on line 130

Any suggestions?

-

What version of mediawiki are you using? --Jeroen

-

1.16.0, and here's the error when trying to reach the Wiki:

A database query syntax error has occurred. This may indicate a bug in the software. The last attempted database query was: (SQL query hidden) from within function "". Database returned error "1146: Table 'xxxxxxxx_wiki.live_translate' doesn't exist (localhost)". -- Blink

Blink15:57, 23 December 2010

I had a look at this, and it turned out to be a compatibility issue with MediaWiki 1.16 in the installation code. It's fixed on SVN trunk. Updating your code and running update.php again should fix the issue :)

Jeroen De Dauw15:58, 23 December 2010

thanks, it's working now =)

173.55.64.9418:38, 23 December 2010