Skip to content

Commit

Permalink
Move module-level documentation to rst files
Browse files Browse the repository at this point in the history
This is a huge commit but it's only documentation changes. The
module-level docstrings now only have a single line description (maybe
with a citation), and all other description goes in the docs/api/*.rst
files.
  • Loading branch information
goodmami committed Aug 14, 2019
1 parent 2d5c061 commit 03ee4db
Show file tree
Hide file tree
Showing 59 changed files with 1,454 additions and 1,392 deletions.
92 changes: 0 additions & 92 deletions delphin/codecs/dmrsjson.py
Expand Up @@ -2,98 +2,6 @@

"""
DMRS-JSON serialization and deserialization.
Example:
* *The new chef whose soup accidentally spilled quit and left.*
::
{
"top": 10008,
"index": 10009,
"nodes": [
{
"nodeid": 10000,
"predicate": "_the_q",
"lnk": {"from": 0, "to": 3}
},
{
"nodeid": 10001,
"predicate": "_new_a_1",
"sortinfo": {"SF": "prop", "TENSE": "untensed", "MOOD": "indicative", "PROG": "bool", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 4, "to": 7}
},
{
"nodeid": 10002,
"predicate": "_chef_n_1",
"sortinfo": {"PERS": "3", "NUM": "sg", "IND": "+", "cvarsort": "x"},
"lnk": {"from": 8, "to": 12}
},
{
"nodeid": 10003,
"predicate": "def_explicit_q",
"lnk": {"from": 13, "to": 18}
},
{
"nodeid": 10004,
"predicate": "poss",
"sortinfo": {"SF": "prop", "TENSE": "untensed", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 13, "to": 18}
},
{
"nodeid": 10005,
"predicate": "_soup_n_1",
"sortinfo": {"PERS": "3", "NUM": "sg", "cvarsort": "x"},
"lnk": {"from": 19, "to": 23}
},
{
"nodeid": 10006,
"predicate": "_accidental_a_1",
"sortinfo": {"SF": "prop", "TENSE": "untensed", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 24, "to": 36}
},
{
"nodeid": 10007,
"predicate": "_spill_v_1",
"sortinfo": {"SF": "prop", "TENSE": "past", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 37, "to": 44}
},
{
"nodeid": 10008,
"predicate": "_quit_v_1",
"sortinfo": {"SF": "prop", "TENSE": "past", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 45, "to": 49}
},
{
"nodeid": 10009,
"predicate": "_and_c",
"sortinfo": {"SF": "prop", "TENSE": "past", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 50, "to": 53}
},
{
"nodeid": 10010,
"predicate": "_leave_v_1",
"sortinfo": {"SF": "prop", "TENSE": "past", "MOOD": "indicative", "PROG": "-", "PERF": "-", "cvarsort": "e"},
"lnk": {"from": 54, "to": 59}
}
],
"links": [
{"from": 10000, "to": 10002, "rargname": "RSTR", "post": "H"},
{"from": 10001, "to": 10002, "rargname": "ARG1", "post": "EQ"},
{"from": 10003, "to": 10005, "rargname": "RSTR", "post": "H"},
{"from": 10004, "to": 10005, "rargname": "ARG1", "post": "EQ"},
{"from": 10004, "to": 10002, "rargname": "ARG2", "post": "NEQ"},
{"from": 10006, "to": 10007, "rargname": "ARG1", "post": "EQ"},
{"from": 10007, "to": 10005, "rargname": "ARG1", "post": "NEQ"},
{"from": 10008, "to": 10002, "rargname": "ARG1", "post": "NEQ"},
{"from": 10009, "to": 10008, "rargname": "ARG1", "post": "EQ"},
{"from": 10009, "to": 10010, "rargname": "ARG2", "post": "EQ"},
{"from": 10010, "to": 10002, "rargname": "ARG1", "post": "NEQ"},
{"from": 10007, "to": 10002, "rargname": "MOD", "post": "EQ"},
{"from": 10010, "to": 10008, "rargname": "MOD", "post": "EQ"}
]
}
"""

from pathlib import Path
Expand Down
81 changes: 0 additions & 81 deletions delphin/codecs/dmrspenman.py
Expand Up @@ -2,87 +2,6 @@

"""
DMRS-PENMAN serialization and deserialization.
Example:
* *The new chef whose soup accidentally spilled quit and left.*
::
(e9 / _quit_v_1
:lnk "<45:49>"
:cvarsort e
:sf prop
:tense past
:mood indicative
:prog -
:perf -
:ARG1-NEQ (x3 / _chef_n_1
:lnk "<8:12>"
:cvarsort x
:pers 3
:num sg
:ind +
:RSTR-H-of (q1 / _the_q
:lnk "<0:3>")
:ARG1-EQ-of (e2 / _new_a_1
:lnk "<4:7>"
:cvarsort e
:sf prop
:tense untensed
:mood indicative
:prog bool
:perf -)
:ARG2-NEQ-of (e5 / poss
:lnk "<13:18>"
:cvarsort e
:sf prop
:tense untensed
:mood indicative
:prog -
:perf -
:ARG1-EQ (x6 / _soup_n_1
:lnk "<19:23>"
:cvarsort x
:pers 3
:num sg
:RSTR-H-of (q4 / def_explicit_q
:lnk "<13:18>")))
:MOD-EQ-of (e8 / _spill_v_1
:lnk "<37:44>"
:cvarsort e
:sf prop
:tense past
:mood indicative
:prog -
:perf -
:ARG1-NEQ x6
:ARG1-EQ-of (e7 / _accidental_a_1
:lnk "<24:36>"
:cvarsort e
:sf prop
:tense untensed
:mood indicative
:prog -
:perf -)))
:ARG1-EQ-of (e10 / _and_c
:lnk "<50:53>"
:cvarsort e
:sf prop
:tense past
:mood indicative
:prog -
:perf -
:ARG2-EQ (e11 / _leave_v_1
:lnk "<54:59>"
:cvarsort e
:sf prop
:tense past
:mood indicative
:prog -
:perf -
:ARG1-NEQ x3
:MOD-EQ e9)))
"""

from pathlib import Path
Expand Down
105 changes: 0 additions & 105 deletions delphin/codecs/dmrx.py
Expand Up @@ -2,111 +2,6 @@

"""
DMRX (XML for DMRS) serialization and deserialization.
Example:
* *The new chef whose soup accidentally spilled quit and left.*
::
<dmrs cfrom="-1" cto="-1" index="10009" top="10008">
<node cfrom="0" cto="3" nodeid="10000">
<realpred lemma="the" pos="q" />
<sortinfo />
</node>
<node cfrom="4" cto="7" nodeid="10001">
<realpred lemma="new" pos="a" sense="1" />
<sortinfo MOOD="indicative" PERF="-" PROG="bool" SF="prop" TENSE="untensed" cvarsort="e" />
</node>
<node cfrom="8" cto="12" nodeid="10002">
<realpred lemma="chef" pos="n" sense="1" />
<sortinfo IND="+" NUM="sg" PERS="3" cvarsort="x" />
</node>
<node cfrom="13" cto="18" nodeid="10003">
<gpred>def_explicit_q</gpred>
<sortinfo />
</node>
<node cfrom="13" cto="18" nodeid="10004">
<gpred>poss</gpred>
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="untensed" cvarsort="e" />
</node>
<node cfrom="19" cto="23" nodeid="10005">
<realpred lemma="soup" pos="n" sense="1" />
<sortinfo NUM="sg" PERS="3" cvarsort="x" />
</node>
<node cfrom="24" cto="36" nodeid="10006">
<realpred lemma="accidental" pos="a" sense="1" />
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="untensed" cvarsort="e" />
</node>
<node cfrom="37" cto="44" nodeid="10007">
<realpred lemma="spill" pos="v" sense="1" />
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="past" cvarsort="e" />
</node>
<node cfrom="45" cto="49" nodeid="10008">
<realpred lemma="quit" pos="v" sense="1" />
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="past" cvarsort="e" />
</node>
<node cfrom="50" cto="53" nodeid="10009">
<realpred lemma="and" pos="c" />
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="past" cvarsort="e" />
</node>
<node cfrom="54" cto="59" nodeid="10010">
<realpred lemma="leave" pos="v" sense="1" />
<sortinfo MOOD="indicative" PERF="-" PROG="-" SF="prop" TENSE="past" cvarsort="e" />
</node>
<link from="10000" to="10002">
<rargname>RSTR</rargname>
<post>H</post>
</link>
<link from="10001" to="10002">
<rargname>ARG1</rargname>
<post>EQ</post>
</link>
<link from="10003" to="10005">
<rargname>RSTR</rargname>
<post>H</post>
</link>
<link from="10004" to="10005">
<rargname>ARG1</rargname>
<post>EQ</post>
</link>
<link from="10004" to="10002">
<rargname>ARG2</rargname>
<post>NEQ</post>
</link>
<link from="10006" to="10007">
<rargname>ARG1</rargname>
<post>EQ</post>
</link>
<link from="10007" to="10005">
<rargname>ARG1</rargname>
<post>NEQ</post>
</link>
<link from="10008" to="10002">
<rargname>ARG1</rargname>
<post>NEQ</post>
</link>
<link from="10009" to="10008">
<rargname>ARG1</rargname>
<post>EQ</post>
</link>
<link from="10009" to="10010">
<rargname>ARG2</rargname>
<post>EQ</post>
</link>
<link from="10010" to="10002">
<rargname>ARG1</rargname>
<post>NEQ</post>
</link>
<link from="10007" to="10002">
<rargname>MOD</rargname>
<post>EQ</post>
</link>
<link from="10010" to="10008">
<rargname>MOD</rargname>
<post>EQ</post>
</link>
</dmrs>
"""

from pathlib import Path
Expand Down
20 changes: 0 additions & 20 deletions delphin/codecs/eds.py
Expand Up @@ -2,26 +2,6 @@

"""
Serialization functions for the "native" EDS format.
Example:
* *The new chef whose soup accidentally spilled quit and left.*
::
{e18:
_1:_the_q<0:3>[BV x3]
e8:_new_a_1<4:7>{e SF prop, TENSE untensed, MOOD indicative, PROG bool, PERF -}[ARG1 x3]
x3:_chef_n_1<8:12>{x PERS 3, NUM sg, IND +}[]
_2:def_explicit_q<13:18>[BV x10]
e14:poss<13:18>{e SF prop, TENSE untensed, MOOD indicative, PROG -, PERF -}[ARG1 x10, ARG2 x3]
x10:_soup_n_1<19:23>{x PERS 3, NUM sg}[]
e15:_accidental_a_1<24:36>{e SF prop, TENSE untensed, MOOD indicative, PROG -, PERF -}[ARG1 e16]
e16:_spill_v_1<37:44>{e SF prop, TENSE past, MOOD indicative, PROG -, PERF -}[ARG1 x10]
e18:_quit_v_1<45:49>{e SF prop, TENSE past, MOOD indicative, PROG -, PERF -}[ARG1 x3]
e2:_and_c<50:53>{e SF prop, TENSE past, MOOD indicative, PROG -, PERF -}[ARG1 e18, ARG2 e20]
e20:_leave_v_1<54:59>{e SF prop, TENSE past, MOOD indicative, PROG -, PERF -}[ARG1 x3]
}
"""

from pathlib import Path
Expand Down

0 comments on commit 03ee4db

Please sign in to comment.