Datasets:
sejm_api_2011_2022: cut the "Przebieg posiedzenia" trailers before the cross-source dedup (amends #76, v2#57)
What and why
Amends the merged Hub PR 76 (sejm_api_2011_2022, slayerlabs/polish-dynaword-v2#57), approved as option S. Stacked on Hub PR 83 (sejm_api trailer cut): it reuses sejm_api_common.split_release_rows from #83 and pins the post-cut sejm_api.parquet as a reference, so merge #83 first. Until then this PR's diff also shows #83's commits.
The same "Przebieg posiedzenia" trailers as in sejm_api are in 105,920 of the 118,902 pre-dedup speeches (97,723,744 characters). Hub PR 76 stripped the headers only from the shingled text when it scored containment; the published rows kept them, and kept any appended statement inside its parent row.
src/clean_sejm_api_2011_2022.py now:
- cuts every trailer and emits each appended statement as a row of its own (
split_release_rows, same rules as #83: speaker = the name the header gives, not the label ("Stanu w Ministerstwie …" before 5a4bd59), the parent's date and term, sidecarsplit_from= parent id andhas_events: null; cut and split rows under 200 characters and new exact duplicates dropped); - runs the containment search on the result, so a speech is scored on its own words and an appended statement on its own;
- pins
sejm_apiat its post-cut sha (ba2daa20…); the local header stripper (body()) andcheck_pinare gone (no header is left after the cut in the inputs or either reference;check_pincomes fromsejm_api_common); - checks the input
stats.jsonagainst the recomputed release stats, andread + split_rows - drops == kept.
src/sources.py provenance note and the card are updated; artifacts/source_findings.md appended. README/CHANGELOG untouched.
Before -> after
| before (Hub PR 76) | after | |
|---|---|---|
| rows cut | 105,920 of 118,902 (97,723,744 chars) | |
| statements split into rows of their own | 15,648 (11,134 other speaker, 4,514 same-speaker follow-ups) | |
| dropped under 200 chars after the cut | 7,563 (5,374 cut rows, 2,189 split rows) | |
| dropped exact duplicates | 0 | 20 |
| rows entering the containment search | 118,902 | 126,967 |
| contained (>= 0.5) and dropped | 86,442 | 93,861 |
| kept at 0.3-0.5 | 899 | 639 |
outcome A (sejm_api alone) / outcome B |
216 / 48,833 | 45 / 54,081 |
| documents | 32,460 | 33,106 |
| characters | 81,385,172 | 70,230,096 |
tokens (cl100k_base proxy) |
30,766,807 | 26,112,679 |
.parquet sha256 |
8fad4b4e…0a20a |
622228ca…742db |
.attribution.jsonl sha256 |
5ce9a3c1…94b4 |
bb45cbd3…a72c |
Where the 646 extra documents come from: of the 32,460 rows #76 kept, 1,882 fall under 200 characters once their trailer is cut (504 dated 2011-2019), 4 now reach 0.5 and 5 drop below it; 2,527 split rows are added (180 of them cut from a speech that is itself dropped as contained). Kept 2011-2019 rows: 1,697 -> 1,281.
The 20 duplicates are 12 texts, 2013-2019: 11 undelivered written statements ("wypowiedź niewygłoszona" / "tekst niewygłoszony", mostly vote corrections) filed with the same text by several MPs, or 2-3 times by one MP on the same day, and the RPP oath taken by three members. Before the cut their different trailers kept them apart. First wins, as in the fetch.
The card's hand checks (12 post-2019 drops, 20 pairs at 0.3-0.7) were made on the #76 build and were not repeated; the card says so.
Checks
pytestfrom the repo root (on #83's 5a4bd59): 517 passed, 51 failed/errors, all reading unsmudged LFS pointers of other sources in the worktree (the same set as on #83, minus oneparliamentarytest that passes here because that file is smudged as a reference). The 48 sejm tests pass, including 2 new ones here: no trailer left in the released rows and split rows marked (split_from,has_events: null, ≥200 chars, ids aligned with the sidecar, stats match), and a synthetic build where an appended statement found in a reference (36 of its 56 shingles) is cut into its own row and dropped, while the parent is kept; uncut, the row scored 36/137 = 0.26 and stayed whole. The header-stripping test is removed withbody().- The shipped files are the output of
src/clean_sejm_api_2011_2022.pyrun on the three pinned inputs restored from 3bab9f9 (all pins checked). Before #83's author fix, a second run with another worker count gave the same bytes. Rebuilding after #83's author fix changed only ids and authors of 2,319 split rows (2,301 office fragments, 18 "Sprawozdawca" prefixes); the decisions are the same multiset apart from ids, andstats.jsondiffers only in thesejm_apipin. - README/CHANGELOG untouched.
Sample (python3 src/render_sample.py data/sejm_api_2011_2022/sejm_api_2011_2022.parquet -n 3 --max-chars 600)
id: sejm_api_2011_2022_2d72966f2d3384916d9ce60e5f808d4cb7b0fa636cdbdbe6ef85a5adf91876c4
source: sejm_api_2011_2022
added: 2026-08-31
created: 2020-02-13
token_count: 339
license: public-domain (official documents)
author: Anna Moskwa
Rozumiem, że na sali sejmowej nie będziemy zajmować się teraz konkretnym człowiekiem i analizować jego CV i ścieżki przenoszenia go do poszczególnych urzędów. Nie wydaje mi się, żeby Izba się tym zajmowała. Został on wybrany na podstawie doświadczenia i wykształcenia, zgodnie z kryteriami i z procedurami. Tyle mogę panu posłowi dzisiaj powiedzieć. Wrócę jeszcze do kwestii urzędu, bo pan poseł to podniósł. Mówimy o zniesieniu urzędu, co nie oznacza w żaden sposób zniesienia administracji morskiej. Nie mówimy, że będzie teraz luka na terenie Pomorza. Chodzi po prostu o podział na dwa urzędy. […]
id: sejm_api_2011_2022_5ece90a302fb1d4d1cdf3db3756939aad3049b44b558e70f54d0795d2a9c626d
source: sejm_api_2011_2022
added: 2026-08-31
created: 2022-07-06
token_count: 287
license: public-domain (official documents)
author: Małgorzata Chmiel
Panie Marszałku! Wysoka Izbo! To jest skandal, żeby tylko pół minuty wyznaczył pan na zadanie pytania w sprawie tak ważnej dla tak wielu mieszkańców. I to na dodatek w wypadku podziału pieniędzy, naszych wspólnych pieniędzy, na tak ważne inwestycje. Chciałam zapytać, czy prawdą jest to, co powiedział minister infrastruktury... (Głos z sali: Nie jest.) ...że inwestycje drogowe realizowane są tam, gdzie samorządowcy wierzą w rząd PiS. (Głos z sali: Ha, ha, ha!) Pan minister Adamczyk tak powiedział. (Dzwonek) I chciałam zapytać, czy w ten sposób przyznajecie się do sposobu podziału naszych […]
id: sejm_api_2011_2022_b630ddae2e70bcf6d0830488667533768fc4b3a79a60ca9fae82be4cc6b41438
source: sejm_api_2011_2022
added: 2026-08-31
created: 2022-09-14
token_count: 1127
license: public-domain (official documents)
author: Jarosław Sachajko
Panie Marszałku! Wysoka Izbo! W imieniu koła Kukiz’15 - Demokracja Bezpośrednia chciałem przedstawić stanowisko w sprawie uchwały o dochodzeniu przez Polskę reparacji za szkody spowodowane przez Niemcy w czasie II wojny światowej. Padły tutaj bardzo ważkie słowa o tym, że jest to historyczna chwila, że jest to polska racja stanu, i dziwię się, że nie wszyscy tak to odbierają. Bo rzeczywiście jest to historyczna chwila, polska racja stanu, nawet może więcej, europejska czy światowa racja stanu, żeby różni totalitarni dyktatorzy wiedzieli, różne państwa wiedziały, że każda zbrodnia, która […]
A speech from 2020-02-13 before and after the cut:
Before (input row a29eee3b592f, from character 478 of 1608):
…y, jak to się stało, będziemy to wyjaśniać. Ale naprawdę bardzo prosimy tutaj o merytoryczną dyskusję nad tym. (Oklaski) Przebieg posiedzenia Janusz Cieszyński: 9. kadencja, 5. posiedzenie, 2. dzień - Podsekretarz Stanu w Ministerstwie Zdrowia Janusz Cieszyński 9. kadencja, 5. posiedzenie, 2. dzień (13-02-2020) 4. punkt porządku dziennego: Pierwsze czytanie rządowego projektu ustawy o zmianie niektórych ustaw w związku z promocją prozdrowotnych wyborów konsumentów. Podsekretarz Stanu w Ministerstwie Zdrowia Janusz Cieszyński: Szanowna Pani Marszałek! Wysoka Izbo! Ja bym przestrzegał przed obawami przed skierowaniem tego projektu do prac w komisji, ponieważ, szanowni państwo, opłatą nie będzie objęte to, co państwa najbardziej interesuje, czyli so […]
After (the cut parent and its split row):
id: sejm_api_2011_2022_5c8cc55c3b559da53c48a90d108c5fc637e14d99c5f3e52a4be3a29eee3b592f
source: sejm_api_2011_2022
added: 2026-08-31
created: 2020-02-13
token_count: 225
license: public-domain (official documents)
author: Hanna Gill-Piątek
Szanowna Pani Marszałek! Panie Ministrze! Szanowni Państwo! Wysoka Izbo! Ten podatek i przede wszystkim podatek od małpek, które w tej chwili są przyczyną tego, że młodzież coraz bardziej się rozpija, jest podatkiem po prostu słusznym. (Oklaski) Jeżeli chodzi o Lewicę, to my będziemy za skierowaniem tego projektu do komisji, natomiast będziemy oczywiście chcieli poprawić tę ustawę, chociażby pod względem tego, że nagle zniknął z niej podatek od reklamy suplementów. Nie wiemy, jak to się stało, będziemy to wyjaśniać. Ale naprawdę bardzo prosimy tutaj o merytoryczną dyskusję nad tym. (Oklaski)
id: sejm_api_2011_2022_bf653b7d7a50165a71f61fac7cd4509874f03d109c7fde70a6eebc48544fc37b
source: sejm_api_2011_2022
added: 2026-08-31
created: 2020-02-13
token_count: 108
license: public-domain (official documents)
author: Janusz Cieszyński
Szanowna Pani Marszałek! Wysoka Izbo! Ja bym przestrzegał przed obawami przed skierowaniem tego projektu do prac w komisji, ponieważ, szanowni państwo, opłatą nie będzie objęte to, co państwa najbardziej interesuje, czyli sok z buraka. Dziękuję bardzo. (Oklaski) (Głos z sali: Ooo...)
🤖 Generated with Claude Code
refs/pr/84 ref