MCPcopy Create free account

hub / github.com/AdamSobieszek/langtorch / functions

Functions413 in github.com/AdamSobieszek/langtorch

Methodforward
(ctx, input, other)
src/langtorch/tt/functional.py:72
Methodforward
(ctx, input1, input2)
src/langtorch/tt/functional.py:94
Methodforward
(ctx, input, args, kwargs)
src/langtorch/tt/functional.py:124
Methodforward
(ctx, input, args=tuple(), kwargs=None)
src/langtorch/tt/functional.py:148
Methodforward
(ctx, input, p=0.5, training=True, inplace=False)
src/langtorch/tt/functional.py:179
Methodforward
(ctx, input, on, dim=0)
src/langtorch/tt/functional.py:228
Methodforward
(ctx, input, shape)
src/langtorch/tt/functional.py:249
Methodforward
(ctx, input)
src/langtorch/tt/functional.py:267
Methodforward
(ctx, input, sep="", dim=None)
src/langtorch/tt/functional.py:281
Methodforward
(ctx, input, shape)
src/langtorch/tt/functional.py:326
Methodforward
(ctx, input, axes)
src/langtorch/tt/functional.py:341
Methodforward
(ctx, input, pad, mode='constant', value='')
src/langtorch/tt/functional.py:355
Methodforward
(ctx, input, index)
src/langtorch/tt/functional.py:396
Methodforward
(ctx, input: TextTensor, target: TextTensor, prompt: TextTensor)
src/langtorch/tt/modules/to_tt/loss.py:33
Methodforward
(self, input: TextTensor, target: TextTensor)
src/langtorch/tt/modules/to_tt/loss.py:65
Methodforward
(self, input)
src/langtorch/tt/modules/to_tt/linear.py:40
Methodforward
(self, input_texttensor: TextTensor, skip_special_tokens=True, **gen_kwargs)
src/langtorch/tt/modules/to_tt/transformers.py:27
Methodforward
By default, the TextModule forward formats the input using the prompt template tensors using TextTensor multiplication,
src/langtorch/tt/modules/to_tt/textmodule.py:113
Methodforward
(self, text_tensor: TextTensor, tool_kwargs=dict())
src/langtorch/tt/modules/to_tt/assistantmodule.py:23
Methodforward
(self, input_text_tensor)
src/langtorch/tt/modules/to_tt/codemodule.py:16
Methodforward
(self, input: Tensor)
src/langtorch/tt/modules/to_tt/conv.py:272
Methodforward
(ctx, input_tensor, activation)
src/langtorch/tt/modules/to_tt/activation.py:18
Methodforward
(self, inputs)
src/langtorch/tt/modules/to_tt/activation.py:130
Methodforward
(self, input: TextTensor)
src/langtorch/tt/modules/to_tt/activation.py:187
Methodforward
r""" Args: query: Query embeddings of shape :math:`(L, E_q)` for unbatched input, :math:`(L, N, E_q)` when ``batch_first=False``
src/langtorch/tt/modules/to_tt/activation.py:263
Methodforward
(self, input_texttensor: TextTensor, skip_special_tokens=True, **gen_kwargs)
src/langtorch/tt/modules/to_t/tokenizer.py:23
Methodforward
(self, t1: TextTensor, t2: TextTensor)
src/langtorch/tt/modules/to_t/distance.py:38
Methodforward
(self, x: TextTensor)
src/langtorch/tt/modules/to_t/embedding.py:16
Methodfrom_api_responses
Text from a list of dicts of OpenAI style API responses
src/langtorch/texts/text.py:166
Methodfrom_df
(cls, df: 'DataFrame', **kwargs)
src/langtorch/tensors/texttensor.py:487
Methodfrom_file
(self, filename: str, shared: bool = False, nbytes: int = 0)
src/langtorch/types.py:49
Methodfrom_file
(cls, path, encoding="utf-8", parse: Union[bool, str] = True, **kwargs)
src/langtorch/tensors/texttensor.py:483
Methodfrom_pandoc_json
Creates a Text object from a Pandoc AST JSON string.
src/langtorch/texts/text.py:736
Functionfull
(shape, text_entry, **kwargs)
src/langtorch/utils.py:20
Functionfull_like
(other, text_entry, **kwargs)
src/langtorch/utils.py:27
Methodgenerate_nested_keys
puts each item onto a nested tuple of keys
src/langtorch/texts/text.py:430
Functiongenerate_schema_from_function
(function: Any, parameter_details: Dict[str, Dict[str, Any]] = None, hide_de
src/langtorch/api/tools.py:89
Functionget_or_create_eventloop
()
src/langtorch/api/TODO_assistant.py:8
Functionget_or_create_eventloop
()
src/langtorch/api/call.py:13
Methodget_subitems
Helper function to recursively get items, given a list of nested keys. :param items: The list of items to sea
src/langtorch/texts/text.py:412
Methodget_tensor_metadata
(self)
src/langtorch/session.py:330
Functiongrad_worker_func
The function that each worker thread runs in the parallel backward. Args: queue: The queue of nodes to process in the computational
src/langtorch/autograd/autograd.py:10
Methodguess_language
(cls, text)
src/langtorch/texts/text.py:822
Methodheaders_to_keys
Removes headers entries of the MarkdownTensor and places them as keys of their following paragraphs. If multiple header levels are pr
src/langtorch/tensors/markdowntensor.py:22
Functionhstack
(input: TextTensor, *args, **kwargs)
src/langtorch/_VariableFunctions.py:208
Methodidentity
(self)
src/langtorch/texts/text.py:225
Methodiloc
Provides index-based indexing for TextTensor, leveraging the `iloc` method of the Text entries. You can access and manipulate sub-ele
src/langtorch/tensors/texttensor.py:439
Methodiloc
Index-based indexing. You can access entries with nested keys using dot notation, e.g. .loc["key1.key2"]
src/langtorch/texts/text.py:331
Methodinput_formatter
(cls, content)
src/langtorch/tensors/codetensor.py:21
Methodinput_formatter
(cls, content)
src/langtorch/tensors/chattensor.py:11
Methodinspect
(self)
src/langtorch/tensors/texttensor.py:642
Methodinspect
(self)
src/langtorch/texts/text.py:726
Methodis_shared
(self)
src/langtorch/types.py:34
Functionis_valid_tree
Checks if an entry is a valid tree for a Text instance.
src/langtorch/grammars/text_content_ast.py:121
Methoditem_to_tt
(cls, k, v, parse)
src/langtorch/tensors/texttensor.py:187
Functioniter_subarrays
(arr, dim)
src/langtorch/utils.py:46
Methodkeep_history_hook
(module, input, output)
src/langtorch/tt/modules/to_tt/activation.py:126
Methodkeyed_print
Prints the Text instance with keys aligned over their corresponding values.
src/langtorch/texts/text.py:179
Functionlangtorch_parser
(txt)
src/langtorch/grammars/parsers.py:19
Methodlinter
(cls, tensor)
src/langtorch/tensors/chattensor.py:22
Methodloc
Provides key-based indexing for TextTensor, leveraging the `loc` method of the Text entries. You can access and manipulate sub-elemen
src/langtorch/tensors/texttensor.py:415
Methodloc
Key-based indexing. You can access entries with nested keys using dot notation, e.g. .loc["key1.key2"]
src/langtorch/texts/text.py:392
Methodlower
(self)
src/langtorch/texts/text.py:732
MethodmT
(self)
src/langtorch/tensors/texttensor.py:883
Functionmake_grads
(outputs: Sequence[torch.Tensor], grads: Sequence[_OptionalTensor], is_grads_batched: bool)
src/langtorch/utils.py:103
Methodmatch_mul_rule
(k, v, k_, v_, i, result, formatted_indices, indices_to_delete)
src/langtorch/texts/text.py:592
Functionmean
(input: TextTensor, definition: str = "a text that is of similar length to the entries, synthesises c
src/langtorch/semantic_algebra.py:17
Methodmetadata
(self)
src/langtorch/tensors/texttensor.py:567
Methodnbytes
(self)
src/langtorch/types.py:40
Functionoverride
(func)
src/langtorch/api/utils.py:5
Functionpad_sequences_and_create_masks
(token_lists)
src/langtorch/utils.py:197
Functionpandoc_to_ast_from_file
Converts a given file into a Pandoc AST JSON format. Args: file_path (str): The path to the file to be converted. Returns:
src/langtorch/grammars/pandoc.py:132
Functionparse_content
(content, parser)
src/langtorch/grammars/text_content_ast.py:11
Methodpath
(self)
src/langtorch/session.py:162
Functionpositive_indices
Change negative to positive indices, handling newaxis (None) and slices. Parameters: - indices: a tuple containing integer indices, slic
src/langtorch/utils.py:151
Methodpre_forward_hook
(module, input: List[TextTensor])
src/langtorch/tt/modules/to_tt/textmodule.py:78
Functionprint_schema
(dictionary)
src/langtorch/api/tools.py:7
Functionprocess_api_requests_from_file
Processes API requests in parallel, throttling to stay under rate limits.
src/langtorch/api/TODO_gcp.py:13
Methodprompt
(self)
src/langtorch/tt/modules/to_tt/textmodule.py:94
Methodprompts
(self, ids)
src/langtorch/session.py:212
Methodproperty_func
(self)
src/langtorch/session.py:306
Methodreduction_hook
(module, input, loss)
src/langtorch/tt/modules/to_tt/loss.py:22
Methodreload
(self)
src/langtorch/session.py:165
Methodreplace_tuple_with_ttype
(tpl)
src/langtorch/tensors/texttensor.py:115
Functionreshape
(input: TextTensor, *args, **kwargs)
src/langtorch/_VariableFunctions.py:194
Functionrevise_your_answer
Agent decides to revise their answer based on the other agent's response. Parameters: thought (str): The internal thought process
src/langtorch/api/tools.py:151
Functionrun_backward
Run the backward pass using the execution engine. Args: tensors: List of tensors for which to compute gradients. grad_tensor
src/langtorch/autograd/autograd.py:64
Methodsave
(self, path: str)
src/langtorch/texts/text.py:844
Functionset_defaults_from_ctx
Use this decorator to set args with the value "default" to values from the context configuration. Example: @set_defaults_from_ctx
src/langtorch/decorators.py:10
Methodset_key_
(self, keys)
src/langtorch/tensors/texttensor.py:526
Methodshare_memory_
(self)
src/langtorch/types.py:37
Methodsort_key
(index)
src/langtorch/texts/text.py:674
Methodsplit
Return a new TextTensor, with an additional first dimension to split everything using sep as the delimiter. sep The de
src/langtorch/tensors/texttensor.py:996
Functionsqueeze
(input: TextTensor, *args, **kwargs)
src/langtorch/_VariableFunctions.py:186
Methodstep
Perform a single optimization step. This method updates the parameters of the optimizer by generating new text using the engine and u
src/langtorch/optim/optimizer.py:108
Methodstr_formatter
(cls, instance)
src/langtorch/texts/thread.py:8
Methodstr_formatter
(cls, instance)
src/langtorch/texts/code.py:8
Functionswapaxes
(input: TextTensor, *args, **kwargs)
src/langtorch/_VariableFunctions.py:198
Functiontensor_or_tensors_to_tuple
(tensors: Optional[_TensorOrTensors], length: int)
src/langtorch/torch_utils.py:9
Functiontensor_or_tensors_to_tuple
(tensors: Optional[_TensorOrTensors], length: int)
src/langtorch/utils.py:59
← previousnext →301–400 of 413, ranked by callers