wisent 0.5.10__tar.gz → 0.5.12__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of wisent might be problematic. Click here for more details.
- {wisent-0.5.10 → wisent-0.5.12}/PKG-INFO +1 -1
- wisent-0.5.12/wisent/__init__.py +1 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/models/wisent_model.py +49 -10
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/multi_steering.py +34 -14
- {wisent-0.5.10 → wisent-0.5.12}/wisent.egg-info/PKG-INFO +1 -1
- wisent-0.5.10/wisent/__init__.py +0 -1
- {wisent-0.5.10 → wisent-0.5.12}/LICENSE +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/README.md +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/pyproject.toml +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/setup.cfg +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/setup.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/metrics/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/metrics/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/metrics/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/metrics/evaluator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/metrics/passk.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/cpp_sanitizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/java_sanitizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/python_sanitizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/utils.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/livecodebench/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/livecodebench/provider.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/core/runtime.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/entrypoint.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/safe_docker/recipes.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/models/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/models/logistic.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/classifiers/models/mlp.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/classifiers/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/classifiers/classifier_rotator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/cli_logger.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/data_loaders/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/data_loaders/data_loader_rotator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/evaluators/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/evaluators/evaluator_rotator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/steering_methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/steering_methods/steering_rotator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/commands/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/commands/help_cmd.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/commands/listing.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/commands/train_cmd.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/main.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/shell.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/ui.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/util/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/util/aggregations.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/util/parsing.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/cli/wisent_cli/version.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/activations/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/activations/activations_collector.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/activations/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/activations/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/budget.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/device_benchmarks.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/agent_classifier_decision.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/classifier_marketplace.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/create_classifier.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/response_diagnostics.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/select_classifiers.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/synthetic_classifier_option.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/tasks/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/tasks/task_manager.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/tasks/task_relevance.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/tasks/task_selector.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose/test_synthetic_classifier.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/diagnose.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/steer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/agent/timeout.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/autonomous_agent.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/bigcode_integration.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/buliders.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/pair.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/response.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/serialization.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/core/set.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/activations.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/base.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/control_vectors.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/coverage.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/divergence.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/duplicates.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_extractor_manifest.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_extractor_registry.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_task_extractors/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_task_extractors/winogrande.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_task_pairs_generation.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/loaders/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/loaders/custom.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/data_loaders/loaders/lm_loader.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/detection_handling.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/download_full_benchmarks.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/evaluators/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/evaluators/oracles/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/evaluators/oracles/interactive.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/evaluators/oracles/nlp_evaluator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/evaluators/oracles/user_specified.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/hyperparameter_optimizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/lm_eval_harness_ground_truth.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/log_likelihoods_evaluator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/managed_cached_benchmarks.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/mixed_benchmark_sampler.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/model_config_manager.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/model_persistence.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/models/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/models/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/models/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/classifier/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/classifier/activation_generator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/classifier/classifier_cache.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/classifier/optuna_classifier_optimizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/bigcode_evaluator_wrapper.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/data_utils.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/metrics.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/optuna_pipeline.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/steering/steering_optimization.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/parser.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/core/atom.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/core/prompt_formater.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/direct_completion.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/instruction_following.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/multiple_choice.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/role_playing.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/representation.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/sample_size_optimizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/sample_size_optimizer_v2.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/save_results.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_method.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_methods/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_methods/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_methods/methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_methods/methods/caa.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/steering_optimizer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/task_interface.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/task_selector.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/aime_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/file_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/hle_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/hmmt_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/livecodebench_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/livemathbench_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/lm_eval_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/math500_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/polymath_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tasks/supergpqa_task.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/time_estimator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/timing_calibration.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tracking/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tracking/latency.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/tracking/memory.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/trainers/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/trainers/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/trainers/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/trainers/steering_trainer.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/user_model_config.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/utils/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/core/utils/device.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/methods/opti_classificator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/opti/methods/opti_steering.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/deduper_cleaner.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/methods/base_dedupers.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/methods/base_refusalers.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/methods/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/methods/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/pairs_cleaner.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/cleaners/refusaler_cleaner.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/db_instructions/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/db_instructions/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/db_instructions/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/db_instructions/mini_dp.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/core/atoms.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/core/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/core/core.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/methods/__init__.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/methods/fast_diversity.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/pairs_generator.py +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent.egg-info/SOURCES.txt +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent.egg-info/dependency_links.txt +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent.egg-info/requires.txt +0 -0
- {wisent-0.5.10 → wisent-0.5.12}/wisent.egg-info/top_level.txt +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.5.12"
|
|
@@ -337,7 +337,7 @@ class WisentModel:
|
|
|
337
337
|
@torch.inference_mode()
|
|
338
338
|
def generate(
|
|
339
339
|
self,
|
|
340
|
-
inputs: list[list[ChatMessage]],
|
|
340
|
+
inputs: list[list[ChatMessage]] | str,
|
|
341
341
|
max_new_tokens: int = 128,
|
|
342
342
|
temperature: float = 0.7,
|
|
343
343
|
top_p: float = 0.95,
|
|
@@ -346,6 +346,7 @@ class WisentModel:
|
|
|
346
346
|
use_steering: bool = False,
|
|
347
347
|
steering_plan: SteeringPlan | None = None,
|
|
348
348
|
enable_thinking: bool = True,
|
|
349
|
+
prompt_is_formatted: bool = False,
|
|
349
350
|
**gen_kwargs: Any,
|
|
350
351
|
) -> list[str]:
|
|
351
352
|
"""
|
|
@@ -353,7 +354,7 @@ class WisentModel:
|
|
|
353
354
|
|
|
354
355
|
attributes:
|
|
355
356
|
inputs:
|
|
356
|
-
list of chat messages (each a list of {'role','content'} dicts).
|
|
357
|
+
list of chat messages (each a list of {'role','content'} dicts) OR pre-formatted string.
|
|
357
358
|
max_new_tokens:
|
|
358
359
|
max tokens to generate (beyond the prompt).
|
|
359
360
|
temperature:
|
|
@@ -371,6 +372,8 @@ class WisentModel:
|
|
|
371
372
|
If None, uses the internal plan.
|
|
372
373
|
enable_thinking:
|
|
373
374
|
If False, disable thinking/reasoning mode (prevents <think> tags for supported models like Qwen).
|
|
375
|
+
prompt_is_formatted:
|
|
376
|
+
If True, inputs is a pre-formatted string with chat template already applied.
|
|
374
377
|
**gen_kwargs:
|
|
375
378
|
additional kwargs passed to 'model.generate()'.
|
|
376
379
|
|
|
@@ -449,7 +452,23 @@ class WisentModel:
|
|
|
449
452
|
if use_steering:
|
|
450
453
|
self.apply_steering(steering_plan)
|
|
451
454
|
|
|
452
|
-
|
|
455
|
+
if prompt_is_formatted and isinstance(inputs, str):
|
|
456
|
+
# Direct tokenization of pre-formatted prompt
|
|
457
|
+
tokenizer_output = self.tokenizer(
|
|
458
|
+
inputs,
|
|
459
|
+
return_tensors="pt",
|
|
460
|
+
padding=False, # Single prompt, no padding needed
|
|
461
|
+
truncation=True, # Avoid errors on long inputs
|
|
462
|
+
max_length=self.tokenizer.model_max_length # Use model's actual limit
|
|
463
|
+
)
|
|
464
|
+
# Move tensors to the correct device (same as _batch_encode does)
|
|
465
|
+
batch = {
|
|
466
|
+
"input_ids": tokenizer_output["input_ids"].to(resolve_torch_device()),
|
|
467
|
+
"attention_mask": tokenizer_output["attention_mask"].to(resolve_torch_device())
|
|
468
|
+
}
|
|
469
|
+
else:
|
|
470
|
+
# Current behavior: apply chat template
|
|
471
|
+
batch = self._batch_encode(inputs, add_generation_prompt=True, enable_thinking=enable_thinking)
|
|
453
472
|
|
|
454
473
|
gen_out = self.hf_model.generate(
|
|
455
474
|
**batch,
|
|
@@ -613,7 +632,7 @@ class WisentModel:
|
|
|
613
632
|
@torch.inference_mode()
|
|
614
633
|
def generate_stream(
|
|
615
634
|
self,
|
|
616
|
-
inputs: list[list[ChatMessage]],
|
|
635
|
+
inputs: list[list[ChatMessage]] | str,
|
|
617
636
|
max_new_tokens: int = 128,
|
|
618
637
|
temperature: float = 0.7,
|
|
619
638
|
top_p: float = 0.95,
|
|
@@ -623,6 +642,7 @@ class WisentModel:
|
|
|
623
642
|
skip_prompt: bool = True,
|
|
624
643
|
skip_special_tokens: bool = True,
|
|
625
644
|
enable_thinking: bool = True,
|
|
645
|
+
prompt_is_formatted: bool = False,
|
|
626
646
|
**gen_kwargs: Any,
|
|
627
647
|
) -> Iterable[str]:
|
|
628
648
|
"""
|
|
@@ -631,7 +651,8 @@ class WisentModel:
|
|
|
631
651
|
|
|
632
652
|
attributes:
|
|
633
653
|
inputs:
|
|
634
|
-
list of chat messages (each a list of {'role','content'} dicts)
|
|
654
|
+
list of chat messages (each a list of {'role','content'} dicts) OR pre-formatted string.
|
|
655
|
+
Currently only one conversation is supported.
|
|
635
656
|
max_new_tokens:
|
|
636
657
|
max tokens to generate (beyond the prompt).
|
|
637
658
|
temperature:
|
|
@@ -651,6 +672,8 @@ class WisentModel:
|
|
|
651
672
|
if True, special tokens are removed from the yielded text.
|
|
652
673
|
enable_thinking:
|
|
653
674
|
If False, disable thinking/reasoning mode (prevents <think> tags for supported models like Qwen).
|
|
675
|
+
prompt_is_formatted:
|
|
676
|
+
If True, inputs is a pre-formatted string with chat template already applied.
|
|
654
677
|
**gen_kwargs:
|
|
655
678
|
additional kwargs passed to 'model.generate()'.
|
|
656
679
|
|
|
@@ -658,14 +681,30 @@ class WisentModel:
|
|
|
658
681
|
generated text chunks (str), as they become available.
|
|
659
682
|
"""
|
|
660
683
|
|
|
661
|
-
if len(inputs) != 1:
|
|
662
|
-
raise ValueError(
|
|
663
|
-
f"generate_stream currently supports exactly one conversation at a time (got {len(inputs)})."
|
|
664
|
-
)
|
|
665
684
|
if use_steering:
|
|
666
685
|
self.apply_steering(steering_plan)
|
|
667
686
|
|
|
668
|
-
|
|
687
|
+
if prompt_is_formatted and isinstance(inputs, str):
|
|
688
|
+
# Direct tokenization of pre-formatted prompt
|
|
689
|
+
tokenizer_output = self.tokenizer(
|
|
690
|
+
inputs,
|
|
691
|
+
return_tensors="pt",
|
|
692
|
+
padding=False, # Single prompt, no padding needed
|
|
693
|
+
truncation=True, # Avoid errors on long inputs
|
|
694
|
+
max_length=self.tokenizer.model_max_length # Use model's actual limit
|
|
695
|
+
)
|
|
696
|
+
# Move tensors to the correct device (same as _batch_encode does)
|
|
697
|
+
batch = {
|
|
698
|
+
"input_ids": tokenizer_output["input_ids"].to(resolve_torch_device()),
|
|
699
|
+
"attention_mask": tokenizer_output["attention_mask"].to(resolve_torch_device())
|
|
700
|
+
}
|
|
701
|
+
else:
|
|
702
|
+
# Current behavior: apply chat template
|
|
703
|
+
if not isinstance(inputs, list) or len(inputs) != 1:
|
|
704
|
+
raise ValueError(
|
|
705
|
+
f"generate_stream currently supports exactly one conversation at a time (got {type(inputs)} with {len(inputs) if isinstance(inputs, list) else 'N/A'} items)."
|
|
706
|
+
)
|
|
707
|
+
batch = self._batch_encode(inputs, add_generation_prompt=True, enable_thinking=enable_thinking)
|
|
669
708
|
|
|
670
709
|
streamer = TextIteratorStreamer(
|
|
671
710
|
self.tokenizer,
|
|
@@ -166,17 +166,19 @@ class MultiSteering:
|
|
|
166
166
|
max_new_tokens: int = 100,
|
|
167
167
|
temperature: float = 0.7,
|
|
168
168
|
top_p: float = 0.9,
|
|
169
|
-
enable_thinking: bool = True
|
|
169
|
+
enable_thinking: bool = True,
|
|
170
|
+
prompt_is_formatted: bool = False
|
|
170
171
|
) -> Iterable[str]:
|
|
171
172
|
"""Apply the combined steering vector to generate text with streaming.
|
|
172
173
|
|
|
173
174
|
Args:
|
|
174
175
|
model: WisentModel instance to use for generation
|
|
175
|
-
prompt: Input prompt
|
|
176
|
+
prompt: Input prompt (either raw text or pre-formatted with chat template)
|
|
176
177
|
max_new_tokens: Maximum tokens to generate
|
|
177
178
|
temperature: Sampling temperature
|
|
178
179
|
top_p: Top-p sampling parameter
|
|
179
180
|
enable_thinking: If False, disable thinking/reasoning mode (prevents <think> tags for supported models like Qwen)
|
|
181
|
+
prompt_is_formatted: If True, prompt already has chat template applied
|
|
180
182
|
|
|
181
183
|
Yields:
|
|
182
184
|
Generated text chunks
|
|
@@ -191,7 +193,8 @@ class MultiSteering:
|
|
|
191
193
|
raise MultiSteeringError("No layer information available")
|
|
192
194
|
|
|
193
195
|
print(f"\n🎯 Applying combined steering vector at layer {self.layer}")
|
|
194
|
-
print(f"Prompt: {prompt}")
|
|
196
|
+
print(f"Prompt: {prompt[:100]}..." if len(prompt) > 100 else f"Prompt: {prompt}")
|
|
197
|
+
print(f"Prompt is formatted: {prompt_is_formatted}")
|
|
195
198
|
print("=" * 50)
|
|
196
199
|
|
|
197
200
|
# Create SteeringPlan from the combined vector
|
|
@@ -202,13 +205,19 @@ class MultiSteering:
|
|
|
202
205
|
normalize=False # Already normalized in combine_vectors
|
|
203
206
|
)
|
|
204
207
|
|
|
205
|
-
#
|
|
206
|
-
|
|
208
|
+
# Handle prompt formatting
|
|
209
|
+
if prompt_is_formatted:
|
|
210
|
+
# Prompt already has chat template applied - pass as string directly
|
|
211
|
+
inputs = prompt
|
|
212
|
+
else:
|
|
213
|
+
# Format prompt as chat messages (current behavior)
|
|
214
|
+
messages: list[ChatMessage] = [{"role": "user", "content": prompt}]
|
|
215
|
+
inputs = [messages]
|
|
207
216
|
|
|
208
217
|
try:
|
|
209
218
|
# Use WisentModel's generate_stream with steering
|
|
210
219
|
yield from model.generate_stream(
|
|
211
|
-
inputs=
|
|
220
|
+
inputs=inputs,
|
|
212
221
|
max_new_tokens=max_new_tokens,
|
|
213
222
|
temperature=temperature,
|
|
214
223
|
top_p=top_p,
|
|
@@ -216,7 +225,8 @@ class MultiSteering:
|
|
|
216
225
|
steering_plan=steering_plan,
|
|
217
226
|
skip_prompt=True,
|
|
218
227
|
skip_special_tokens=True,
|
|
219
|
-
enable_thinking=enable_thinking
|
|
228
|
+
enable_thinking=enable_thinking,
|
|
229
|
+
prompt_is_formatted=prompt_is_formatted
|
|
220
230
|
)
|
|
221
231
|
|
|
222
232
|
except Exception as e:
|
|
@@ -231,17 +241,19 @@ class MultiSteering:
|
|
|
231
241
|
max_new_tokens: int = 100,
|
|
232
242
|
temperature: float = 0.7,
|
|
233
243
|
top_p: float = 0.9,
|
|
234
|
-
enable_thinking: bool = True
|
|
244
|
+
enable_thinking: bool = True,
|
|
245
|
+
prompt_is_formatted: bool = False
|
|
235
246
|
) -> str:
|
|
236
247
|
"""Apply the combined steering vector to generate text (non-streaming).
|
|
237
248
|
|
|
238
249
|
Args:
|
|
239
250
|
model: WisentModel instance to use for generation
|
|
240
|
-
prompt: Input prompt
|
|
251
|
+
prompt: Input prompt (either raw text or pre-formatted with chat template)
|
|
241
252
|
max_new_tokens: Maximum tokens to generate
|
|
242
253
|
temperature: Sampling temperature
|
|
243
254
|
top_p: Top-p sampling parameter
|
|
244
255
|
enable_thinking: If False, disable thinking/reasoning mode (prevents <think> tags for supported models like Qwen)
|
|
256
|
+
prompt_is_formatted: If True, prompt already has chat template applied
|
|
245
257
|
|
|
246
258
|
Returns:
|
|
247
259
|
Generated text
|
|
@@ -256,7 +268,8 @@ class MultiSteering:
|
|
|
256
268
|
raise MultiSteeringError("No layer information available")
|
|
257
269
|
|
|
258
270
|
print(f"\n🎯 Applying combined steering vector at layer {self.layer}")
|
|
259
|
-
print(f"Prompt: {prompt}")
|
|
271
|
+
print(f"Prompt: {prompt[:100]}..." if len(prompt) > 100 else f"Prompt: {prompt}")
|
|
272
|
+
print(f"Prompt is formatted: {prompt_is_formatted}")
|
|
260
273
|
print("=" * 50)
|
|
261
274
|
|
|
262
275
|
# Create SteeringPlan from the combined vector
|
|
@@ -267,19 +280,26 @@ class MultiSteering:
|
|
|
267
280
|
normalize=False # Already normalized in combine_vectors
|
|
268
281
|
)
|
|
269
282
|
|
|
270
|
-
#
|
|
271
|
-
|
|
283
|
+
# Handle prompt formatting
|
|
284
|
+
if prompt_is_formatted:
|
|
285
|
+
# Prompt already has chat template applied - pass as string directly
|
|
286
|
+
inputs = prompt
|
|
287
|
+
else:
|
|
288
|
+
# Format prompt as chat messages (current behavior)
|
|
289
|
+
messages: list[ChatMessage] = [{"role": "user", "content": prompt}]
|
|
290
|
+
inputs = [messages]
|
|
272
291
|
|
|
273
292
|
try:
|
|
274
293
|
# Use WisentModel's generate with steering
|
|
275
294
|
outputs = model.generate(
|
|
276
|
-
inputs=
|
|
295
|
+
inputs=inputs,
|
|
277
296
|
max_new_tokens=max_new_tokens,
|
|
278
297
|
temperature=temperature,
|
|
279
298
|
top_p=top_p,
|
|
280
299
|
use_steering=True,
|
|
281
300
|
steering_plan=steering_plan,
|
|
282
|
-
enable_thinking=enable_thinking
|
|
301
|
+
enable_thinking=enable_thinking,
|
|
302
|
+
prompt_is_formatted=prompt_is_formatted
|
|
283
303
|
)
|
|
284
304
|
|
|
285
305
|
return outputs[0] if outputs else ""
|
wisent-0.5.10/wisent/__init__.py
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.5.10"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/output_sanitizer/python_sanitizer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/livecodebench/__init__.py
RENAMED
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/benchmarks/coding/providers/livecodebench/provider.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/diagnostics/control_vectors.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_extractor_manifest.py
RENAMED
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/core/contrastive_pairs/lm_eval_pairs/lm_extractor_registry.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/core/optuna/classifier/optuna_classifier_optimizer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/core/prompts/prompt_stratiegies/instruction_following.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wisent-0.5.10 → wisent-0.5.12}/wisent/synthetic/generators/diversities/methods/fast_diversity.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|