Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update 40-3.cgel #29

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 57 additions & 1 deletion datasets/oneoff/40-3.cgel
Original file line number Diff line number Diff line change
@@ -1,4 +1,60 @@
# sent_id = 40-3
# text = This subsection does not prevent the payment of reasonable compensation to an officer in an amount approved by the board of directors.
# sent = this subsection does not prevent the payment of reasonable compensation to an officer in an amount approved by the board of directors
# tree_by = mebwells (YYYY-MM-DD)
# tree_by = mebwells (2024-08-12)
(Clause
:Subj (NP
:Det (DP
:Head (D :t "this"))
:Head (Nom
:Head (N :t "subsection")))
:Head (VP
:Head (VP
:Head (V_aux :t "does" :l "do" :xpos "VBZ")
:Mod (AdvP
:Head (Adv :t "not")))
:Comp (Clause
:Head (VP
:Head (V :t "prevent" :xpos "VB")
:Obj (NP
:Det (DP
:Head (D :t "the"))
:Head (Nom
:Head (Nom
:Head (N :t "payment")
:Comp (PP
:Head (P :t "of")
:Obj (NP
:Head (Nom
:Mod (AdjP
:Head (Adj :t "reasonable"))
:Head (N :t "compensation")))))
:Comp (PP
:Head (P :t "to")
:Obj (NP
:Det (DP
:Head (D :t "an"))
:Head (Nom
:Head (N :t "officer")
:Mod (PP
:Head (P :t "in")
:Obj (NP
:Det (DP
:Head (D :t "an"))
:Head (Nom
:Head (N :t "amount")
:Mod (Clause
:Head (VP
:Head (V :t "approved" :l "approve" :xpos "VBN")
:Comp (PP
:Head (P :t "by")
:Obj (NP
:Det (DP
:Head (D :t "the"))
:Head (Nom
:Head (N :t "board")
:Comp (PP
:Head (P :t "of")
:Obj (NP
:Head (Nom
:Head (N :t "directors" :p ".")))))))))))))))))))))
Binary file added datasets/oneoff/pdf/40-3.pdf
Binary file not shown.
124 changes: 124 additions & 0 deletions datasets/oneoff/tex/40-3.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@

\documentclass[tikz,border=12pt]{standalone}
\usepackage[linguistics]{forest}
\usepackage{times}
\usepackage{textcomp}
\usepackage{xcolor}
\usepackage{soul}
\usepackage[T1]{fontenc}
\usepackage{marvosym}

\definecolor{orange}{HTML}{FFCCFF}
\definecolor{ltyellow}{HTML}{FFFFAA}
\definecolor{cgelblue}{HTML}{009EE0}

% text highlight color
% https://tex.stackexchange.com/a/352959
\newcommand{\hlc}[2][yellow]{{%
\colorlet{foo}{#1}%
\sethlcolor{foo}\hl{#2}}%
}
\newcommand{\hlgreen}[2][green]{{%
\colorlet{foo}{#1}%
\sethlcolor{foo}\hl{#2}}%
}
\newcommand{\p}[1]{%
\sethlcolor{white}\color{gray}\hl{#1}%
}

\pagestyle{empty}
%----------------------------------------------------------------------
% Node labels in CGEL trees are defined with \Node,
% which is defined so that \Node{Abcd}{Xyz} yields
% a label with the function Abcd on the top, in small
% sanserif font, followed by a colon, and the category
% Xyz on the bottom.
\newcommand{\Node}[2]{\small\textsf{#1:}\\{#2}}
% For commonly used functions this is defined with \(function)
\newcommand{\Head}[1]{\Node{Head}{#1}}
\newcommand{\Subj}[1]{\Node{Subj}{#1}}
\newcommand{\Comp}[1]{\Node{Comp}{#1}}
\newcommand{\Mod}[1]{\Node{Mod}{#1}}
\newcommand{\Det}[1]{\Node{Det}{#1}}
\newcommand{\PredComp}[1]{\Node{PredComp}{#1}}
\newcommand{\Crd}[1]{\Node{Coordinate}{#1}}
\newcommand{\Mk}[1]{\Node{Marker}{#1}}
\newcommand{\Obj}[1]{\Node{Obj}{#1}}
\newcommand{\Sup}[1]{\Node{Supplement}{#1}}
\newcommand{\idx}[1]{\textsubscript{\fcolorbox{red}{white}{\textcolor{red}{#1}}}}
%----------------------------------------------------------------------
\begin{document}

% # sent_id = 40-3
% # text = This subsection does not prevent the payment of reasonable compensation to an officer in an amount approved by the board of directors.
% # sent = this subsection does not prevent the payment of reasonable compensation to an officer in an amount approved by the board of directors
% # tree_by = mebwells (2024-08-12)

\begin{forest}
where n children=0{% for each terminal node
font=\sffamily,
fill=ltyellow,
%tier=word % align at the "word" tier (bottom)
}{% % no false conditions, so empty
},
[Clause
[\Node{Subj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[this]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[subsection]]]]
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V\textsubscript{aux}},edge={line width=1pt}[does]]
[\Node{Mod}{AdvP}
[\Node{Head}{Adv},edge={line width=1pt}[not]]]]
[\Node{Comp}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V},edge={line width=1pt}[prevent]]
[\Node{Obj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[the]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[payment]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[of]]
[\Node{Obj}{NP}
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Mod}{AdjP}
[\Node{Head}{Adj},edge={line width=1pt}[reasonable]]]
[\Node{Head}{N},edge={line width=1pt}[compensation]]]]]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[to]]
[\Node{Obj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[an]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[officer]]
[\Node{Mod}{PP}
[\Node{Head}{P},edge={line width=1pt}[in]]
[\Node{Obj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[an]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[amount]]
[\Node{Mod}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V},edge={line width=1pt}[approved]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[by]]
[\Node{Obj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[the]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[board]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[of]]
[\Node{Obj}{NP}
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[directors,label={right:\p{.}}]]]]]]]]]]]]]]]]]]]]]]
\end{forest}


\end{document}