summaryrefslogtreecommitdiff
path: root/src/runtime/haskell/PGF/VisualizeTree.hs
AgeCommit message (Collapse)Author
2023-12-14visualize_dependencies (vd) now creates latex in landscape mode to show long ↵Aarne Ranta
trees better
2020-07-06an attempt to solve record extension overloading bug, commented out for the ↵aarneranta
moment
2020-05-05accepting gf-ud style abslabels in gf-core ; cnclabels TODOaarneranta
2019-11-13fixed a vd bug that sometimes erased the root labelaarneranta
2019-11-12fixed the problem with generating several roots in ud2gf. Now only the ↵aarneranta
leftmost word becomes ROOT, the others become dep - which can be eliminated by cnclabels. This works fine for e.g. English prepositional and particle verbs. But it does not work if the 'main' word is not the leftmost one
2019-03-20hiding morphological tags from Latex printing of dependency treesAarne Ranta
2019-01-07add CoNLLU as output format for gf2ud: merging issue (#24)Prasanth Kolachina
2019-01-07Merge pull request #24 from odanoburu/gf2ud-commentsPrasanth Kolachina
(gf2ud) add comments to CoNLL-U output
2018-12-20save the original concrete category in BracketedStringKrasimir Angelov
2018-12-19(gf2ud) add comments to CoNLL-U outputodanoburu
when debbuging labels, I find it useful to have comments saying what's the original sentence (lazy, I know) and the original tree (depending on the treebank, the trees can be similar). I know this is not the goal exactly, but UDv2 treebanks (http://universaldependencies.org/format.html) should always have a 'text =' comment, and a 'sent_id =' comment (which would be easy to implement too, but not that useful).
2018-12-18added the possibility to annotate features of syncat words, e.g. @"is" PresSg3Aarne Ranta
2018-12-18refactored cnc configfile parsing a bitAarne Ranta
2018-12-18Merge branch 'master' into masterAarne Ranta
2018-12-18morph. feat generation by ARPrasanth Kolachina
2018-12-18added morphological tags to UD tree output. Tags are give in ↵Aarne Ranta
CncConfiguration, e.g. @N Sg Pl. Default tag is Cat-offset, as defined for each Cat in pgf
2018-12-17allow comments in dependency configs and fix conll outputPrasanth Kolachina
2018-12-01dealing with ',' as syncategorematic tokenAarne Ranta
2018-11-28fixed a bug in the cnclabel formatAarne Ranta
2018-04-18Fixes for GHC 8.4.1 compatibilityThomas Hallgren
* In GHC 8.4.1, the operator <> has become a method of the Semigroup class and is exported from the Prelude. This is unfortunate, since <> is also exported from the standard library module Text.PrettyPrint, so in any module that defines a pretty printer, there is likely to be an ambiguity. This affects ~18 modules in GF. Solution: import Prelude hiding (<>) This works also in older versions of GHC, since GHC does't complain if you hide something that doesn't exists. * In GHC 8.4.1, Semigroup has become a superclass of Monoid. This means that anywhere you define an instance of the Monoid class you also have to define an instance in the Semigroup class. This affects Data.Binary.Builder in GF. Solution: conditionally define a Semigroup instance if compiling with base>=4.11 (ghc>=8.4.1)
2017-04-06separated syncat multiwords in dep tree generation ; added function ↵aarne
wildcards to concrete annotatations (see for instance english/LangEng.labels)
2017-04-06vd command now reads local concrete configurations to deal with syncat ↵aarne
words; TODO: dissolve clustered multiwords bound with +
2016-06-15added a default value in dependency visualization for cases using maximum, ↵aarne
to cover the case where the list of arcs is empty
2016-06-09PGF service & minibar: only show dependency diagrams if the labels are knownhallgren
+ The PGF service now reads and caches dependency label configuration files. + The grammar info returned by command=grammar has a new boolean field 'hasDependencyLabels' to indicate if dependency labels were found for the grammar. Also, command=deptree will now fail if no labels are present. + The minibar only shows word dependency trees if labels are present. + Also changed the type of getDepLabels from [String] -> Labels to String -> Labels, since all uses were in the form "getDepLabels . lines".
2016-06-08PGF.VisualizeTree: add white background in the SVG rendering of dependency treeshallgren
This makes them look the same as SVG produced by graphviz
2016-06-08PGF.VisualizeTree: add SVG renderering of word dependency treeshallgren
This was done by introducing an intermediate representation for the LaTeX pictures produced by the LaTeX renderer and providing a new backend that outputs SVG instead of LaTeX.
2016-06-03vd latex: some adjustments in heights and lengthsaarne
2016-06-02vd: arc heights now depend on number of arcs below rather than word distanceaarne
2016-05-26Add haddock documentation to PGF.graphvizDependencyTree and PGF.getDepLabelshallgren
They seemed very difficult to use without the documentation, since their types are not particularly self documenting. Also documented what the (Bool,Bool) argument to PGF.graphvizAbstractTree is for.
2016-05-23made the word length proportionate in dependency visualization, instead of ↵aarne
using the max length for every word
2015-11-23vd -conll2latex now converts conll to latex. Without going through GF trees, ↵aarne
but as a service to the dependency parser community.
2015-11-18reduced label size and optimized arc length in vd -output=latexaarne
2015-11-17latex visualization of dep trees: explained the program better and ↵aarne
eliminated most magic numbers
2015-11-17added -output=latex to visialize_dependencies. This generates more ↵aarne
familiar-looking output than the default graphviz, which can moreover be pasted into LaTeX documents. Some more work is needed to make long sentences look nice and fit on a page; a constant word length is now used to simplify computing the coordinates.
2015-11-05vp -showdep: as default label for the first (incl. only) argument, don't use ↵aarne
dep#0 but assume it is the head
2015-11-05improved documentation of vp -showdepaarne
2015-11-04dependency labels in parse trees now with the -deps flag, -file=labels_file ↵aarne
for configuration. With -nocat option this shows reasonable dep trees, more familiar looking than the vd command. With -showfun flag, the tree gives a rather complete picture of the analysis of the sentence.
2015-11-04prepared visualize_parse for showing dependency labelsaarne
2015-07-16added a space after the tag in word alignment to work around a graphviz bug ↵aarne
shown with Chinese characters
2013-11-05Eliminate mutual dependencies between the GF compiler and the PGF libraryhallgren
+ References to modules under src/compiler have been eliminated from the PGF library (under src/runtime/haskell). Only two functions had to be moved (from GF.Data.Utilities to PGF.Utilities) to make this possible, other apparent dependencies turned out to be vacuous. + In gf.cabal, the GF executable no longer directly depends on the PGF library source directory, but only on the exposed library modules. This means that there is less duplication in gf.cabal and that the 30 modules in the PGF library will no longer be compiled twice while building GF. To make this possible, additional PGF library modules have been exposed, even though they should probably be considered for internal use only. They could be collected in a PGF.Internal module, or marked as "unstable", to make this explicit. + Also, by using the -fwarn-unused-imports flag, ~220 redundant imports were found and removed, reducing the total number of imports by ~15%.
2013-10-30linref is now used by the linearizer. The visible change is that the 'l' ↵kr.angelov
command in the shell now can linearize discontinuous phrases
2013-05-03[haskell runtime] Remove trailing whitespaces in VisualizeTree.hsgregoire.detrez
2013-04-21reverse the direction of the arcs in the dependency treeskr.angelov
2013-04-19remove the dead code left behind by Peter Ljunglöf in VisualizeTreekr.angelov
2013-04-16added a malt_tab format to the vd command in the GF shellkr.angelov
2013-04-16the generation of dependency trees in the Haskell runtime is now finally ↵kr.angelov
working with bracketed strings. This also fixes some errors in the old implementation
2012-11-22PGFService.hs: fix type error caused by change to PGF.graphvizParseTreehallgren
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-22better visualization of parse treespeter.ljunglof
2012-03-18PGF run-time library: function names in BracketedString (experimental)hallgren
+ Make room for function names in the BracketedString data structure. + Fill in function names when linearizing an abstract syntax tree to a BracketedString. + Fill in wildCId when it is not obvious what the function is. + Function bracketedLinearize: for compatibility with the other linearization functions, return Leaf "" instead of error "cannot linearize". + Export flattenBracketedString from module PGF. + PGFServce: make function names available in the JSON representation of BracketedString.
2011-12-08Now graphvizAbstractTree suppress the visualization of implicit arguments.kr.angelov
2010-12-06simple refactoring in PGF.Macros and relatedkrasimir