# Pyfixest Cupy64 Absorbed Regressors

> |

- **Type:** Skill
- **Install:** `agentstack add skill-kennethkhoocy-applied-micro-skills-pyfixest-cupy64-absorbed-regressors`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [kennethkhoocy](https://agentstack.voostack.com/s/kennethkhoocy)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [kennethkhoocy](https://github.com/kennethkhoocy)
- **Source:** https://github.com/kennethkhoocy/applied-micro-skills/tree/main/plugins/applied-micro/skills/pyfixest-cupy64-absorbed-regressors

## Install

```sh
agentstack add skill-kennethkhoocy-applied-micro-skills-pyfixest-cupy64-absorbed-regressors
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# pyfixest cupy64 backend: absorbed regressors survive, reports change shape

## Problem
Adding `demeaner_backend="cupy64"` to an existing `pf.feols()` call is treated
as a pure performance switch, but it changes the output: regressors with zero
within-FE identifying variation (fully absorbed by the fixed effects) that the
default numba backend silently drops are RETAINED by the cupy64 path (also in
its scipy/CPU fallback when cupy is not installed). They appear in the
coefficient table as non-identified garbage (huge coefficient, huge SE).

## Context / Trigger Conditions
Observed 2026-07-18 (Specialist Directors US, H5 re-baseline audit): adding
the kwarg to 4 feols sites left the headline triple stable to 4 decimals
(B1 diff 1.45e-6, SE diff 9.9e-6) but the text report grew from 366 to 390
lines — 24 new rows for absorbed controls (e.g. `event_x_lrisk = 435.8059`,
SE `7106.3365`) under firm-year + director FE, where firm-year-level
variables have no identifying variation.

## Solution
1. Treat a backend change as a POTENTIALLY OUTPUT-CHANGING edit: diff the
   report and expect schema changes, not byte equality. Verify the
   coefficients of interest at ~4-decimal precision instead.
2. Never interpret retained absorbed-regressor rows as estimates; check
   within-FE variation before reading nuisance coefficients.
3. Never parse pyfixest text reports by line position; anchor on the
   variable name of the coefficient you need.
4. When byte-stable reports matter (regression-tested pipelines), pin the
   backend consistently everywhere rather than mixing backends across runs.

## Verification
Re-run one model with and without the kwarg; compare: headline coef equal to
~1e-6, coefficient-row sets DIFFERENT (absorbed regressors present only under
cupy64). That asymmetry confirms this behavior rather than a data change.

## Notes
- Applies even with no GPU: the fail-open CPU fallback shows the same
  retention behavior, so "cupy isn't installed" does not make the kwarg inert.
- The headline inference (identified coefficients, clustered SEs) agrees to
  reporting precision; this is a report-shape/nuisance-row issue, not a
  correctness issue for identified estimates.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [kennethkhoocy](https://github.com/kennethkhoocy)
- **Source:** [kennethkhoocy/applied-micro-skills](https://github.com/kennethkhoocy/applied-micro-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-kennethkhoocy-applied-micro-skills-pyfixest-cupy64-absorbed-regressors
- Seller: https://agentstack.voostack.com/s/kennethkhoocy
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
