HF RL Explorer

Statics that override built-in model/document methods are getting wrapped with hooks unexpectedly

Statics that override built-in model/document methods are getting wrapped with hooks unexpectedly: a task in MiMo-V2.6-RL-oss: Agentic RL Environments (MiMo RL release). I'm using a plugin similar to mongoose-delete that overrides some built-in methods (save, remove, etc.) by attaching them…

The task

I'm using a plugin similar to mongoose-delete that overrides some built-in methods (save, remove, etc.) by attaching them through schema.statics. My schema also defines normal hooks like pre('save') / post('save') for unrelated business logic on documents. Roughly: When I call…

Part of XiaomiMiMo/MiMo-V2.6-RL-oss.