| View previous topic :: View next topic |
| Author |
Message |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Thu Mar 08, 2007 9:15 pm Post subject: BabelFishTranslator.tcl (current version: 1.12) |
|
|
Uses BabelFish to translate words or sentences from/to english.
(french version does the same from/to french)
Allowed languages can be easily modified according to BabelFish available languages.
eg.:
| Quote: | <nick> !translate en-fr this is a test
<bot> Translation: ceci est un test |
You can download the latest version here until it has been added to the Tcl archive :
BabelFishTranslator.tcl v1.12 (english version)
BabelFishTranslator.tcl v1.12 (french version)
please leave comments / bug reports here
Last edited by MenzAgitat on Tue Jul 08, 2008 7:08 am; edited 8 times in total |
|
| Back to top |
|
 |
raktivist Voice
Joined: 22 Nov 2005 Posts: 15
|
Posted: Fri Mar 09, 2007 11:14 pm Post subject: |
|
|
'i edited mine to this.. to reflect correct 'help' notice.
pardon me but i don't know anything about scripting but i figured i edit that line as it was incorrect info! other than that! very neat script u got here!
| Code: | putserv "NOTICE $nick :\037Available languages:\037"
putserv "NOTICE $nick :\002fr-en\002 —— French/English"
putserv "NOTICE $nick :\002de-en\002 —— German/English"
putserv "NOTICE $nick :\002nl-en\002 —— Dutch/English"
putserv "NOTICE $nick :\002it-en\002 —— Italian/English"
putserv "NOTICE $nick :\002pt-en\002 —— Portuguese/English"
putserv "NOTICE $nick :\002es-en\002 —— Spanish/English"
putserv "NOTICE $nick :\002en-fr\002 —— English/French"
putserv "NOTICE $nick :\002en-de\002 —— English/German"
putserv "NOTICE $nick :\002en-nl\002 —— English/Dutch"
putserv "NOTICE $nick :\002en-it\002 —— English/Italian"
putserv "NOTICE $nick :\002en-pt\002 —— English/Portuguese"
putserv "NOTICE $nick :\002en-es\002 —— English/Spanish" |
|
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Sat Mar 10, 2007 8:34 am Post subject: |
|
|
Oops, you are right.
I am a french guy and the script was originally written for that language.
When I translated it for english-speaking users, I apparently forgot some details in the online help
Thank you for having noticed that, here is the fixed version : BabelFishTranslator
Note: The french version does not have this issue, so the latest french version is still v1.0 |
|
| Back to top |
|
 |
mabus Voice
Joined: 17 Jun 2005 Posts: 27
|
Posted: Sun Aug 12, 2007 12:01 pm Post subject: |
|
|
| How difficult would it be to add other languages to this? |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Mon Aug 13, 2007 9:06 am Post subject: |
|
|
It is very simple, as long as it is supported by babelfish.altavista.com.
Go take a look here and click on Sélectionnez les langues source et cible to see if it can be done.
Which languages do you want to add support for ? |
|
| Back to top |
|
 |
mabus Voice
Joined: 17 Jun 2005 Posts: 27
|
Posted: Mon Aug 13, 2007 10:12 am Post subject: |
|
|
| A couple of my channel members speak russian and have been asking me try to find something to help them out. Though of course, the more languages it could incorporate the better. |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Tue Aug 14, 2007 7:44 am Post subject: |
|
|
Languages using specific charsets are a little bit problematic, I need a complete conversion table including russian characters for the Url construction procedure.
Look for this in BabelFishTranslator.tcl :
| Code: | ##### URL construction
set text [string map {
....
|
Should someone find that for me, I could add russian support. |
|
| Back to top |
|
 |
mabus Voice
Joined: 17 Jun 2005 Posts: 27
|
Posted: Tue Aug 14, 2007 5:55 pm Post subject: |
|
|
| hmmm, I see the "string map" in the script. What exactly would you need to be found ... specifically? |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Thu Aug 16, 2007 6:50 am Post subject: |
|
|
I need a conversion table for russian specific characters -> hex values |
|
| Back to top |
|
 |
schizosmurf Voice

Joined: 12 Oct 2007 Posts: 15
|
Posted: Fri Oct 12, 2007 10:59 am Post subject: |
|
|
installed this script yesterday and it works perfectly. good job.
is there a way to make it work in private message also, and not just from public message
ex. /msg eggbot !translate en-es How are you today? |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Sat Oct 13, 2007 1:13 pm Post subject: |
|
|
Good idea, I'll also put the whole thing in a namespace to avoid possible conflicts.
Expect a new version very soon. |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Sat Oct 13, 2007 3:53 pm Post subject: |
|
|
New version available.
changelog:
v1.1
- It is now possible to do a request in private msg with the bot like this : | Code: | | /msg botname !translate en-fr This is a test |
- Integration in a namespace |
|
| Back to top |
|
 |
schizosmurf Voice

Joined: 12 Oct 2007 Posts: 15
|
Posted: Sat Oct 13, 2007 4:17 pm Post subject: |
|
|
works great. good job
dropped script into folder, restart bot, and tada!
thx for taking my suggestion and making it reality |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Fri Oct 26, 2007 2:03 pm Post subject: |
|
|
At the moment, there are only two versions of the script : english and french.
If some altruist guys would translate the whole script (including comments) into some other languages, I could add them in a multilingual package  |
|
| Back to top |
|
 |
MenzAgitat Op

Joined: 04 Jul 2006 Posts: 118 Location: France
|
Posted: Thu Dec 06, 2007 8:17 am Post subject: |
|
|
New version available : v1.11
- bug fix in the english version
- the help displays faster
You can find a working link to download it in the first post of this thread. |
|
| Back to top |
|
 |
|