stanfordnlp / pyvene

Stanford NLP Python Library for Understanding and Improving PyTorch Models via Interventions
http://pyvene.ai
Apache License 2.0
608 stars 59 forks source link

[Minor] Adding `use_cache` flag to intervenable model forward call #152

Closed AmirZur closed 5 months ago

AmirZur commented 5 months ago

Description

Added use_cache flag to forward call in IntervenableModel. This is necessary for DPO training with ReFT.

Testing Done

Ran all unit tests successfully. Logs attached below. unittest_logs.txt

Checklist: