prelawsql
prelawsql validates and indexes Philippine legal-source material. It is built
for two kinds of readers:
- lawyers and legal researchers who need to trace a database record back to the exact source material; and
- developers who need deterministic parsing, reviewable failures, and safe rebuilds.
The package does not silently repair the source corpus. Raw source bytes are kept as evidence, normalized fields are stored separately, and records that cannot be interpreted safely are placed in quarantine for review.
Quick start
# Validate statute routes and atomically publish data/stats.db.
pre build-statute-index --replace
# Create data/cases.db with the decision and justice schemas.
pre init-decision-index --replace
# Ingest Supreme Court monthly decision listings for calendar year 2024.
# --end is exclusive.
pre ingest-decision-listings --start 2024 --end 2025
These commands create derived SQLite databases. They do not edit the decision, statute, or codification repositories.
Important classification rule
The word Opinion is not classified without knowing the document's role:
- a ponencia headed
Opinionis aDecision; - a separate opinion headed
Opinionis aSeparate Opinion; and - an unqualified
Opinionwith no reliable role remains unclassified.
Explicit Concurring Opinion, Dissenting Opinion, and Separate Opinion
labels are always treated as separate opinions. Kapasyahan is treated as a
resolution, while the observed defective label Ecision is treated as a
decision.
Command outcomes
| Exit code | Meaning |
|---|---|
0 |
Clean completion, or reviewed policy explicitly allowed quarantine |
1 |
System failure or an incomplete monthly retrieval |
2 |
Invalid command usage |
3 |
Processing completed, but one or more records were quarantined |
--allow-quarantine changes only code 3 to 0. It cannot hide a failed or
incomplete run.
Start with the documentation overview. The evidence and review guide explains what the database can establish—and what it cannot establish—before the data is relied upon in legal work. See Releases for the version-by-version change boundary and migration examples.
Release files for prelawsql 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| prelawsql-1.0.1.tar.gz | 47.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| prelawsql-1.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 103.7 kB
Release files / prelawsql-1.0.1.tar.gz
| Download URL | prelawsql-1.0.1.tar.gz |
|---|---|
| Size | 47.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a7f0c947520cfa37fff86aaa874bed61902122dfaf61d989e628a123016ab53d
|
|
BLAKE2b-256 checksum How to use checksums |
cde8b37c1cf2ae5dc7237d6a835a5b597c107a82fbac5d95824d705538f4735f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / prelawsql-1.0.1-py3-none-any.whl
| Download URL | prelawsql-1.0.1-py3-none-any.whl |
|---|---|
| Size | 56.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0262ae9751fa5b9eba4d7da6b6505800851ae2e73368d3e7d915e00a4036a0f4
|
|
BLAKE2b-256 checksum How to use checksums |
a9e32d133c81dc20cb8aab02fb4b2d5033c1fc7750c67fa08ffc5ae1ad58ecd7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|