I have a table with millions of rows that needs processing. The type of processing is not really important for this article. We simply need to process some data with Ruby --or any other user-space programming language.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # train_grpo.py | |
| import re | |
| import torch | |
| from datasets import load_dataset, Dataset | |
| from transformers import AutoTokenizer, AutoModelForCausalLM | |
| from peft import LoraConfig | |
| from trl import GRPOConfig, GRPOTrainer | |
| # Load and prep dataset |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Rails.application.config.sorcery.submodules = [:reset_password, :activity_logging, :external, :remember_me] | |
| Rails.application.config.sorcery.configure do |config| | |
| config.not_authenticated_action = :not_authenticated | |
| config.save_return_to_url = true | |
| config.cookie_domain = sorcery.kickr.io | |
| # -- session timeout -- | |
| # config.session_timeout = 3600 | |
| # config.session_timeout_from_last_action = false | |
| # -- activity logging -- |