aiq.tool.github_tools.get_github_file#

Classes#

GithubGetFileToolConfig

Tool that returns the text of a github file using a github url starting with github and ending

GithubGetFileLinesToolConfig

Tool that returns the text lines of a github file using a github url starting with

Functions#

github_text_from_url(config, builder)

github_text_lines_from_url(config, builder)

Module Contents#

class GithubGetFileToolConfig(/, **data: Any)#

Bases: aiq.data_models.function.FunctionBaseConfig

Tool that returns the text of a github file using a github url starting with github and ending with a specific file.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

async github_text_from_url(
config: GithubGetFileToolConfig,
builder: aiq.builder.builder.Builder,
)#
class GithubGetFileLinesToolConfig(/, **data: Any)#

Bases: aiq.data_models.function.FunctionBaseConfig

Tool that returns the text lines of a github file using a github url starting with github and ending with a specific file line references. Examples of line references are #L409-L417 and #L166-L171.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

async github_text_lines_from_url(
config: GithubGetFileLinesToolConfig,
builder: aiq.builder.builder.Builder,
)#