LojGloss (la tavycpi)

LojGloss (or la tavycpi in Lojban, meaning “the parrot”) is a javascript-based Lojban glosser and parser. LojGloss opens in an HTML page with a text area that you can paste or type Lojban text into. When you insert the text, it displays the text below the box as you typed it in, but with translations beneath the lojban words. It also displays translations of bridi places. Clicking on a word shows a box that displays the gloss, mnemonic, and definition. It also shows you how the phrases are grouped together, and lets choose how much detail to use in showing the structure.

If the word is actually a compound cmavo (i.e. a series of cmavo with no separating spaces) then LojGloss will parse it and show each cmavo in the definition box. If the word is a lujvo, then LojGloss will parse it into its rafsi and show the definitions for each of the constituent gismu.

The latest version is available (as of 2009-1) from my home server here. I’d prefer you use this one, but I’ll still provide a link to the old Windows version.

On Windows, the .NET framework 3.5 is required*. I’ve prepared a small utility you can run to see if you need to download it. If it tells you 2.0 or 3.0 aren’t installed, don’t worry—those are included in the 3.5 install. You’ll also need (due to some Microsoft brain-damage) to run this additional installer with files they should have put in the first. (Don’t worry, it’s just another megabyte!)

* The linked download is a small program that downloads the remaining required files. Depending on what you have already, it could be between 20 and 100 MB. If you don’t like those programs, further down that page is a full download, but it includes all of the 2.0 and 3.0 files, and is much larger than you need if you already have 2.0 or 3.0.

Download the files from here, and run pdf23ds.Lojgloss.exe to start Lojgloss.

Download the files from here, run the pdf23ds.PegParser.exe program, and open the htm page inside to use it.

Your firewall software might alert you that the program is trying to listen on a TCP port. This is normal—it’s how the HTM page communicates with the parser.

The program can also be run using Mono version 1.9 or higher, which supports Windows, Linux, OS X, and other platforms. If you’re using Mono on Linux, you might need to run mono pdf23ds.Lojgloss.Parser.exe instead of running the exe directly. I’m not sure if that’s necessary on OS X. You can run mono –version to see what version you have currently.

Note: Mono support is currently limited to the command line tool.

Known limitations

  1. A few rafsi are not yet glossed in lujvo because to do so correctly would require a different mechanism in the glosser that hasn’t yet been implemented.
  2. GUI doesn’t support Mono.
  3. The parser is kind of slow and memory intensive.

Planned features

In planned order of implementation:

  1. Further glossing improvements to match jbofi’e.
  2. Gloss tooltips?
  3. Add links to CLL sections dealing with the selected selma’o.
  4. Add an interface to the gloss database for making improvements or translations.
  5. Add an interface to give direct access to the parser output, with the ability to format that output in a variety of ways, including customized.
  6. Make parser much faster. (Switch to Rats! generated parser instead of own parser.)
  7. Make a server version by cross-compiling the C# to javascript.
  8. Integration of glossing database with Jbovlaste.
  9. GUI support on Mono? This will require features in Mono that will probably not be added until their 2.0 release or later, so I don’t really have much control over it.

Feel free to suggest new features.

Releases

2.0.2 (2008-7-3): Minor update. The program now detects when the 3.5 framework is not installed and displays a message instead of just not doing anything at all. Connectives are glossed as in jbofi’e now. Improve lujvo glossing a little.
2.0.1 (2008-6-28): Parse errors are now handled. The error information is shown in a tree with the affected text highlighted as you mouse over the different error nodes. The GUI now has tabs because you gotta have tabs. Mono support has been added for commandline tool. The overall speed of the parser has been improved quite a bit. A trace screen can be shown with extremely detailed information about the parse.
2.0 (2008-6-22): Rewrite client-side in C#. Add support for incremental parsing. Import all the jbofi’e glossing data and use most of it. Bridi place glossing complete except for some termsets. Mono support probably broken. You can save to/load from a file now, and there’s an auto-load for when you’re reading long works with lojgloss.
1.6 (2007-11-17): Make language structure able to be dynamically shown or hidden, and provide some keyboard and mouse support for navigating it.
1.5.3 (2007-11-14): Sumti place handling improved. Hopefully no bugs aside from the cmavo not handled. Lujvo glossing works again. Cmavo clusters with their own glosses in the wordlist are handled now.
1.5.2 (2007-11-14): Glossing was broken. Fix it. Improve zoi handling.
1.5.1 (2007-11-14): Fixed 1.5 gismu parsing. Add some basic, buggy sumti place handling.
1.5 (2007-11-13): Broken. (Gismu parsing doesn’t work. Hmm.) Fix lujvo and cmavo cluster parsing. Add support for Mono on Linux (and probably on OS X and Windows.)
1.4 (2007-11-13): Add very basic parsing support.
1.3 (2007-11-13): A bunch of fixes and enhancements and stuff.
1.1 (2006-8-12): Fix parsing of CVV-initial lujvo, make linebreaks format more nicely.
1.0 (2006-8-12): Initial release.


14 Responses to “LojGloss (la tavycpi)”

Michael Turniansky says:

Excellent product.. thanks.

Dave Cortesi says:

Downloaded to Linux (Ubuntu 7.10) after checking that the mono libraries were installed. However, it is not clear what to DO with it after downloading. The .exe file is of no use…

Downloaded to Windows (XP) and executed, but it quickly triggers an alert from my firewall that this application is trying to “act as a TCP/IP server” and open a port 85. Perhaps that’s something .NET does? But it looks suspicious. Don’t see any reason it should need to open a network port, and don’t know if I should allow this action or not.

pdf23ds says:

Dave, if you do a chmod +x on the executable, you’ll be able to execute it, but with version 1.4 Linux support is still broken.

The reason your firewall is alerting you is that the application runs an HTTP server that the HTML file accesses. The program does the parsing, and the HTM sends the Lojban text to the server to get back the parse tree.

pdf23ds says:

OK, Linux support is now available.

dave cortesi says:

Knowing the WINE project is a quite large & effortful attempt to provide a Windows API under Linux, I was dubious that pdf23*.exe would run under Linux, but I tried it. Here’s the result:

dcortesi@ubuntu:~/Desktop/lojgloss$ chmod +x pdf23ds.PegParser.exe

dcortesi@ubuntu:~/Desktop/lojgloss$ ./pdf23ds.PegParser.exe

bash: ./pdf23ds.PegParser.exe: cannot execute binary file

I will give it another try under Windows, allowing it to open a port. But I’d like to know how you go about testing under Linux without actually COMPILING under Linux…

pdf23ds says:

Do you have Mono installed? That’s required, and that’s what runs the executable. It doesn’t use Wine. If it won’t execute directly, does running “mono pdf23ds.PegParser.exe” work for you? If it does, I’ll modify my instructions accordingly. But for others on linux, they’ve been able to run it directly. I suspect you simply need to get Mono.

dave cortesi says:

Mono was there; after I downloaded the latest (11/14) version it executes with an explicit mono pdf… command.

pdf23ds says:

BTW, Dave, I had already heard from some people who had gotten it running under linux, so I assumed it would work for other people. There are always glitches, unfortunately, and I’m sorry you had to deal with them.

Shintyakov says:

I have a little success in running glosser under Linux.

Looks like glosser fails to open windows under Linux, but parsing and glossing server runs ok.

So, I did the following:
Runned parser in background
> ./runparser &

and opened lojgloss.htm in browser

> htmlview lojgloss.htm

And everything worked.

dave cortesi says:

Double-clicking pdf23ds.Lojgloss.exe in the 2.0.1 folder produces the “Application Error” message “The application failed to initialize properly (0xc0000135). Click on OK to terminate the application.”

dave cortesi says:

2.02 like 2.01 when executed only displays the message “The application failed to initialize properly (0xc0000135).”

Michael Turniaqnsky says:

Still not working. Downloaded net 3.5, ran pdf23ds.Lojgloss.exe, and getting “Scripts are not running on this page. That probably means you opened the .htm file instead of running pdf23ds.Lojgloss.exe. This page won’t do anything unless you run that program, sorry.”. Not helpful, since I AM running that program… Help?!

Colin says:

The program fails on my Windows XP x64 box with this exception:

System.TypeInitializationException: The type initializer for ‘pdf23ds.Lojgloss.Main’ threw an exception. —> System.BadImageFormatException: Could not load file or assembly ‘System.Data.SQLite, Version=1.0.49.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139′ or one of its dependencies. An attempt was made to load a program with an incorrect format.
File name: ‘System.Data.SQLite, Version=1.0.49.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139′
at pdf23ds.Lojgloss.Main..cctor()

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

— End of inner exception stack trace —
at pdf23ds.Lojgloss.Main..ctor()
at pdf23ds.Lojgloss.Program.Main2(String[] args)
at pdf23ds.Lojgloss.Program.Main(String[] args)

From what I can tell .NET 3.5 tries to load x64 libs while only x86 libs are supplied(and the program itself is MSIL bytecode???, so .NET only checks for native libs).
I did manag to get it running by getting the x64 System.Data.SQLite.dll 1.0.49, however.
I also get the ’scripts are not running’ message, perhaps because I have IE 6.0?

pdf23ds says:

Colin, it ought to work fine on IE6. x64, on the other hand, I can’t help you with. Probably you ought to try the web version of Lojgloss, which is more recent and more portable. If you still want to get the windows version working, could you e-mail me the log files you find underneath the Lojgloss directory?

Leave a Reply

To include an em dash, use three hypens with no surrounding spaces, or two with surrounding spaces.