Commit Graph

8612 Commits

Author SHA1 Message Date
hallgren f27d509075 Introducing GF.Text.Pretty for more concise pretty printers and GF.Infra.Location for modularity
GF.Text.Pretty provides the class Pretty and overloaded versions of the pretty
printing combinators in Text.PrettyPrint, allowing pretty printable values to
be used directly instead of first having to convert them to Doc with functions
like text, int, char and ppIdent. Some modules have been converted to use
GF.Text.Pretty, but not all. Precedences could be added to simplify the pretty
printers for terms and patterns.

GF.Infra.Location contains the types Location and L, factored out from
GF.Grammar.Grammar, and the class HasSourcePath. This allowed the import
of GF.Grammar.Grammar to be removed from GF.Infra.CheckM, making it more
like a pure library module.
2014-07-27 22:06:23 +00:00
Sergei Trofimovich b154361e24 gf.cabal: fix depend in --flags=-custom-binary case
Detected when building today:

Building gf-3.6...
Preprocessing library gf-3.6...

src/runtime/haskell/PGF/Internal.hs:17:8:
    Could not find module ‘Data.Binary.IEEE754’
    It is a member of the hidden package ‘data-binary-ieee754-0.4.4’.
    Perhaps you need to add ‘data-binary-ieee754’ to the build-depends in your .cabal file.
2014-07-25 14:41:11 +00:00
hallgren ea6aa6dc02 PGF service: expire PGFs from the cache when they have been unused for 24 hours
...to keep memory use down on the server.
2014-07-21 15:53:38 +00:00
hallgren 9ded33829a WebSetup.hs: include Chinese when building the Phrasebook 2014-07-21 15:48:49 +00:00
aarne b51e88810e DictionaryEng: removed some uses of the token "IRREG" but then stopped and added a comment; don't know what it is supposed to mean. Also changed who_N from "who" to "WHO" but again, don't know what who_N is supposed to mean. But it now creates hilarious translations of "who's who", treated as a statement about WHO... 2014-07-20 08:26:33 +00:00
aarne c6ca698101 contracted questions in TranslateEng: who's as a variant of who is etc. 2014-07-20 08:25:54 +00:00
aarne 78bd8f98a8 fixed a bug in PhonoIta.elision, which caused gluing of articles with nouns beginning with a vowel also when there was no apostrophe 2014-07-20 08:06:45 +00:00
aarne 423fa50994 Qiao's corrections in PhrasebookChi. This replaces the old, partial and low-quality version and is hence the first Chinese phrasebook version that can claim high quality. 2014-07-16 21:07:34 +00:00
hallgren 47e185679f src/server/gf-server.cabal: update dependencies 2014-07-15 12:00:51 +00:00
aarne fb9508b38e modified some explanations in app.html 2014-07-15 09:55:45 +00:00
aarne 17a9accf97 using reduplication in Chi indirect questions, as suggested by Qiao 2014-07-15 09:41:26 +00:00
john.j.camilleri d59749c914 PGF Web Service: include entire completion in full mode
When using full=yes in the web service 'complete' command,
you now get an additional field 'seq' with the longest possible completion.
So, given:

  lin
    f1 = ss "the" ;
    f2 = ss ("the red house" | "the real deal") ;

and trying to complete on input "th", you get:

    [
        {
            "from": "TestCnc",
            "brackets": {
                "cat": "_",
                "fid": 0,
                "index": 0,
                "fun": "_",
                "children": []
            },
            "text": "th",
            "completions": [
                {
                    "token": "the",
                    "funs": [
                        {
                            "fun": "f1",
                            "hyps": [],
                            "cat": "C",
                            "seq": "the"
                        },
                        {
                            "fun": "f2",
                            "hyps": [],
                            "cat": "C",
                            "seq": "the red house"
                        },
                        {
                            "fun": "f2",
                            "hyps": [],
                            "cat": "C",
                            "seq": "the real deal"
                        }
                    ]
                }
            ]
        }
    ]
2014-07-15 09:33:22 +00:00
john 747287055f PGF web service: Return additional completion info with 'full' flag
BETA! The 'complete' command now has a new flag 'full' which when set
returns additional info about completions.

Without 'full' flag (default):

[
    {
        "from": "PhrasebookEng",
        "brackets": {
            "cat": "_",
            "fid": 0,
            "index": 0,
            "fun": "_",
            "children": [
                {
                    "token": "the"
                }
            ]
        },
        "text": "su",
        "completions": [
            "supermarket",
            "suspect"
        ]
    }
]

With full=true or full=yes:

[
    {
        "from": "PhrasebookEng",
        "brackets": {
            "cat": "_",
            "fid": 0,
            "index": 0,
            "fun": "_",
            "children": [
                {
                    "token": "the"
                }
            ]
        },
        "text": "su",
        "completions": [
            {
                "token": "supermarket",
                "funs": [
                    {
                        "fid": 421,
                        "fun": "Supermarket",
                        "hyps": [],
                        "cat": "PlaceKind"
                    }
                ]
            },
            {
                "token": "suspect",
                "funs": [
                    {
                        "fid": 445,
                        "fun": "Suspect",
                        "hyps": [],
                        "cat": "Property"
                    }
                ]
            }
        ]
    }
]
2014-07-11 09:25:26 +00:00
kr.angelov 0138869499 implemented computing with abstract syntax trees. It passes all test cases except those that require def rules. The design is consistent with the STG virtual machine 2014-07-08 19:45:49 +00:00
kr.angelov b3397f8071 bugfix for the typechecker in the C runtime 2014-07-08 19:19:48 +00:00
kr.angelov 153479e991 an API for visitor patterns on abstract syntax trees from Python. This makes the embedded grammars especially pleasing 2014-07-06 23:48:51 +00:00
john ce9999c45d Maltese RG: small updates to dict 2014-07-06 23:23:58 +00:00
kr.angelov a794ec5c42 small fix for the embedded mode in Python 2014-07-06 19:55:08 +00:00
kr.angelov 7afbff6fa8 embedded mode for GF grammar in Python. Only generation for now 2014-07-06 19:49:17 +00:00
john ae193e6fb6 Maltese RG: simple change which makes things compilable again 2014-07-06 17:19:10 +00:00
aarne 205f4567fb making hard-wired questiong in PhrasebookChi type correct after addition of indirect questions 2014-07-05 08:34:22 +00:00
aarne 65a9709041 distinction between direct and indirect questions in Chi, to eliminate "ma" in indir questions 2014-07-05 08:33:45 +00:00
kr.angelov 40bfaff8ce filter out the leading +/* from the parser tree 2014-07-03 18:27:39 +00:00
kr.angelov dde3e1ee73 bugfix in the ParseTreeView 2014-07-03 18:09:34 +00:00
kr.angelov 71b82c88a3 scroll bars for the ParseTreeView 2014-07-03 13:42:26 +00:00
kr.angelov ba1e95dacb Visualization for parse trees on Android 2014-07-02 11:30:06 +00:00
kr.angelov 42dea944d9 added bracketedLinearize in the Java binding 2014-07-02 07:08:01 +00:00
kr.angelov 410b7c78ce fixed rare memory leak in the Java bindings 2014-07-02 07:06:51 +00:00
john.j.camilleri f189e91629 Add Nothing' to Maybe.gf, including warning 2014-07-02 06:37:27 +00:00
kr.angelov b9ffc8ac00 a few changes in the Nerc that I have forgoten to push 2014-07-01 17:32:25 +00:00
kr.angelov 3843f5505e fix warnings in the compilation of the Java binding 2014-07-01 17:31:29 +00:00
kr.angelov 2e5d12db06 remove some of the translations for clever_A in Bulgarian 2014-07-01 09:00:19 +00:00
kr.angelov 5ae0b8814e a number of adjectives in DictionaryBul 2014-07-01 08:57:05 +00:00
aarne 9fe068449b link to play store from app.html 2014-06-30 09:14:17 +00:00
john.j.camilleri 2542d04565 RGL browser: remove duplicates in API tab
For some reason I was scanning both Syntax and
Constructors, Cat, Structural, Combinators
even though the former imports all the latter...
2014-06-30 07:35:59 +00:00
hallgren 93ba5b7b37 minibar: include the grammar's last modification in the grammar info shown by the "i" button
Also bumped version number in gf.cabal to 3.6-darcs.
Also removed some unecessary use of CPP.
2014-06-24 13:59:09 +00:00
hallgren b429086b2f Adjust the release date on the home page 2014-06-23 13:33:38 +00:00
hallgren 18de8c3988 Final updates of the download page for the 3.6 release
+ Describe which features are included in the different binary packages.
+ Describe the new MINGW package.
2014-06-23 13:30:33 +00:00
hallgren 865e818ea9 Update web pages and bump version number to 3.6! 2014-06-21 18:29:29 +00:00
hallgren 2646c40549 doc/gf-developers.t2t: made the C run-time section a bit more informative 2014-06-23 13:28:10 +00:00
kr.angelov 1cf221634e added at_home_Adv in DictionaryBul 2014-06-23 07:28:51 +00:00
kr.angelov 23cdf3fe6f small fixes in DictionaryBul.gf 2014-06-23 07:18:28 +00:00
hallgren 7d945def61 release-3.6.t2t: just a couple of more fixes.
Sorry.
2014-06-21 18:25:52 +00:00
hallgren ca24be7d7c release-3.6.t2t: fix broken link 2014-06-21 18:17:00 +00:00
hallgren f0ca4e4387 release-3.6.t2t: fix a formatting problem 2014-06-21 18:12:47 +00:00
hallgren e8ceba35b0 debian/changelog: updated for the release of GF 3.6 2014-06-21 17:10:24 +00:00
hallgren 7645207e6b build-binary-dist.sh: include a ghc package configuration file
as an experiment
2014-06-21 16:32:10 +00:00
hallgren 7f1521dbc5 Polished and renamed release notes to release-3.6.t2t
Also added an example use of lookupmorpho to gf-web-api-examples.html.
2014-06-21 13:02:10 +00:00
hallgren 54d081a036 The --output-dir option now applies also to PGF files 2014-06-21 12:26:56 +00:00
hallgren eee9617036 Cloud service & apps: better error handling in wide coverage translation
The wide coverage demo apps now shows a "please wait" message while the grammar
is loading, and a red error message if the grammar is not found on the server.
The Simple Translation Tool also show red error messages if the grammar is not
found.
2014-06-20 18:39:28 +00:00