1
0
forked from GitHub/gf-core
Commit Graph

7922 Commits

Author SHA1 Message Date
kr.angelov
b70cea2673 bugfix in the handling of BIND in the C runtime 2014-04-22 13:53:18 +00:00
hallgren
a2c25e88d4 gf.cabal: add GF builtin default -K64M. Enable parallel compile with ghc>=7.8
+ Programs compiled with ghc<7.8 have a default built-in 8M stack size limit.
  With ghc>7.0 this built-in default can be changed, so it is now 64M, allowing
  GF to work with larger grammars without manually increasing the stack size.
  (But if GF is compiled with ghc 6.12, the built-in default is still 8M.)

+ Enable ghc>=7.8 support for compiling modules in parallel, to speed up the
  compilation of GF.
2014-04-22 12:43:24 +00:00
kr.angelov
5847f8e18f fix in the renaming 2014-04-22 11:55:22 +00:00
kr.angelov
c032781095 rename DGTranslator to Human Language Compiler. Added a new logo 2014-04-22 11:53:16 +00:00
aarne
d3020a2f19 a copy of app help file as demos/app.html 2014-04-21 08:45:32 +00:00
aarne
7340400758 some edits in app help 2014-04-21 08:40:38 +00:00
hallgren
0e21bcde22 Wide Coverage Demo web app: more client side caching
For example, you can now reorder paragraphs by cut & paste, without causing
anything to be sent to the server for re-translation.

Also some color & layout tweaks.
2014-04-17 13:48:00 +00:00
kr.angelov
b0b27a1b32 now word completion from Java works. It could be made better 2014-04-17 11:00:27 +00:00
hallgren
5cb5cdd31e Wide Coverage Demo App: show a word-for-word translation if all else fails 2014-04-16 15:37:09 +00:00
hallgren
dd96c8a2c6 PGF web API: adding the command c-wordforword
It has the same parameters and result format as c-translate, but it does
the translation word for word. (To be used as a last resort).
2014-04-16 15:24:23 +00:00
aarne
1bc77326e2 edits in App help ; name suggestion "Language Compiler" ; sepApo(), a quick fix to French and Italian elision in the App 2014-04-15 22:02:06 +00:00
aarne
fbcb5e1957 removed clash in AppFin imports 2014-04-15 21:26:33 +00:00
hallgren
7fc3627c6e PGF web API: add commands lookupmorpho and c-lookupmorpho 2014-04-15 14:50:38 +00:00
hallgren
2ea326a83e gftranslate.js: switch to Translate11.pgf 2014-04-11 20:08:12 +00:00
aarne
d8f15af8f0 Dut added to android Translator.java 2014-04-11 19:47:50 +00:00
aarne
3740a30f05 App11.pgf in Makefile 2014-04-11 18:56:59 +00:00
hallgren
ba825ae81a Wide Coverage Demo App (gftranslate.js): use a special lexer for Chinese. 2014-04-11 18:39:12 +00:00
hallgren
6601a3972e Simple Translator: use colors to indicate translation quality 2014-04-11 15:00:15 +00:00
aarne
aca589d872 experimental AppDut added 2014-04-11 07:49:34 +00:00
kr.angelov
7c3d97e72a named entities in the Android App 2014-04-11 12:56:31 +00:00
hallgren
ea389df58e Simple Translator: Use PGF API for (un)lexing instead of separate server calls
Also,

  + Get up to 10 (instead of 5) alternative robust translations.
  + Remove duplicates from list of alternative robust translations
  + Add GF Cloud logo to the simple translator page
2014-04-11 12:10:05 +00:00
kr.angelov
f72fe45c32 forgoten Completer.java 2014-04-11 07:52:10 +00:00
kr.angelov
b82f9a5035 expose Java API for word completion 2014-04-11 07:50:22 +00:00
kr.angelov
65b4ba2459 change the JVM version to 1.6 in JNI_OnLoad 2014-04-11 07:15:27 +00:00
kr.angelov
dbc8a6f579 bugfix in the Java binding 2014-04-10 16:43:40 +00:00
hallgren
4008a2b111 PGF web service: disable caching of parse results
Caching parse results uses a lot of memory, even if they expire after
2 minutes, so it won't scale up to many simultaneous users.

But some excessive memory use seems to be caused by space leaks in
(the Haskell binding to) the C run-time system, and these should be fixed.
For example, flushing the PGF cache does not release the memory allocated
by the C run-time system when loading a PGF file.
2014-04-10 15:55:33 +00:00
hallgren
5f75baf56a Wide Coverage Demo App: it now works ok without server caching of parse results 2014-04-10 15:50:34 +00:00
kr.angelov
1ca09448f9 now fully functional Java API for custom literals 2014-04-10 14:14:31 +00:00
kr.angelov
348c9c4233 bugfix in the C runtime 2014-04-10 07:42:49 +00:00
aarne
d7ef5d8c0b improved generation of BNC dictionaries ; now called TopDictionary for clarity 2014-04-10 13:07:05 +00:00
kr.angelov
d9f4c1598c a quick hack to enable the NERC from bindings. This should be made available from the API but for now I just hacked the C runtime 2014-04-10 07:27:07 +00:00
hallgren
d19e6d9d07 Wide Coverage Demo App: new buttons: to switch colors on/off & to try Google Translate 2014-04-09 20:51:31 +00:00
hallgren
402cccc3ca localstorage.js: bug fix
If you stored "false" and tried to retrieve it with a default value, you got
the default value instead of "false".
2014-04-09 20:49:53 +00:00
hallgren
96f36d8f0a Wide Coverage Demo App: use PGF service lexing/unlexing
It is now enough to make one server call per translation, and the results can
cached by the browser.
2014-04-09 19:49:45 +00:00
hallgren
d1da0e06de PGF web service: add unlexers and enable client side caching
Most PGF web API commands that produce linearizations now accept an
unlexer parameter. Possible values are "text", "code" and "mixed".

The web service now include Date and Last-Modified headers in the HTTP,
responses. This means that browsers can treat responses as static content and
cache them, so it becomes less critical to cache parse results in the server.

Also did some cleanup in PGFService.hs, e.g. removed a couple of functions
that can now be imported from PGF.Lexing instead.
2014-04-09 17:51:25 +00:00
hallgren
50ea3d265c Change the type of PGF.Lexing.bindTok to [String] -> [String]
The old type was [String] -> String. This function was only used
in GF.Text.Lexing.stringOp, which now uses (unwords . bindTok) instead,
with no change in behaviour.
2014-04-09 17:39:21 +00:00
hallgren
677d849840 Unlexers: move capitalization of first word from GF.Text.Lexing to PGF.Lexing
The capitalization of the first word was done in GF.Text.Lexing.stringOp,
but is now done in the functions unlexText and unlexMixed in PGF.Lexing.
These functions are only used in stringOp and in PGFService (where the change
is needed), so the subtle change in behaviour should not cause any bugs.
2014-04-09 17:26:23 +00:00
hallgren
04a6260eea PGF Service: a bit more clever lexer=text
Only change the first word to lowercase if the original input is not found in
the grammar's morphology. This allows parsing of sentenses starting with "I" in 
English, nouns in German and proper names in other languages, but it can make
the wrong choice for multi-words.
2014-04-09 14:13:18 +00:00
hallgren
4479bb81b7 Wide Coverage Demo App updates
+ Add Clear button.
+ Use localstorage to remember entered text between visits.
+ Add a link to it on the GF cloud service start page.
2014-04-09 13:59:35 +00:00
aarne
88cf84613e more passives in App. Import changes are now produced with MkApp.hs, which copies the exclude list from App.gf to the concrete syntax files. 2014-04-09 14:01:06 +00:00
aarne
a3921bffd7 rewrote App so that it just inherits Translate and excludes some functions. This minimizes the duplication of code between Translate and App. Also added some functions, which make App 15% slower but increase the coverage and quality. This trade-off has to be studied further. 2014-04-09 13:04:19 +00:00
hallgren
622ab0b44c Fix build problem in PGFService.hs when configured without c-runtime 2014-04-08 20:45:54 +00:00
hallgren
29efca71cb PGF web service: add lexer support
The PGF web API commands parse, translate, translategroup, c-parse and
c-translate now support a lexer parameter. Possible values are "text",
"code" and "mixed".

This is used in the Wide Coverage Demo App to save one server roundtrip.
2014-04-08 16:10:33 +00:00
aarne
44521edd2d small fixes in App grammar - don't affect performance 2014-04-08 16:14:05 +00:00
hallgren
9cac98a356 Move basic lexing functions from GF.Text.Lexing to the new module PGF.Lexing
They are thus part of the PGF Run-Time Library, making it possible to add
lexing functionality in PGF service in a natural way.
2014-04-08 14:07:49 +00:00
hallgren
936f3d8297 Wide Coverage Demo App: remove quality markers ("+" or "*") before unlexing
Otherwise the first word won't be capitalized.
2014-04-08 13:46:57 +00:00
kr.angelov
a90756aeda added preliminary API for custom literals from Java. Not functional yet 2014-04-08 13:54:49 +00:00
kr.angelov
f99d3033aa bugfix in the C runtime that shows up with only some grammars 2014-04-08 12:41:41 +00:00
hallgren
64623d4881 Wide Coverage Demo App: restore swap button 2014-04-08 11:32:54 +00:00
hallgren
c8a8883df8 demos/translation.t2t: more space for the demo app 2014-04-07 13:01:00 +00:00