Skip to content

idx=5: freeze (18 records) — THIRD AMENDMENT TO MASTER LEASE, no parser changes#78

Open
arthrod wants to merge 1 commit into
redo/idx-4from
redo/idx-5
Open

idx=5: freeze (18 records) — THIRD AMENDMENT TO MASTER LEASE, no parser changes#78
arthrod wants to merge 1 commit into
redo/idx-4from
redo/idx-5

Conversation

@arthrod
Copy link
Copy Markdown
Owner

@arthrod arthrod commented May 17, 2026

User description

Summary

Sixth stacked PR. Adds idx=5 (THIRD AMENDMENT TO MASTER LEASE between Pinnacle Entertainment and Gaming and Leisure Properties, March 24, 2017) as the sixth verified frozen baseline on top of idx=4 (PR #77).

No parser changes needed. The round-2/3 subdoc consolidation logic (title-as-root + +1 subdoc penalty) already handles this agreement type cleanly. This PR is freeze-only.

Verified output for idx=5

  • 18 records (was 279 under pre-round-2 parser — 93.5% reduction in record count)
  • Distribution: {L0:1, L1:10, L2:7}
  • Reconstruction: word_coverage 99.6%, char_ratio 99.9%
  • Max depth: 2

Top-level structure

o=0  L0: THIRD AMENDMENT TO MASTER LEASE
o=1  L1: THIS THIRD AMENDMENT TO MASTER LEASE (this "Amendment") is made and effective as of March 24, 2017...
o=2  L1: W I T N E S S E T H: WHEREAS, Pinnacle Entertainment, Inc... (recitals)
o=3  L1: ARTICLE I AMENDMENT OF EXHIBIT B TO THE MASTER LEASE
o=4  L2: 1.1 The parties hereby agree that...
o=5  L1: TRACT FIFTEEN That certain parcel conveyed to Riverview Development Company... (inserted legal text per doc2dict natural grouping)
o=7  L1: ARTICLE II AMENDMENT TO MEMORANDUM OF LEASE
o=8  L1: ARTICLE III AUTHORITY TO ENTER INTO AMENDMENT
o=9  L1: ARTICLE IV MISCELLANEOUS
o=13 L1: IN WITNESS WHEREOF, this Amendment has been duly executed... LANDLORD: GOLD MERGER SUB, LLC By: /s/ Brandon J. Moore...
o=14 L1: EXHIBIT B LEGAL DESCRIPTIONS                    ← subdoc title at L1
o=15 L2: <242,279 chars of legal property descriptions>  ← subdoc body at L2 (+1 penalty)
o=16 L2: SECTION 12: NORTH HALF... (continuation of subdoc body)
o=17 L1: Schedule 1.1 / Ex. B-98 (trailing bare-identifier artifact)

Why this is significant

idx=5 was the stress test for the round-2 subdoc consolidation logic. The pre-round-2 parser exploded EXHIBIT B's 200+ TRACT/LOT/PARCEL legal property descriptions into separate L1 records, ballooning the freeze to 279 records and burying the main agreement structure. Round-2's _consolidate_real_subdocs + sig-page natural grouping correctly identifies EXHIBIT B as a real subdoc with a substantive body, consolidates the body to one L2 record (with +1 subdoc penalty), and preserves the main agreement's 4 Articles + sig area at L1.

This validates the round-2 design against a fundamentally different subdoc type (legal property descriptions, not press releases or [***] redactions).

Known minor quirks (non-blocking; inspector concurs)

  1. L1 "TRACT FIFTEEN" at o=5 — doc2dict's natural grouping placed this quoted-insert text at L1 instead of L3 (it's prose inside Article I § 1.1(a)). Depth-precision quirk, no content loss. Acceptable per "preserve doc2dict's natural grouping" rule.
  2. Single 242KB L2 record for EXHIBIT B body — this is the deliberate consolidation. Splitting it further would reintroduce the over-fragmentation the round-2 fix solved.
  3. Trailing "Schedule 1.1" / "Ex. B-98" at o=17 — tiny 24-char footer-like artifact. Harmless.

Test plan

  • uv run scripts/parse_doc2dict_with_config.py --limit 6 --no-truncate --output-dir data/auto_parse exits 0 with ok 6
  • uv run scripts/level_loop/freeze.py 5 --force reports word_coverage ≥ 90% (99.6%)
  • uv run scripts/level_loop/regress.py reports all 6 frozen idxs OK
  • Inspector verified subdoc consolidation, ARTICLE structure, sig area, all regress

Source

http://www.sec.gov/Archives/edgar/data/1656239/000165623917000033/d363017dex101.htm

🤖 Generated with Claude Code


CodeAnt-AI Description

Freeze the idx=5 master lease baseline with verified parser output

What Changed

  • Added idx=5 as a frozen baseline for the Third Amendment to Master Lease
  • Verified the parsed output stays at 18 records with strong reconstruction results
  • Added the frozen JSONL output and updated the freeze history to include this baseline
  • No parser behavior changed

Impact

✅ More regression coverage for master lease documents
✅ Fewer breakages on repeated freeze checks
✅ Safer baseline comparisons for frozen documents

🔄 Retrigger CodeAnt AI Review

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

…der existing parser

Round-2/3 subdoc consolidation logic (title L1 + body L2 with +1 penalty)
already handles this idx cleanly without any new parser changes:

  - Pre-round-2 survey: 279 records (L1=261, L2=17) — EXHIBIT B legal
    descriptions exploded into 200+ L1 LOT/TRACT/PARCEL records.
  - Current parser output: 18 records (L0=1, L1=10, L2=7) — EXHIBIT B
    header at L1, full body consolidated into one L2 record per subdoc
    rubric.
  - Reconstruction: word_coverage=99.6%, char_ratio=99.9% (well above
    the 90% bar).

Structure produced for idx=5:
  L0 "THIRD AMENDMENT TO MASTER LEASE" (title)
  L1 preamble + WITNESSETH/WHEREAS recitals
  L1 4 Articles (I/II/III/IV) with L2 numbered N.M sections
  L1 IN WITNESS WHEREOF signature block (single doc2dict node)
  L1 "EXHIBIT B LEGAL DESCRIPTIONS" subdoc header
  L2 EXHIBIT B body (242k chars of legal property descriptions)
  L1 trailing "Schedule 1.1" bare-identifier subdoc reference

All 6 frozen idxs (0/1/2/3/4/5) pass regression.
@blocksorg
Copy link
Copy Markdown

blocksorg Bot commented May 17, 2026

Mention Blocks like a regular teammate with your question or request:

@blocks review this pull request
@blocks make the following changes ...
@blocks create an issue from what was mentioned in the following comment ...
@blocks explain the following code ...
@blocks are there any security or performance concerns?

Run @blocks /help for more information.

Workspace settings | Disable this message

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hi @arthrod! 👋

Your private repo does not have access to Sourcery.

Please upgrade to continue using Sourcery ✨

@qodo-code-review
Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@codeant-ai
Copy link
Copy Markdown

codeant-ai Bot commented May 17, 2026

CodeAnt AI is reviewing your PR.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 17, 2026

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 3a41f4e8-8feb-4780-8e5a-7dc5cce3818c

📥 Commits

Reviewing files that changed from the base of the PR and between 81ad76f and a6e0d87.

📒 Files selected for processing (2)
  • data/auto_parse/level_freeze/frozen/idx_5.jsonl
  • data/auto_parse/level_freeze/state.json
📜 Recent review details
🧰 Additional context used
🔍 Remote MCP

The repository isn't yet indexed in DeepWiki. Let me search for related documentation using other approaches and gather context about the document being processed.## Summary of Additional Context Found

Based on my research, I've gathered the following relevant information to supplement the pull request review:

Document Details

The THIRD AMENDMENT TO MASTER LEASE is dated March 24, 2017, between Gold Merger Sub, LLC (landlord) and Pinnacle MLS, LLC (tenant), following a merger agreement dated July 20, 2015, between Pinnacle Entertainment, Gaming and Leisure Properties, Inc. (GLPI), and Pinnacle merged into the landlord on April 28, 2016.

Real Property Consolidation Context

The amendment addresses property acquisitions, including quitclaim deeds for Pinnacle Real Property located in Vicksburg, Mississippi, with portions added via additional deeds dated to the amendment's effective date. The "EXHIBIT B LEGAL DESCRIPTIONS" mentioned in the PR—which comprises approximately 242 KB of legal property descriptions and consolidates into a single L2 subdoc—represents these extensive real property scheduling requirements.

Historical Transaction Context

In April 2016, Pinnacle made a strategic sale-leaseback of the majority of its real estate assets to GLPI (a real estate investment trust). This Third Amendment (March 24, 2017) was subsequently referenced in later lease arrangements, including in a Lease Commitment and Rent Allocation Agreement that addressed facility divisions and rent allocation following corporate restructuring.

Parsing Efficiency

The PR's achievement of 99.6% word coverage and 99.9% character reconstruction ratio with only 18 records (down from 279 pre-round-2) reflects the parser's effectiveness in handling complex legal documents with extensive exhibits. The consolidation of EXHIBIT B into a single L2 record is a direct consequence of the real property scheduling density in master lease amendments of this type.

[::DeepWiki::]], [::web_search::]

🔇 Additional comments (1)
data/auto_parse/level_freeze/state.json (1)

8-9: LGTM!

Also applies to: 136-141


📝 Walkthrough

Summary by CodeRabbit

  • Chores
    • Updated internal state data structure with expanded configuration values and new action history entry to maintain system state integrity.

Walkthrough

This PR updates the auto-parse level freeze state file by expanding the frozen indices array from 4 to [8, 4, 9, 5] and appending a new freeze event history entry dated 2026-05-17T06:18:39 for index 5 with 18 records processed.

Changes

Level freeze state progression

Layer / File(s) Summary
Frozen indices and history update
data/auto_parse/level_freeze/state.json
The frozen array is expanded to include indices 8, 4, 9, and 5 in place of a single 4 value. A new history entry records a freeze action at timestamp 2026-05-17T06:18:39 for index 5 with 18 records, advancing the level-freeze workflow state.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Possibly related PRs

  • arthrod/clause-extract#39: Both PRs update data/auto_parse/level_freeze/state.json by expanding the frozen indices and adding freeze progress entries at different indices.
  • arthrod/clause-extract#5: Both PRs modify the same workflow state file to update frozen lists and append history freeze entries as part of the level-freeze loop progression.
  • arthrod/clause-extract#17: Both PRs modify the same state file fields (frozen/current_idx and history) to record freeze actions and advance the level-freeze workflow.

Suggested labels

Feat2

Poem

🐰 Ah, the frozen indices grow,
New records, eight, four, nine, and oh!
History marks the freeze so sweet,
At index five, the task complete!
State marches on, 'tis quite a sight.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically identifies the main change: adding idx=5 (THIRD AMENDMENT TO MASTER LEASE) as a frozen baseline with 18 records, and notes no parser changes are needed.
Description check ✅ Passed The description is directly related to the changeset, providing comprehensive details about the frozen baseline addition, verified output metrics, structural analysis, and test verification.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

@codeant-ai codeant-ai Bot added the size:S This PR changes 10-29 lines, ignoring generated files label May 17, 2026
@coderabbitai coderabbitai Bot added the Feat2 label May 17, 2026
@codeant-ai
Copy link
Copy Markdown

codeant-ai Bot commented May 17, 2026

CodeAnt AI finished reviewing your PR.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the state.json file to include index 5 in the frozen list and adds a corresponding history entry for the freeze action. Review feedback highlights that the current_idx should be advanced to 6 to maintain state consistency and prevent accidental overwrites. Additionally, there are concerns regarding structural inaccuracies and footer artifacts in the frozen data for index 5 that should be addressed in the parser to ensure a high-quality baseline.

3,
4
4,
5
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The current_idx (line 2) remains at 0 despite freezing up to idx=5. In this workflow, it is recommended to advance current_idx to 6 to reflect the progress and ensure that subsequent runs of the loop scripts (like freeze.py or advance.py) default to the correct next document. This prevents accidental overwrites of earlier indices.

Comment on lines +137 to 142
{
"ts": "2026-05-17T06:18:39",
"action": "freeze",
"idx": 5,
"n_records": 18
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The frozen output for idx=5 contains a structural inconsistency where 'TRACT FIFTEEN' (order 5) is assigned to Level 1, despite being content within Section 1.1(a) (Level 2). Additionally, order 17 appears to be a trailing footer artifact ('Ex. B-98') that should ideally be dropped per the rubric. While these are noted as 'quirks' in the PR description, freezing them into the golden baseline reduces the structural accuracy of the regression set. Consider if these can be addressed in the parser to maintain a cleaner baseline.

@arthrod
Copy link
Copy Markdown
Owner Author

arthrod commented May 17, 2026

Triage agent — PR #78 comment review (read-only pass, no code changes)

2 inline comments reviewed:

  1. gemini-code-assist @ state.json:9 — current_idx should advance to 6 (WILL-DEFER)
    Valid process observation: after freezing through idx=5, current_idx remaining at 0 could cause accidental overwrites if the freeze loop re-runs. The coordinator is managing current_idx progression actively — deferring to Arthur's workflow to update at the appropriate checkpoint.

  2. gemini-code-assist @ state.json:142 — idx=5 structural inconsistency: TRACT FIFTEEN at L1 and trailing footer (NEED-DISCUSSION)
    Gemini flags 'TRACT FIFTEEN' (order 5) as a structural anomaly at L1 given it's content within Section 1.1(a) (L2), and notes order 17 as a trailing footer artifact. This touches the frozen output for idx=5. Arthur's judgment needed on whether idx=5's freeze is considered acceptable per the rubric or whether this warrants a re-freeze.

NEED-DISCUSSION (1): idx=5 freeze — TRACT FIFTEEN level assignment and trailing footer in frozen/idx_5.jsonl.

Triage only — no code changes made this round.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feat2 size:S This PR changes 10-29 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant