Download annotations/annotation_29/function_info.json from mcy98/RECODE-H: direct link, hf CLI and curl.
- Browser
- Download file 10.2 kB
-
https://huggingface.co/datasets/mcy98/RECODE-H/resolve/main/annotations/annotation_29/function_info.json
- Command line
-
hf download hf://datasets/mcy98/RECODE-H/annotations/annotation_29/function_info.json
-
curl -L -o function_info.json https://huggingface.co/datasets/mcy98/RECODE-H/resolve/main/annotations/annotation_29/function_info.json
10.2 kB
| [ | |
| { | |
| "function_name": "get_scaler", | |
| "file_path": "llmtime.py", | |
| "function_calls": [ | |
| { | |
| "function_call_name": "np.isnan", | |
| "functionality": "Check for NaN values in array.", | |
| "input": "history", | |
| "output": "ndarray of bool", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.quantile", | |
| "functionality": "Compute the quantile of array elements.", | |
| "input": "np.abs(history), alpha", | |
| "output": "float", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.abs", | |
| "functionality": "Absolute value element-wise.", | |
| "input": "history", | |
| "output": "array_like", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.maximum", | |
| "functionality": "Element-wise maximum of array elements.", | |
| "input": "np.quantile(np.abs(history), alpha), .01", | |
| "output": "float", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.min", | |
| "functionality": "Return the minimum along a dimension.", | |
| "input": "history", | |
| "output": "float", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.max", | |
| "functionality": "Return the maximum along a dimension.", | |
| "input": "history", | |
| "output": "float", | |
| "location_or_namespace": "numpy" | |
| } | |
| ] | |
| }, | |
| { | |
| "function_name": "truncate_input", | |
| "file_path": "llmtime.py", | |
| "function_calls": [ | |
| { | |
| "function_call_name": "split", | |
| "functionality": "Split string on a separator.", | |
| "input": "input_str, settings.time_sep", | |
| "output": "list[str]", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "join", | |
| "functionality": "Join list of strings with a separator.", | |
| "input": "settings.time_sep, input_str_chuncks[i:]", | |
| "output": "str", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "tokenization_fn", | |
| "functionality": "", | |
| "input": "truncated_input_str", | |
| "output": "list[str]", | |
| "location_or_namespace": "models.llms or internal" | |
| }, | |
| { | |
| "function_call_name": "len", | |
| "functionality": "Return number of items in object.", | |
| "input": "input_tokens / input_str_chuncks / input_arr / truncated_input_arr", | |
| "output": "int", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "print", | |
| "functionality": "Print warning about truncation.", | |
| "input": "f'Warning: Truncated input from {len(input_arr)} to {len(truncated_input_arr)}'", | |
| "output": "None", | |
| "location_or_namespace": "builtins" | |
| } | |
| ] | |
| }, | |
| { | |
| "function_name": "handle_prediction", | |
| "file_path": "llmtime.py", | |
| "function_calls": [ | |
| { | |
| "function_call_name": "len", | |
| "functionality": "Return length of predicted array.", | |
| "input": "pred", | |
| "output": "int", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "print", | |
| "functionality": "Print warning if prediction too short.", | |
| "input": "f'Warning: Prediction too short {len(pred)} < {expected_length}, ...'", | |
| "output": "None", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "np.concatenate", | |
| "functionality": "Join two or more arrays.", | |
| "input": "[pred, np.full(expected_length - len(pred), pred[-1])]", | |
| "output": "np.ndarray", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "np.full", | |
| "functionality": "Return a new array of given shape and value.", | |
| "input": "expected_length - len(pred), pred[-1]", | |
| "output": "np.ndarray", | |
| "location_or_namespace": "numpy" | |
| } | |
| ] | |
| }, | |
| { | |
| "function_name": "generate_predictions", | |
| "file_path": "llmtime.py", | |
| "function_calls": [ | |
| { | |
| "function_call_name": "len", | |
| "functionality": "Check number of input series.", | |
| "input": "input_strs", | |
| "output": "int", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "print", | |
| "functionality": "Print parallel execution info.", | |
| "input": "'Running completions in parallel for each input'", | |
| "output": "None", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "min", | |
| "functionality": "Return minimum of arguments.", | |
| "input": "max_concurrent, len(input_strs)", | |
| "output": "int", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "ThreadPoolExecutor", | |
| "functionality": "Parallel execution of completions.", | |
| "input": "max_workers", | |
| "output": "ThreadPoolExecutor object", | |
| "location_or_namespace": "concurrent.futures" | |
| }, | |
| { | |
| "function_call_name": "tqdm", | |
| "functionality": "Progress bar for parallel execution.", | |
| "input": "p.map(complete, input_strs), total=len(input_strs)", | |
| "output": "iterator", | |
| "location_or_namespace": "tqdm" | |
| }, | |
| { | |
| "function_call_name": "map", | |
| "functionality": "Map function over iterable.", | |
| "input": "complete, input_strs", | |
| "output": "iterator", | |
| "location_or_namespace": "concurrent.futures.ThreadPoolExecutor" | |
| }, | |
| { | |
| "function_call_name": "deserialize_str", | |
| "functionality": "Deserialize LLM text completion to prediction array.", | |
| "input": "completion, settings, ignore_last=False, steps=steps", | |
| "output": "array-like", | |
| "location_or_namespace": "data.serialize" | |
| }, | |
| { | |
| "function_call_name": "handle_prediction", | |
| "functionality": "Post-process prediction output to expected length.", | |
| "input": "deserialize_str(completion, ...), expected_length=steps, strict=strict_handling", | |
| "output": "array-like or None", | |
| "location_or_namespace": "llmtime.py" | |
| } | |
| ] | |
| }, | |
| { | |
| "function_name": "get_llmtime_predictions_data", | |
| "file_path": "llmtime.py", | |
| "function_calls": [ | |
| { | |
| "function_call_name": "assert", | |
| "functionality": "Ensure valid model and input conditions.", | |
| "input": "model in completion_fns", | |
| "output": "None", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "isinstance", | |
| "functionality": "Type checks for settings and train/test.", | |
| "input": "settings, dict / train, list / train[i], pd.Series", | |
| "output": "bool", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "pd.Series", | |
| "functionality": "Create pandas Series from array.", | |
| "input": "train[i], index=pd.RangeIndex(...)", | |
| "output": "pandas.Series", | |
| "location_or_namespace": "pandas" | |
| }, | |
| { | |
| "function_call_name": "pd.RangeIndex", | |
| "functionality": "Create a pandas index.", | |
| "input": "len(train[i]) or len(train[i]), len(test[i])+len(train[i])", | |
| "output": "pandas.RangeIndex", | |
| "location_or_namespace": "pandas" | |
| }, | |
| { | |
| "function_call_name": "all", | |
| "functionality": "Check if all elements are True.", | |
| "input": "len(t)==test_len for t in test", | |
| "output": "bool", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "len", | |
| "functionality": "Get length of a sequence.", | |
| "input": "train, test, t, preds", | |
| "output": "int", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "get_scaler", | |
| "functionality": "Construct Scaler for normalization.", | |
| "input": "train[i].values, alpha=alpha, beta=beta, basic=basic", | |
| "output": "Scaler", | |
| "location_or_namespace": "llmtime.py" | |
| }, | |
| { | |
| "function_call_name": "np.array", | |
| "functionality": "Convert list to numpy array.", | |
| "input": "[scaler.transform(input_array) for ...]", | |
| "output": "np.ndarray", | |
| "location_or_namespace": "numpy" | |
| }, | |
| { | |
| "function_call_name": "serialize_arr", | |
| "functionality": "Serialize array for model input.", | |
| "input": "scaled_input_arr, settings", | |
| "output": "str", | |
| "location_or_namespace": "data.serialize" | |
| }, | |
| { | |
| "function_call_name": "zip", | |
| "functionality": "Iterate over multiple sequences.", | |
| "input": "input_arrs, input_strs", | |
| "output": "iterator", | |
| "location_or_namespace": "builtins" | |
| }, | |
| { | |
| "function_call_name": "truncate_input", | |
| "functionality": "Truncate input for context length.", | |
| "input": "input_array, input_str, settings, model, test_len", | |
| "output": "tuple", | |
| "location_or_namespace": "llmtime.py" | |
| }, | |
| { | |
| "function_call_name": "generate_predictions", | |
| "functionality": "Run model, deserialize outputs.", | |
| "input": "completion_fn, input_strs, steps, settings, scalers, num_samples, temp, parallel, **kwargs", | |
| "output": "tuple(preds, completions_list, input_strs)", | |
| "location_or_namespace": "llmtime.py" | |
| }, | |
| { | |
| "function_call_name": "pd.DataFrame", | |
| "functionality": "Wrap predictions as DataFrame.", | |
| "input": "preds[i], columns=test[i].index", | |
| "output": "pandas.DataFrame", | |
| "location_or_namespace": "pandas" | |
| }, | |
| { | |
| "function_call_name": "sample.median", | |
| "functionality": "Column-wise median of predictions.", | |
| "input": "axis=0", | |
| "output": "pandas.Series", | |
| "location_or_namespace": "pandas.DataFrame" | |
| }, | |
| { | |
| "function_call_name": "mean", | |
| "functionality": "Compute mean of values.", | |
| "input": "BPDs", | |
| "output": "float", | |
| "location_or_namespace": "numpy" | |
| } | |
| ] | |
| } | |
| ] | |