Views
No views yet
SentenceTransformer(
(0): Transformer({'max_seq_length': 8192, 'do_lower_case': False}) with Transformer model: ModernBertModel
(1): Pooling({'word_embedding_dimension': 768, 'pooling_mode_cls_token': False, 'pooling_mode_mean_tokens': True, 'pooling_mode_max_tokens': False, 'pooling_mode_mean_sqrt_len_tokens': False, 'pooling_mode_weightedmean_tokens': False, 'pooling_mode_lasttoken': False, 'include_prompt': True})
(2): Normalize()
)pip install -U sentence-transformers1from sentence_transformers import SentenceTransformer
2
3# Download from the 🤗 Hub
4model = SentenceTransformer("Trelis/modernbert-embed-base-touch-rugby-ft")
5# Run inference
6sentences = [
7 'Is there a time-out for injuries during a standard Touch Rugby match?',
8 '4.9\tReferees and players may wear spectacles or sunglasses provided they are safe \nand securely attached.4.10\tReferees and players may wear sport monitoring equipment and medical \nsupports such as knee or ankle braces provided, at the sole discretion of \ncompetition’s controlling body, the items are not dangerous.5\u2002 Team Composition \n5.1\tA Team consists of a maximum of 14 players, no more than six (6) of whom are \nallowed on the field at any time.FIT Playing Rules - 5th Edition\n6\nCOPYRIGHT © Touch Football Australia 2020\nRuling = A Penalty awarded to the non-offending Team at the time the offence is identified \nseven (7) metres infield on the Halfway Line or the position of the ball, whichever is the \ngreater Advantage.5.2\tA Team must have a minimum of four (4) players on the field for a match to \ncommence or continue, except during a Drop-Off.',
9 '10.10\tIf a player in Possession intentionally makes a Touch on an Offside defender \nwho is making every effort to retire and remain out of play, the Touch counts.FIT Playing Rules - 5th Edition\nCOPYRIGHT © Touch Football Australia 2020\n9\n10.11\tIf a Touch is made on a player in Possession while the player is juggling the ball \nin an attempt to maintain control of it, the Touch counts if the attacking player \nfollowing the Touch retains Possession.10.12\tIf a player in Possession is Touched and subsequently makes contact with \neither the Sideline, a field marker or the ground outside the Field of Play, the \nTouch counts and play continues with a Rollball at the Mark where the Touch \noccurred.10.13\tWhen a player from the Defending Team enters its defensive Seven Metre Zone, \nthe Defending Team must move Forward at a reasonable pace until a Touch is \nImminent or made.Ruling = A Penalty to the Attacking Team at the point of the Infringement.',
10]
11embeddings = model.encode(sentences)
12print(embeddings.shape)
13# [3, 768]
14
15# Get the similarity scores for the embeddings
16similarities = model.similarity(embeddings, embeddings)
17print(similarities.shape)
18# [3, 3]question and related_chunk| question | related_chunk | |
|---|---|---|
| type | string | string |
| details |
|
|
| question | related_chunk |
|---|---|
What is defined as 'Forward' in the context of Touch Rugby? | Referee[object Object]The match official(s) appointed to make Rulings during the conduct [object Object]of a match.Rollball[object Object]The act of bringing the ball into play following a Touch or a Change [object Object]of Possession.Ruck/Rollball Area[object Object]The area, not exceeding one (1) metre in distance, between the [object Object]player performing a Rollball and the Half.Ruling[object Object]The decision made by a Referee as a result of particular [object Object]circumstance and may result in a Play On, a Tap Penalty, a discipline [object Object]option, Change of Possession or a Try.Seven Metre Zone[object Object]The area between the seven (7) metre line and the Try Line.See [object Object]Appendix 1.Sidelines[object Object]The side boundaries of the Field of Play.See Appendix 1.Sin Bin[object Object]A player sent to the Sin-Bin Area for a period of four (4) completed [object Object]Possessions.The player is counted as a player on the Field of Play [object Object]and cannot be replaced or Interchanged. |
What is the numerical difference between the teams on the field of play during a Drop-Off if a player has been sent to the sin bin? | 24.5 For the avoidance of doubt for clauses 24.3 and 24.4 the non-offending Team [object Object]will retain a numerical advantage on the Field of Play during the Drop-Off.25 Match Officials [object Object]25.1 The Referee is the sole judge on all match related matters inside the Perimeter [object Object]for the Duration of a match, has jurisdiction over all players, coaches and [object Object]officials and is required to:[object Object]25.1.1 Inspect the Field of Play, Line Markings and Markers prior to the [object Object]commencement of the Match to ensure the safety of all participants.25.1.2 Adjudicate on the Rules of the game;[object Object]25.1.3 Impose any sanction necessary to control the match;[object Object]25.1.4 Award Tries and record the progressive score;[object Object]25.1.5 Maintain a count of Touches during each Possession;[object Object]25.1.6 Award Penalties for Infringements against the Rules; and[object Object]25.1.7 Report to the relevant competition administration any Sin Bins, [object Object]Dismissals or injuries to any participant sustained during a Match. |
What happens if neither team is leading after two minutes of play in a Drop-Off? | 24.1.5 Should neither Team be leading at the expiration of two (2) minutes, a [object Object]signal is given and the match will pause at the next Touch or Dead Ball.Each Team will then remove another player from the Field of Play.24.1.6 The Match will recommence immediately after the players have left the [object Object]field at the same place where it paused (i.e.the Team retains Possession [object Object]at the designated number of Touches, or at Change of Possession due to [object Object]some Infringement or the sixth Touch) and the Match will continue until a [object Object]Try is scored.24.1.7 There is no time off during the Drop-Off and the clock does not stop at [object Object]the two (2) minute interval.24.1.8 Substitution during the Drop-Off is permitted in accordance with normal [object Object]Interchange Rules.24.2 Mixed gender Teams may have no more than (2) males on the field during the [object Object]Drop-Off. |
MultipleNegativesRankingLoss with these parameters:
1{
2 "scale": 20.0,
3 "similarity_fct": "cos_sim"
4}question and related_chunk| question | related_chunk | |
|---|---|---|
| type | string | string |
| details |
|
|
| question | related_chunk |
|---|---|
What is the penalty for an attacking player obstructing a defender in Touch Rugby? | Ruling = A Penalty to the Attacking Team at the point of the Infringement or on the seven (7) [object Object]metre line directly Forward of the Infringement.15.4 When a Rollball occurs within Defending Team’s Seven Metre Zone or a Penalty [object Object]Tap within ten (10) metres of the Defending Team’s Try Line, all players from the [object Object]Defending Team must have both feet on or behind their Try Line and no other [object Object]part of the body in contact with the ground Forward of their Try Line.Ruling = A Penalty to the Attacking Team at the seven (7) metre line directly Forward of the [object Object]point of the Infringement.15.5 After effecting the Touch, the defending player must retire the required seven [object Object](7) metres or to the Defending Try Line as indicated by the Referee without [object Object]interfering with the Attacking Team.Ruling = A Penalty to the Attacking Team ten (10) metres Forward of the Infringement or if [object Object]on the Defensive Try Line, on the seven (7) metre line. |
When must a player perform a Rollball seven metres in-field? | 13.5 A player may only perform a Rollball at the Mark under the following [object Object]circumstances:[object Object]13.5.1 when a Touch has been made; or[object Object]13.5.2 when Possession changes following the sixth Touch; or[object Object]13.5.3 when Possession changes due to the ball being dropped or passed and [object Object]goes to the ground; or[object Object]13.5.4 when Possession changes due to an Infringement by an attacking player [object Object]at a Penalty, a Tap or a Rollball; or[object Object]FIT Playing Rules - 5th Edition[object Object]COPYRIGHT © Touch Football Australia 2020[object Object]11[object Object]13.5.5 when Possession changes after the Half is Touched or when the Half [object Object]places the ball on or over the Try Line; or[object Object]13.5.6 in replacement of a Penalty Tap; or[object Object]13.5.7 when so directed by the Referee.13.6 A player is to perform a Rollball seven (7) metres in-field under the following [object Object]circumstances:[object Object]13.6.1 when a Change of Possession takes place due to a player in Possession [object Object]making contact with the Sideline or any ground outside the Field of Play, [object Object]prior to a Touch being made; or[object Object]13.6.2 when the ball not in Poss... |
What is the ruling if a player uses excessive force when making a touch? | FIT Playing Rules - 5th Edition[object Object]8[object Object]COPYRIGHT © Touch Football Australia 2020[object Object]9.6 If a player mishandles the ball and even if in an effort to gain control, the ball [object Object]is accidentally knocked Forward into any other Player, a Change of Possession [object Object]results.10 The Touch [object Object]10.1 A Touch may be made by either a defending player or a player in Possession.10.2 A defending player may not claim a Touch if contact has not been made.If a [object Object]player claims a Touch has been made, but the Referee is unsure the Touch will [object Object]count.Ruling = A Penalty to the Attacking Team at the point of the Infringement and the offending [object Object]player sent to the Sin Bin.10.3 Players of both Defending and Attacking Teams are to use the minimum force [object Object]necessary to make a Touch.Players must ensure that the method employed in [object Object]making a Touch does not pose an unnecessary risk to player safety.Ruling = A Penalty to the non-offending Team at the point of the Infringement. |
MultipleNegativesRankingLoss with these parameters:
1{
2 "scale": 20.0,
3 "similarity_fct": "cos_sim"
4}eval_strategy: stepsper_device_train_batch_size: 32per_device_eval_batch_size: 32learning_rate: 2e-05num_train_epochs: 1lr_scheduler_type: cosinewarmup_ratio: 0.3overwrite_output_dir: Falsedo_predict: Falseeval_strategy: stepsprediction_loss_only: Trueper_device_train_batch_size: 32per_device_eval_batch_size: 32per_gpu_train_batch_size: Noneper_gpu_eval_batch_size: Nonegradient_accumulation_steps: 1eval_accumulation_steps: Nonetorch_empty_cache_steps: Nonelearning_rate: 2e-05weight_decay: 0.0adam_beta1: 0.9adam_beta2: 0.999adam_epsilon: 1e-08max_grad_norm: 1.0num_train_epochs: 1max_steps: -1lr_scheduler_type: cosinelr_scheduler_kwargs: {}warmup_ratio: 0.3warmup_steps: 0log_level: passivelog_level_replica: warninglog_on_each_node: Truelogging_nan_inf_filter: Truesave_safetensors: Truesave_on_each_node: Falsesave_only_model: Falserestore_callback_states_from_checkpoint: Falseno_cuda: Falseuse_cpu: Falseuse_mps_device: Falseseed: 42data_seed: Nonejit_mode_eval: Falseuse_ipex: Falsebf16: Falsefp16: Falsefp16_opt_level: O1half_precision_backend: autobf16_full_eval: Falsefp16_full_eval: Falsetf32: Nonelocal_rank: 0ddp_backend: Nonetpu_num_cores: Nonetpu_metrics_debug: Falsedebug: []dataloader_drop_last: Falsedataloader_num_workers: 0dataloader_prefetch_factor: Nonepast_index: -1disable_tqdm: Falseremove_unused_columns: Truelabel_names: Noneload_best_model_at_end: Falseignore_data_skip: Falsefsdp: []fsdp_min_num_params: 0fsdp_config: {'min_num_params': 0, 'xla': False, 'xla_fsdp_v2': False, 'xla_fsdp_grad_ckpt': False}fsdp_transformer_layer_cls_to_wrap: Noneaccelerator_config: {'split_batches': False, 'dispatch_batches': None, 'even_batches': True, 'use_seedable_sampler': True, 'non_blocking': False, 'gradient_accumulation_kwargs': None}deepspeed: Nonelabel_smoothing_factor: 0.0optim: adamw_torchoptim_args: Noneadafactor: Falsegroup_by_length: Falselength_column_name: lengthddp_find_unused_parameters: Noneddp_bucket_cap_mb: Noneddp_broadcast_buffers: Falsedataloader_pin_memory: Truedataloader_persistent_workers: Falseskip_memory_metrics: Trueuse_legacy_prediction_loop: Falsepush_to_hub: Falseresume_from_checkpoint: Nonehub_model_id: Nonehub_strategy: every_savehub_private_repo: Nonehub_always_push: Falsegradient_checkpointing: Falsegradient_checkpointing_kwargs: Noneinclude_inputs_for_metrics: Falseinclude_for_metrics: []eval_do_concat_batches: Truefp16_backend: autopush_to_hub_model_id: Nonepush_to_hub_organization: Nonemp_parameters:auto_find_batch_size: Falsefull_determinism: Falsetorchdynamo: Noneray_scope: lastddp_timeout: 1800torch_compile: Falsetorch_compile_backend: Nonetorch_compile_mode: Nonedispatch_batches: Nonesplit_batches: Noneinclude_tokens_per_second: Falseinclude_num_input_tokens_seen: Falseneftune_noise_alpha: Noneoptim_target_modules: Nonebatch_eval_metrics: Falseeval_on_start: Falseuse_liger_kernel: Falseeval_use_gather_object: Falseaverage_tokens_across_devices: Falseprompts: Nonebatch_sampler: batch_samplermulti_dataset_batch_sampler: proportional| Epoch | Step | Training Loss | Validation Loss |
|---|---|---|---|
| 0.2222 | 2 | 2.7671 | nan |
| 0.4444 | 4 | 0.0 | nan |
| 0.6667 | 6 | 0.0 | nan |
| 0.8889 | 8 | 0.0 | nan |
1@inproceedings{reimers-2019-sentence-bert,
2 title = "Sentence-BERT: Sentence Embeddings using Siamese BERT-Networks",
3 author = "Reimers, Nils and Gurevych, Iryna",
4 booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing",
5 month = "11",
6 year = "2019",
7 publisher = "Association for Computational Linguistics",
8 url = "https://arxiv.org/abs/1908.10084",
9}1@misc{henderson2017efficient,
2 title={Efficient Natural Language Response Suggestion for Smart Reply},
3 author={Matthew Henderson and Rami Al-Rfou and Brian Strope and Yun-hsuan Sung and Laszlo Lukacs and Ruiqi Guo and Sanjiv Kumar and Balint Miklos and Ray Kurzweil},
4 year={2017},
5 eprint={1705.00652},
6 archivePrefix={arXiv},
7 primaryClass={cs.CL}
8}