MCPcopy Create free account

hub / github.com/Agent-RL/ReCall / functions

Functions1,539 in github.com/Agent-RL/ReCall

Methodbatch_run
(self, dataset, batch_size=16)
src/flashrag/refiner/refiner.py:160
Methodbatch_run
(self, dataset, batch_size=2)
src/flashrag/refiner/refiner.py:226
Methodbatch_run
(self, dataset)
src/flashrag/refiner/kg_refiner.py:556
Functionbatch_search
(request: BatchQueryRequest)
scripts/serving/retriever_serving.py:94
Methodbatch_search
(self, *args, **kwargs)
src/flashrag/retriever/retriever.py:207
Methodbatch_search
(self, query, target_modal="text", num: Union[list, int, None] = None, return_score=False)
src/flashrag/retriever/retriever.py:839
Methodbuild_memory_reference
(self)
src/verl/utils/memory_buffer.py:202
Functioncache_manager
Decorator used for retrieving document cache. With the decorator, The retriever can store each retrieved document as a file and reuse it.
src/flashrag/retriever/retriever.py:20
Methodcal_gen_probs
(self, prev, next)
src/flashrag/generator/generator.py:580
Functioncalc_maj_val
Calculate the majority voting metric
src/verl/trainer/ppo/metric_utils.py:189
Methodcalculate_metric
Get the total score of this metric and score for each sample. Args: data object: it contains basic information and generated info
src/flashrag/evaluator/metrics.py:19
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:84
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:104
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:123
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:166
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:207
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:228
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:260
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:318
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:337
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:356
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:409
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:428
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:447
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:558
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:600
Methodcalculate_metric
(self, data)
src/flashrag/evaluator/metrics.py:615
Methodcalculate_rouge
(self, pred, golden_answers)
src/flashrag/evaluator/metrics.py:380
Functioncheck_correctness
Check correctness of code generation with a global timeout. The global timeout is to catch some extreme/rare cases not handled by the timeouts
src/verl/utils/reward_score/prime_code/utils.py:40
Methodcheck_mutually_exclusive
(mbs, mbs_per_gpu, name: str)
src/verl/trainer/ppo/ray_trainer.py:309
Functioncheck_workers_alive
(workers: List, is_alive: Callable, gap_time: float = 1)
src/verl/single_controller/base/worker_group.py:82
Methodcheckpath
(local_path: str, hdfs_path: str)
src/verl/utils/checkpoint/checkpoint_manager.py:71
Methodchunk
(self, chunks: int)
src/verl/protocol.py:735
Functionclip_by_value
Tensor extenstion to torch.clamp https://github.com/pytorch/pytorch/issues/2793#issuecomment-428784713
src/verl/utils/torch_functional.py:97
Functioncollate_fn
(x: list['DataProtoItem'])
src/verl/protocol.py:152
Functioncollate_fn
(data_list: list[dict])
src/verl/utils/dataset/rl_dataset.py:32
Functioncollect_all_to_all
(worker_group, output)
src/verl/single_controller/base/decorator.py:70
Functioncollect_dp_compute_data_proto
(worker_group, output)
src/verl/single_controller/base/decorator.py:294
Functioncollect_megatron_compute_data_proto
Each output must be a DataProto. We concat the dim=0 of output
src/verl/single_controller/base/decorator.py:147
Functioncollect_megatron_pp_as_dp_data_proto
(worker_group, output)
src/verl/single_controller/base/decorator.py:251
Functioncollect_megatron_pp_only
Only collect output of megatron pp. This is useful when examine weight names as they are identical in tp/dp
src/verl/single_controller/base/decorator.py:227
Methodcompress_json
( self, json_data: dict, json_config: Union[str, dict], instruction: str = "",
src/flashrag/refiner/llmlingua_compressor.py:353
Functioncompute_entropy_loss
Compute Categorical entropy loss Args: logits: `(torch.Tensor)` shape: (bs, response_length, vocab_size) response_mas
src/verl/trainer/ppo/core_algos.py:405
Functioncompute_gae_advantage_return
Adapted from https://github.com/huggingface/trl/blob/main/trl/trainer/ppo_trainer.py Args: token_level_rewards: `(torch.Tensor)`
src/verl/trainer/ppo/core_algos.py:66
Functioncompute_grad_norm
(model: nn.Module)
src/verl/utils/torch_functional.py:173
Functioncompute_grpo_outcome_advantage
Compute advantage for GRPO, operating only on Outcome reward (with only one scalar reward for each response). Args: token_level_
src/verl/trainer/ppo/core_algos.py:107
Methodcompute_log_prob
Compute the log probability of the responses given input_ids, attention_mask and position_ids Args: data (DataProto): a DataProto
src/verl/workers/actor/megatron_actor.py:148
Methodcompute_log_prob
Compute the log probability of the responses given input_ids, attention_mask and position_ids Args: data (DataProto): a DataProto
src/verl/workers/actor/dp_actor.py:177
Methodcompute_logprobs_fn
(output, data)
src/verl/workers/actor/megatron_actor.py:168
Methodcompute_ref_log_prob
(self, data: DataProto)
src/verl/workers/megatron_workers.py:436
Functioncompute_reinforce_plus_plus_baseline_outcome_advantage
Compute advantage for RF++-baseline (https://arxiv.org/abs/2501.03262), operating only on Outcome reward (with only one scalar reward for ea
src/verl/trainer/ppo/core_algos.py:152
Functioncompute_reinforce_plus_plus_outcome_advantage
Compute advantage for REINFORCE++. This implementation is based on the paper: https://arxiv.org/abs/2501.03262 Args: token_level
src/verl/trainer/ppo/core_algos.py:241
Functioncompute_remax_outcome_advantage
Compute advantage for ReMax, operating only on Outcome reward This implementation is based on the paper: https://arxiv.org/abs/2310.10505
src/verl/trainer/ppo/core_algos.py:275
Methodcompute_reward
(self, data: DataProto)
src/verl/workers/reward_model/megatron/reward_model.py:118
Functioncompute_rewards
(token_level_scores, old_log_prob, ref_log_prob, kl_ratio)
src/verl/trainer/ppo/core_algos.py:304
Functioncompute_rloo_outcome_advantage
Compute advantage for RLOO based on https://arxiv.org/abs/2402.14740 Args: token_level_rewards: `(torch.Tensor)` shape: (
src/verl/trainer/ppo/core_algos.py:197
Methodcompute_rm_score
(self, data: DataProto)
src/verl/workers/megatron_workers.py:833
Functioncompute_score
(predict_str: str, ground_truth: str)
src/verl/utils/reward_score/geo3k.py:30
Functioncompute_score
The scoring function for GSM8k. Reference: Trung, Luong, et al. "Reft: Reasoning with reinforced fine-tuning." Proceedings of the 62nd Annual Mee
src/verl/utils/reward_score/gsm8k.py:44
Functioncompute_score
(model_output: str, ground_truth: str, timeout_score: float = 0)
src/verl/utils/reward_score/math_verify.py:23
Functioncompute_score
Compute the reward score for a solution. Args: solution_str: The solution string ground_truth: The ground truth answer
src/verl/utils/reward_score/math_dapo.py:262
Functioncompute_score
(completion, test_cases, continuous=False)
src/verl/utils/reward_score/prime_code/__init__.py:21
Functioncompute_score
(model_output: str, ground_truth: str)
src/verl/utils/reward_score/prime_math/__init__.py:408
Functioncompute_score_batched
This is a demonstration of how the batched reward function should look like. Typically, you want to use batched reward to speed up the proces
src/verl/utils/reward_score/math_batch.py:18
Functioncompute_score_with_format
(tokenizer, solution_str, ground_truth)
src/verl/utils/reward_score/re_call.py:164
Functioncompute_value_loss
Compute the value loss. Copied from https://github.com/huggingface/trl/blob/main/trl/trainer/ppo_trainer.py#L1151 Args: vpreds (`torch.Fl
src/verl/trainer/ppo/core_algos.py:424
Methodcompute_values
(self, data: DataProto)
src/verl/workers/megatron_workers.py:656
Methodcompute_values
Compute values
src/verl/workers/critic/base.py:33
Methodcompute_values
(self, data: DataProto)
src/verl/workers/critic/megatron_critic.py:79
Methodcompute_values
(self, data: DataProto)
src/verl/workers/critic/dp_critic.py:131
Methodconcat
(data: List[ray.ObjectRef])
src/verl/protocol.py:731
Methodconfig
(self)
src/flashrag/generator/openai_generator.py:42
Methodconfig
(self)
src/flashrag/generator/generator.py:27
Methodconfig
(self)
src/flashrag/retriever/retriever.py:123
Methodcos_sim
(a, b)
src/flashrag/refiner/llmlingua_compressor.py:1947
Methodcp_size
(self)
src/verl/single_controller/base/megatron/worker_group.py:51
Functioncreate_huggingface_critic
Args: model_name: override_config_kwargs: Returns:
src/verl/utils/model.py:98
Functioncreate_nccl_communicator_in_ray
(rank: int, world_size: int, group_nam
src/verl/utils/rendezvous/ray_backend.py:47
Functioncreate_random_mask
Create a random mask given input_ids. Support left padding and right padding. Process: - Sample valid token length - Sample left_padding l
src/verl/utils/model.py:153
Methodcustom_forward
(*inputs)
src/flashrag/generator/fid.py:104
Methodcustom_serializer
(obj)
src/flashrag/retriever/retriever.py:164
Functiondecorator
(func)
src/flashrag/generator/generator.py:277
Functiondecorator
(func)
src/flashrag/retriever/retriever.py:433
Functiondecorator
(func)
src/re_call/inference/re_call.py:9
Functiondecorator
(func)
src/verl/utils/reward_score/prime_math/__init__.py:42
Functiondecorator
(func)
src/verl/single_controller/base/decorator.py:403
Functiondecorator
(func)
scripts/evaluation/utils.py:29
Functiondispatch_all_to_all
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:66
Functiondispatch_dp_compute
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:260
Functiondispatch_dp_compute_data_proto
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:277
Functiondispatch_dp_compute_data_proto_with_func
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:284
Functiondispatch_megatron_compute_data_proto
All the args and kwargs must be DataProto. The batch will be chunked by dp_size and passed to each rank
src/verl/single_controller/base/decorator.py:118
Functiondispatch_megatron_pp_as_dp_data_proto
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:241
Functiondispatch_one_to_all
(worker_group, *args, **kwargs)
src/verl/single_controller/base/decorator.py:60
Methoddp_size
(self)
src/verl/single_controller/base/megatron/worker_group.py:41
Methodencode
(self, query_list: Union[List[str], str], batch_size=64, is_query=True)
src/flashrag/retriever/encoder.py:118
Methodencode_image
(self, image_list: List)
src/flashrag/retriever/encoder.py:210
Methodencode_text
(self, text_list: List[str])
src/flashrag/retriever/encoder.py:227
Functionentropy_from_logits
Calculate entropy from logits.
src/verl/utils/torch_functional.py:106
Methodeos_token_id
`Optional[int]`: Id of the end of sentence token in the vocabulary. Returns `None` if the token has not been set.
src/verl/workers/rollout/tokenizer.py:44
← previousnext →1,101–1,200 of 1,539, ranked by callers