Views
No views yet
tmft_project/ directory and open a terminal in that
directory.1python -m pip install -U pip
2python -m pip uninstall -y transformers peft accelerate tokenizers huggingface_hub datasets
3python -m pip install -r requirements.txt
4python -m spacy download en_core_web_smpython main.py --mode prepare --force_preparepython main.py --mode train --method allpython main.py --mode eval --method allpython main.py --mode plotpython main.py --mode all --method all --force_preparetmft_experiment.ipynb from top to bottom.baseline: standard LoRA fine-tuningrmft: random 15% loss maskingtmft_ner: loss masking at spaCy plus regex PII spanstmft_mia: online token masking where the current model is more confident
than the frozen base modeltmft_combined: union of NER and post-warm-up MIA masksdata/processed/: train, validation, and test DatasetDictdata/pii_eval.json: automatically generated real PII prefix-target attacksresults/<method>/: LoRA adapters and training metadataresults/tables/main_results.csv: submission-ready numeric tableresults/figures/: PNG and PDF privacy/utility figures1huggingface-cli login
2python main.py --mode upload --method tmft_combined \
3 --hf_repo_id YOUR_USERNAME/tmft-pythia-160m-tmft-combined--public only after checking that the saved artifacts contain no raw PII.