1
0
forked from GitHub/gf-core
Commit Graph

4876 Commits

Author SHA1 Message Date
john.j.camilleri
c94e34d4e4 Minibar: add show/hide functions 2012-11-23 08:08:13 +00:00
hallgren
24bf1f0d0e minibar: can now switch back to the minibar after switching to the syntax editor
This is done by including a lin_action when starting the syntax editor from
the minibar.
Also: added some minibar options in the syntax editor for consistency...
2012-11-22 16:42:39 +00:00
hallgren
db544b1cc9 PGFService.hs: fix type error caused by change to PGF.graphvizParseTree
Note that some of the graphviz functions have backwards incompatible changes
that might also affect other clients of the PGF run-time library.

Also added graphvizDefaults and export it together with GraphvizOptions from 
the PGF run-time library.
2012-11-22 15:27:16 +00:00
john.j.camilleri
bac6b7fe64 Syntax editor: can now load minibar (in-place) from a linearised tree 2012-11-22 12:45:20 +00:00
peter.ljunglof
486a510611 better visualization of parse trees 2012-11-22 08:50:37 +00:00
peter.ljunglof
eebae7591c Added C compilation notes for Mac OSX 2012-11-22 08:50:49 +00:00
hallgren
7bcf05e3e7 minibar: fix bug introduced in previous update
It could case JavaScript error

	ReferenceError: initial_grammar is not defined
2012-11-21 19:01:52 +00:00
hallgren
e7b14316dd minibar+syntax editor integration, work in progress 2
+ Transfer current astract syntax tree when activating the syntax editor
  from the minibar.
+ Add options to start the minibar with given input. You need to include
  the current grammar url, the current language and the input, like this:

    initial_grammar: "/grammars/Foods.pgf",
    initial: { from: "FoodsEng", input:["that","fish","is","fresh"]}

+ Fix a style sheet clash.
2012-11-21 17:13:21 +00:00
john.j.camilleri
381dc3900c Syntax editor: start with initial AST
Note that the argument has been renamed to initial.abstr
(Where abstr means an abstract syntax tree in string form, NOT an AST object)
2012-11-21 15:24:44 +00:00
hallgren
8bd58a0297 minibar+syntax editor integration, work in progress 2012-11-21 15:07:59 +00:00
john.j.camilleri
051b7b0d21 Syntax editor: start with initial grammar, startcat, to: languages 2012-11-21 11:22:35 +00:00
john.j.camilleri
0f59b25d8a support.js: elem() returns false when as is undefined 2012-11-21 11:13:46 +00:00
hallgren
29d8b182ab gfse: remove obsolete files 2012-11-20 15:31:31 +00:00
hallgren
2ee6211fe1 GF cloud: move gf-web-api-examples.html out of minibar directory 2012-11-20 15:18:05 +00:00
john.j.camilleri
3f88302035 Update gf.cabal to copy new common js files 2012-11-20 14:04:09 +00:00
john.j.camilleri
09c4f8410e Syntax editor: update to use common js files 2012-11-20 13:56:56 +00:00
hallgren
3eaeaed8fd GF cloud: move support.js and pgf_online.js
Created the folder js and moved minibar/support.js and minibar/pgf_online.js
there, to emphasize their status as app independent support libraries.

There are probably more files that should be moved here.

The cloud apps have been updated, externally hosted apps that link directly
to our server need to be updated too.
2012-11-20 12:56:48 +00:00
john.j.camilleri
27beb9a3f8 Syntax editor: random generation of trees (and subtrees!) 2012-11-20 09:36:50 +00:00
kr.angelov
5e3b23325e remove the duplicated definition of PgfProductionIdx in parser.c 2012-11-19 14:16:31 +00:00
john.j.camilleri
bbd81b5d65 Fix date of 2013 summer school on home page (it said 2011) 2012-11-19 10:58:09 +00:00
aarne
61276878f6 index: news on summer school and Chinese 2012-11-19 09:58:26 +00:00
hallgren
889d7db76d GF web service API examples: update examples of the browse command
Also some style tweaks.
2012-11-17 17:42:30 +00:00
hallgren
ca5b066588 PGF service: command=browse&format=json returns info on all cats and funs
The browse command used to have a required parameter id=... and it returned
info on the given identifier only. Now, if format=json, the id=... parameter
can be omitted to get info on all identifiers at the same time. The returned
JSON structure in this case is

        {cats:{...},funs:{...}}

where the inner objects contain one field per category and function,
respectively, in the same format as when you request info on one category or
function.
2012-11-17 14:22:30 +00:00
hallgren
73c78c8840 GF web service API examples: added the "abstrjson" command
It converts an abstract syntax tree (represented as a string) to a JSON
structure.
Also some HTML code cleanup.
2012-11-17 11:55:32 +00:00
john.j.camilleri
3e5dac8ed4 Syntax editor: work on importing AST as string (eg for generate random)
But it's still not complete. Need an efficient way of getting the cat info to accompany funs.
2012-11-16 14:35:37 +00:00
kr.angelov
954d7a7ff5 bugfix for the building of bottom-up filter in the C runtime 2012-11-16 13:27:15 +00:00
hallgren
7d616c01b4 new-comp: rewrite f (x|y) into (f x|f y)
With this change, all languages in molto/mgl/mixture except German and Polish
can be compiled.
2012-11-16 13:47:10 +00:00
john.j.camilleri
67ca0a1eae Syntax editor: select subset of available languages
Also added a basic readme file with a list of todo's
2012-11-16 09:33:55 +00:00
hallgren
225cebf121 Updated summer school links
You can now use the following links to refer to GF Summer School web pages:

- Latest summer school: http://school.grammaticalframework.org/
- 2009 summer school: http://school.grammaticalframework.org/2009
- 2011 summer school: http://school.grammaticalframework.org/2011
- 2013 summer school: http://school.grammaticalframework.org/2013

This is accomplished with DNS and web server configuration. No files have
been moved, so this does not break any existing links (except that
http://school.grammaticalframework.org/ now refers to the latest summer school
instead of the 2011 summer school).
2012-11-15 21:05:10 +00:00
hallgren
9a49825d55 download/release-3.4.t2t: starting to prepare for the next release of GF
Feel free to add to the release notes.
The file can be renamed if the next release will not be called GF 3.4.
2012-11-15 19:33:42 +00:00
john.j.camilleri
f815b2850b Syntax editor: jump to next hole in tree 2012-11-15 15:38:17 +00:00
john.j.camilleri
dc0f333fec Syntax editor: fix bug in Firefox, Seamonkey 2012-11-15 12:40:14 +00:00
hallgren
2cc39661d9 Add flag --document-root for user with gf --server
This can make it easier to test cloud service updates before installing them.
2012-11-14 13:52:45 +00:00
hallgren
595a69ba0c GF usage message fixes
Change the command name from gfc to gf in the usage message header.
Correct spelling of "overide" to "override" in -gf-lib-path description.
2012-11-14 13:49:10 +00:00
kr.angelov
5c52eaf0b7 revised heuristic in the statistical parser 2012-11-14 12:34:22 +00:00
john.j.camilleri
5c8c1f768f Add first demo of new syntax editor
As part of the GF cloud stuff, it can be accessed from
http://cloud.grammaticalframework.org/syntax-editor/editor.html
2012-11-13 15:14:49 +00:00
hallgren
27e675910a Adding a new experimental partial evalutator
GF.Compile.Compute.ConcreteNew + two new modules contain a new
partial evaluator intended to solve some performance problems with the old
partial evalutator in GF.Compile.Compute.ConcreteLazy. It has been around for
a while, but is now complete enough to compile the RGL and the Phrasebook.

The old partial evaluator is still used by default. The new one can be activated
in two ways:

  - by using the command line option -new-comp when invoking GF.
  - by using cabal configure -fnew-comp to make -new-comp the default. In this
    case you can also use the command line option -old-comp to revert to the old
    partial evaluator.

In the GF shell, the cc command uses the old evaluator regardless of -new-comp
for now, but you can use "cc -new ..." to invoke the new evaluator.

With -new-comp, computations happen in GF.Compile.GeneratePMCFG instead of
GF.Compile.Optimize. This is implemented by testing the flag optNewComp in
both modules, to omit calls to the old partial evaluator from GF.Compile.Optimize
and add calls to the new partial evaluator in GF.Compile.GeneratePMCFG.
This also means that -new-comp effectively implies -noexpand.

In GF.Compile.CheckGrammar, there is a check that restricted inheritance is used
correctly. However, when -noexpand is used, this check causes unexpected errors,
so it has been converted to generate warnings, for now.

-new-comp no longer enables the new type checker in
GF.Compile.Typeckeck.ConcreteNew.

The GF version number has been bumped to 3.3.10-darcs
2012-11-13 14:09:15 +00:00
kr.angelov
468464faca bugfix in the statistical parser 2012-11-13 09:48:23 +00:00
kr.angelov
d1044b202a two simple heuristics which speed up the statistical parser more than seven times. 2012-11-12 22:17:40 +00:00
kr.angelov
182e366f5d a simple refactoring in the statistical parser 2012-11-12 21:48:22 +00:00
kr.angelov
7ad4436502 more counters in the profiler for the statistical parser 2012-11-12 15:36:21 +00:00
kr.angelov
9b2487243e now we store the state instead of the offset for every continuation in the chart for the statistical parser 2012-11-12 14:04:52 +00:00
kr.angelov
c28056c4e5 in the statistical parser: move the outside probability from the parse items to their continuation. this makes the value slot shared between many items 2012-11-12 13:43:43 +00:00
kr.angelov
56f3ff8202 small refactoring in the C runtime 2012-11-12 13:05:35 +00:00
kr.angelov
cce22a7f7a use size_t consistently as the type for constituent indices in the C runtime 2012-11-12 12:51:27 +00:00
kr.angelov
6784a4c76e implemented gu_map_count in runtime/c/gu/map.c 2012-11-12 12:42:19 +00:00
hallgren
63093c32f3 Eliminate warnings about deprecated use of catch and try
This is also needed for compatibility with GHC 7.6.
2012-11-08 15:53:46 +00:00
hallgren
1c0429c322 GF.Grammar.PatternMatch: relax overly restrictive type signatures 2012-11-07 17:23:08 +00:00
hallgren
8e6c81fe5a Some changed/new utility functions
GF.Data.Utilities:  Rename mapFst to apFst, mapSnd to apSnd.
		    Add apBoth, mapFst, mapSnd, mapBoth.
GF.Data.Operations: Remove onSnd (same as apSnd)
2012-11-07 15:31:45 +00:00
hallgren
1dbf575a71 gf -server: make it possible to pass arbitrary flags/options to gf when compiling grammars
For example, you can add -optimize-pgf:

  http://localhost:41296/cloud?dir=...&command=remake&-optimize-pgf=&Foods2Eng.gf=&Foods2Swe.gf=
2012-11-06 15:29:38 +00:00