Reprocessed XBRL deal panel¶
This builder assembles a clean issuer–target panel from the current reprocessed SEC 10-K and 10-Q XBRL fact files. It is the current XBRL input to the M&A analysis; the older curated CSV is used only as an additional legacy source when constructing the reviewable target and acquirer mappings.
flowchart LR
k[(10-K numeric + text facts)]
q[(10-Q numeric + text facts)]
build[Identify BusinessAcquisition contexts<br/>select deal facts]
panel[(Clean XBRL deal panel)]
k --> build
q --> build
build --> panel
classDef input fill:#e8eef7,stroke:#52739e,stroke-width:2px
classDef process fill:#fff0d8,stroke:#b7791f,stroke-width:2px
classDef output fill:#e2f2e7,stroke:#3b7a4b,stroke-width:2px
class k,q input
class build process
class panel output
Inputs
| Input | Location | Purpose |
|---|---|---|
| Reprocessed 10-K numeric facts | /data/xbrl/form_10K_notes_numeric_long.parquet |
Acquisition contexts and accounting facts |
| Reprocessed 10-Q numeric facts | /data/xbrl/form_10Q_notes_numeric_long.parquet |
Quarterly fallback when an annual fact is unavailable |
| Reprocessed 10-K text facts | /data/xbrl/form_10K_notes_text_long.parquet |
Resolve the registrant name from the first acquisition filing |
| Reprocessed 10-Q text facts | /data/xbrl/form_10Q_notes_text_long.parquet |
Same name lookup for 10-Q first filings |
Build
| Component | Location | Purpose |
|---|---|---|
| Builder | shared/data/xbrl_deals/build_xbrl_deals.py |
Creates the deal spine and selects goodwill, consideration, and related XBRL facts |
| Output config | shared/config/config_full.yaml, data.xbrl_deals_path |
/data/full/processed/raw/xbrl_deals.parquet |
| Slurm wrapper | None | Run the Python module in an environment with DuckDB and pandas |
Output
| Dataset | Location | Grain |
|---|---|---|
| Clean XBRL deal panel | /data/full/processed/raw/xbrl_deals.parquet |
One issuer CIK × reported target label |
Construction and timing¶
The builder unions the 10-K and 10-Q numeric fact files and retains contexts
whose segment identifies a BusinessAcquisition target. The source files are
not restricted to a hard-coded year range; the panel's date coverage depends
on the current contents of the staged Parquets.
The deal key is (cik, target_firm). The builder identifies the first filing
for that issuer–target pair and stores its first_filing_date and
first_fiscal_year. It then selects point-in-time facts (qtrs = 0),
preferring 10-K/10-K/A over quarterly filings when an annual fact is available.
Selected facts must be filed within 365 days after the first acquisition
filing. Among the preferred facts, it chooses the earliest reference date,
with deterministic rules for dimensions and matching amendments. This
365-day rule is a fact-selection window per deal, not a global sample cutoff.
The output retains acquisition candidates and records whether a goodwill fact
was found. The downstream M&A regression-data builder filters to
has_goodwill = true, attaches selected Revelio mappings, observed pre-deal
match quality, and as-of Compustat data, and keeps the deal rows for analysis.
The later regression sample applies positive-goodwill, both-firms-mapped,
available-controls, and positive-consideration restrictions.
The reported xbrl_year used for pre-deal MQ is first_fiscal_year; the year
fixed effect in the regression is derived from the selected goodwill fact's
reference date (goodwill_ddate). Those year fields need not be identical.
The command reads the four default inputs above and writes to the path in
shared/config/config_full.yaml. --input, --text-input, --config,
--output, and --overwrite can be used to change the inputs, config, or
destination. The builder refuses to replace an existing output unless
--overwrite is supplied.
Next steps are the target mapping, acquirer mapping, and the analysis-layer XBRL regression panel.