strip-kit
De-identification for anything that leaves for an outside model, packaged so each user can run it against their own AWS account.
Three pieces:
lambda/handler.pyandtemplate.yaml: one Lambda, one DynamoDB table, Bedrock for the adversary and fixture generation. Deployed with SAM. Taggedapp=strip-kitso the skills can find it.../skills/strip: the consumer. Loads the current rules from the function, applies them in session, checks the calibration gate, refuses when closed. Claude strips; the function never sees real material.../skills/strip-lab: the calibration loop. Generates invented fixtures, runs re-identification trials against the Bedrock adversary, aggregates the lift over chance, bumps rules versions from the adversary's rationales.
Deploy (once per account)
Prerequisites: AWS CLI, SAM CLI, Bedrock model access enabled in the target region for the two models in template.yaml (DefaultModel for fixture generation, AdversaryModel for trials). Check what the account can reach:
aws bedrock list-inference-profiles --region us-east-1 --query 'inferenceProfileSummaries[].inferenceProfileId'
Then:
sam build
sam deploy --guided --stack-name strip-kit --parameter-overrides AdversaryModel=<strongest non-Anthropic id>
The adversary must not be an Anthropic model: the stripper is Claude, and a same-family adversary shares its blind spots. Use the strongest non-Anthropic model the account can reach; a weak adversary under-reports leakage and the calibration built on it is worthless.
Seed (once per table)
aws lambda invoke --function-name strip-kit --cli-binary-format raw-in-base64-out --payload file://seed/seed_payload.json /dev/stdout
This loads rules v2, the prompt catalog, 12 invented client fixtures, and two inherited calibration rows. The inherited numbers-only row (12 trials, lift 0.042 against a 0.15 bar) opens the numbers-only gate immediately; it stands until the deployment has 12 local trials, after which local trials decide. The narrative row is failing and stays failing until someone proves otherwise. Seeding refuses to run twice.
To change the seed, edit seed/rules.json, seed/fixtures.json, seed/prompts.json or seed/inherited.json and run python3 seed/make_seed.py.
Install as a Python package
The handler is also packaged as strip-kit (Python 3.12+, depends on boto3). It installs as the package strip_kit; lambda/ stays the SAM code directory.
pip install strip-kit
or straight from the repo:
pip install "git+https://github.com/jonasbu11/PreSales.git#subdirectory=strip-kit"
from strip_kit import handler
handler.handler({"action": "ping"})
Tags vX.Y.Z publish the same build to PyPI through .github/workflows/publish-strip-kit.yml (Trusted Publishing, no stored token).
Install the skills (per user)
The skills live in this repo at skills/strip and skills/strip-lab, next to the other presales skills; install them the same way. Each user needs the AWS connector pointed at an account where the function is deployed. On first use the skill discovers the function by tag and writes config.json; set function_name and region by hand to skip discovery.
First run on a new deployment
strip-lab: ping, read calibration, confirm the adversary model is not Anthropic.- Run 12 numbers-only trials against the seeded fixtures so the gate stands on local evidence rather than the inherited row.
- Generate 8 to 12 more client fixtures in batches of four so lineups are not always drawn from the same dozen.
Function actions
See the docstring at the top of lambda/handler.py. Every call is {"action": "<name>", ...} and returns JSON. strip-kit/tests/test_handler.py runs the whole loop against an in-memory store with Bedrock stubbed:
cd strip-kit && pip install boto3 pyyaml && python3 tests/test_handler.py && python3 tests/test_template.py
tests/test_template.py checks the SAM template's IAM scope and data-safety properties (region-scoped Bedrock access, explicit DynamoDB actions, retained table, bounded concurrency).
What is deliberately not here
- No real client list. The threat model assumes the adversary holds it; the lineup is built from synthetic fixtures so the test never needs the real one.
- No real material.
strip_trialtakes a fixture id, not free text about a client. - No in-place rule edits.
bump_rulesrequires a changelog note.
Metadata
Release files for strip-kit 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| strip_kit-0.1.3.tar.gz | 19.0 kB | With provenance | Details for strip_kit-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| strip_kit-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for strip_kit-0.1.3-py3-none-any.whl |
Total release size: 31.1 kB
Release files / strip_kit-0.1.3.tar.gz
| Download URL | strip_kit-0.1.3.tar.gz |
|---|---|
| Size | 19.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7a0b2e24af53881762f02bd53cd2a4986867f20599eb61974e13a89b9b58a685
|
|
BLAKE2b-256 checksum How to use checksums |
39655fa5293244120f8435cfc3bf5c1b55457037e691134deb7cdd0dff7f9dff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.
Transparency logRelease files / strip_kit-0.1.3-py3-none-any.whl
| Download URL | strip_kit-0.1.3-py3-none-any.whl |
|---|---|
| Size | 12.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
447bfa19e3ac0ec5d154e20385808654b38fa26ecc5c746e1cdeea8c7d2f7aa1
|
|
BLAKE2b-256 checksum How to use checksums |
7e7f183fcc5e5aff3148630e4074d7cb7bbeb0ee7d6a540191b708ee7b0a6cb0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.
Transparency logSecurity for strip-kit 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for strip_kit-0.1.3.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 4, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.