Open vjz3qz opened 1 week ago
from llama_index.readers.github import GithubRepositoryReader, GithubClient
def initialize_github_client(github_token):
return GithubClient(github_token)
github_client = initialize_github_client(github_token)
loader = GithubRepositoryReader(
github_client,
owner=owner,
repo=repo,
filter_file_extensions=(
[".py", ".ipynb", ".js", ".ts", ".md"],
GithubRepositoryReader.FilterType.INCLUDE,
),
verbose=False,
concurrent_requests=5,
)
docs = loader.load_data(branch="main")
llama index includes support
Instead of just cloning a public github url, we should use the github api and be able to clone a private repo