-
Notifications
You must be signed in to change notification settings - Fork 5
Add verbatim ord_text field to one-shot extraction schemas #487
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
Open
rajeee
wants to merge
2
commits into
main
Choose a base branch
from
quotes
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,7 +10,7 @@ | |
| "type": "array", | ||
| "items": { | ||
| "type": "object", | ||
| "required": ["feature", "value", "units", "section", "summary", "source"], | ||
| "required": ["feature", "value", "units", "section", "summary", "ord_text", "source"], | ||
| "additionalProperties": false, | ||
| "properties": { | ||
| "feature": { | ||
|
|
@@ -70,6 +70,10 @@ | |
| "description": "Short requirement summary using direct excerpts/quotes whenever possible. Include key conditions, exemptions, qualifiers, application scope (permit/well/aquifer), and explanation for selected value. Null when no requirement exists.", | ||
| "default": null | ||
| }, | ||
| "ord_text": { | ||
| "type": "string", | ||
| "description": "Copy-and-paste directly from the source document the first sentence corresponding to the requirement being extracted. For quantitative features, this is the full sentence from the source that contains the value being extracted; for qualitative features, this is the first full sentence of the source text that relates to the requirement being extracted. Unlike summary, reproduce this single contiguous sentence verbatim from the source, with no paraphrasing, normalization, ellipses, added context, or commentary. Must be a non-null, non-empty string." | ||
| }, | ||
| "source": { | ||
| "type": ["number", "null"], | ||
| "description": "Integer indicating the source index from which this information was pulled. If not applicable or unavailable, use null.", | ||
|
|
@@ -175,34 +179,39 @@ | |
| "value": true, | ||
| "units": null, | ||
| "section": "Rule 3.2 - Permit Required", | ||
| "summary": "'No person may drill a non-exempt well without first obtaining a permit from the District.' Exempt domestic wells are listed separately under Rule 3.5." | ||
| "summary": "'No person may drill a non-exempt well without first obtaining a permit from the District.' Exempt domestic wells are listed separately under Rule 3.5.", | ||
| "ord_text": "No person may drill a non-exempt well without first obtaining a permit from the District." | ||
| }, | ||
| { | ||
| "feature": "annual extraction limits", | ||
| "value": 2, | ||
| "units": "acre-feet/year", | ||
| "section": "Rule 8.1 - Production Limits", | ||
| "summary": "The district sets an explicit annual production cap of '2 acre-feet per acre per year' for this permit class; text also notes permit-specific adjustments by aquifer conditions." | ||
| "summary": "The district sets an explicit annual production cap of '2 acre-feet per acre per year' for this permit class; text also notes permit-specific adjustments by aquifer conditions.", | ||
| "ord_text": "Each non-exempt permit is limited to an annual production of 2 acre-feet per acre per year." | ||
| }, | ||
| { | ||
| "feature": "well spacing", | ||
| "value": 500, | ||
| "units": "feet", | ||
| "section": "Rule 8.4 - Well Spacing", | ||
| "summary": "'A new non-exempt well must be at least 500 feet from any existing non-exempt well.' Reduced spacing may be allowed for low-capacity wells below stated gpm threshold." | ||
| "summary": "'A new non-exempt well must be at least 500 feet from any existing non-exempt well.' Reduced spacing may be allowed for low-capacity wells below stated gpm threshold.", | ||
| "ord_text": "A new non-exempt well must be at least 500 feet from any existing non-exempt well." | ||
| }, | ||
| { | ||
| "feature": "production cost", | ||
| "value": "permit specific", | ||
| "units": "dollars/acre-foot", | ||
| "section": "Fee Schedule - Production Fees", | ||
| "summary": "Production fees are assessed by permit class and use category rather than one universal rate; schedule provides tiered dollar-per-acre-foot charges." | ||
| "summary": "Production fees are assessed by permit class and use category rather than one universal rate; schedule provides tiered dollar-per-acre-foot charges.", | ||
| "ord_text": "Production fees shall be assessed in accordance with the tiered dollar-per-acre-foot rates set out in the Fee Schedule for each permit class and use category." | ||
| } | ||
| ], | ||
| "$instructions": { | ||
| "general": [ | ||
| "Extract only enacted district requirements, not proposed language or general background text.", | ||
| "Use direct excerpts/quotes in summary whenever possible.", | ||
| "Whenever a feature row is emitted, ord_text must be the first full sentence from the source document corresponding to the requirement being extracted, copied verbatim: for quantitative features the full source sentence containing the extracted value, and for qualitative features the first full source sentence relating to the requirement. Unlike summary, ord_text must be a single contiguous sentence reproduced exactly as written, with no paraphrasing, normalization, ellipses, added context, or commentary. If a feature has no requirement, omit the feature row entirely rather than emitting a row with an empty ord_text.", | ||
| "If a feature has no requirement, set value, units, section, and summary to null or omit the feature row.", | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This might be worth adjusting? |
||
| "When multiple values exist for one feature, choose the value applicable to the primary general rule and describe alternatives/conditions in summary.", | ||
| "Preserve distinctions between drilling permits, extraction permits, transfer permits, and reporting obligations.", | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add one or two examples where the sentence for the ordinance text extraction is completely different than the summary?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should remove the summary - and use value for both qualitative and quantitative features (like how we ask the interns to do)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would break the data model we have established here and here. While we could do that, we should have a strong reason for it