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 id43005d93-f59a-11ee-8591-ff101ca1cce5_1_0.cgel #80

Open
wants to merge 2 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
69 changes: 68 additions & 1 deletion datasets/oneoff/id43005d93-f59a-11ee-8591-ff101ca1cce5_1_0.cgel
Original file line number Diff line number Diff line change
@@ -1,4 +1,71 @@
# sent_id = id43005d93-f59a-11ee-8591-ff101ca1cce5_1_0
# text = The Secretary shall establish an advisory committee to be known as the Advisory Committee on Minority Veterans (hereinafter in this section referred to as “the Committee”).
# sent = the Secretary shall establish an advisory committee to be known as the Advisory Committee on Minority Veterans hereinafter in this section referred to as the Committee
# tree_by = bwaldon (YYYY-MM-DD)
# tree_by = bwaldon (2024-11-15)
(Clause
:Subj (NP
:Det (DP
:Head (D :t "the"))
:Head (Nom
:Head (N :t "Secretary")))
:Head (VP
:Head (V_aux :t "shall" :xpos "MD")
:Comp (Clause
:Head (VP
:Head (V :t "establish" :xpos "VB")
:Obj (NP
:Det (DP
:Head (D :t "an"))
:Head (Nom
:Head (Nom
:Mod (AdjP
:Head (Adj :t "advisory"))
:Head (N :t "committee"))
:Mod (Clause
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

supplement maybe? it doesn't feel restrictive. but I'm not sure

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree — will update

:Head (VP
:Marker (Sdr :t "to")
:Head (VP
:Head (V_aux :t "be" :xpos "VB")
:Comp (Clause
:Head (VP
:Head (V :t "known" :l "know" :xpos "VBN")
:Comp (PP
:Head (P :t "as")
:PredComp (NP
:Det (DP
:Head (D :t "the"))
:Head (Nom
:Head (Nom
:Mod (Nom
:Head (N :t "Advisory"))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"advisory" above is an Adj (which I think makes more sense than N unless it is "an advisory")

:Head (N :t "Committee"))
:Mod (PP
:Head (P :t "on")
:Obj (NP
:Head (Nom
:Mod (Nom
:Head (N :t "Minority"))
:Head (N :t "Veterans" :l "veteran")))))
:Supplement (Clause
:Head (VP
:Mod (AdvP
:Head (Adv :p "(" :t "hereinafter"))
:Head (VP
:Mod (PP
:Head (P :t "in")
:Obj (NP
:Det (DP
:Head (D :t "this"))
:Head (Nom
:Head (N :t "section"))))
:Head (VP
:Head (V :t "referred" :l "refer" :xpos "VBN")
:Particle (PP
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comp

:Head (P :t "to"))
:Comp (PP
:Head (P :t "as")
:PredComp (NP
:Det (DP
:Head (D :p "``" :t "the"))
:Head (Nom
:Head (N :t "Committee" :p "''" :p ")" :p ".")))))))))))))))))))))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see there has been normalization of quotes relative to the input string, not sure if that was intentional

Binary file not shown.
135 changes: 135 additions & 0 deletions datasets/oneoff/tex/id43005d93-f59a-11ee-8591-ff101ca1cce5_1_0.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@

\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 = id43005d93-f59a-11ee-8591-ff101ca1cce5_1_0
% # text = The Secretary shall establish an advisory committee to be known as the Advisory Committee on Minority Veterans (hereinafter in this section referred to as “the Committee”).
% # sent = the Secretary shall establish an advisory committee to be known as the Advisory Committee on Minority Veterans hereinafter in this section referred to as the Committee
% # tree_by = bwaldon (2024-11-15)

\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}[the]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[Secretary]]]]
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V\textsubscript{aux}},edge={line width=1pt}[shall]]
[\Node{Comp}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V},edge={line width=1pt}[establish]]
[\Node{Obj}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[an]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Mod}{AdjP}
[\Node{Head}{Adj},edge={line width=1pt}[advisory]]]
[\Node{Head}{N},edge={line width=1pt}[committee]]]
[\Node{Mod}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Marker}{Sdr}[to]]
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V\textsubscript{aux}},edge={line width=1pt}[be]]
[\Node{Comp}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V},edge={line width=1pt}[known]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[as]]
[\Node{PredComp}{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{Mod}{Nom}
[\Node{Head}{N},edge={line width=1pt}[Advisory]]]
[\Node{Head}{N},edge={line width=1pt}[Committee]]]
[\Node{Mod}{PP}
[\Node{Head}{P},edge={line width=1pt}[on]]
[\Node{Obj}{NP}
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Mod}{Nom}
[\Node{Head}{N},edge={line width=1pt}[Minority]]]
[\Node{Head}{N},edge={line width=1pt}[Veterans]]]]]]
[\Node{Supplement}{Clause}
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Mod}{AdvP}
[\Node{Head}{Adv},edge={line width=1pt}[hereinafter,label={left:\p{(}}]]]
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Mod}{PP}
[\Node{Head}{P},edge={line width=1pt}[in]]
[\Node{Obj}{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}[section]]]]]
[\Node{Head}{VP},edge={line width=1pt}
[\Node{Head}{V},edge={line width=1pt}[referred]]
[\Node{Particle}{PP}
[\Node{Head}{P},edge={line width=1pt}[to]]]
[\Node{Comp}{PP}
[\Node{Head}{P},edge={line width=1pt}[as]]
[\Node{PredComp}{NP}
[\Node{Det}{DP}
[\Node{Head}{D},edge={line width=1pt}[X,phantom][the,label={left:\p{``}}][Y,phantom]]]
[\Node{Head}{Nom},edge={line width=1pt}
[\Node{Head}{N},edge={line width=1pt}[X,phantom][Committee,label={right:\p{'').}}][Y,phantom]]]]]]]]]]]]]]]]]]]]]]
\end{forest}


\end{document}