GitHub Repo RAG Extractor - LLM context for repositories avatar

GitHub Repo RAG Extractor - LLM context for repositories

Pricing

from $2.10 / 1,000 processed repositories

Go to Apify Store
GitHub Repo RAG Extractor - LLM context for repositories

GitHub Repo RAG Extractor - LLM context for repositories

Extract repository files and RAG chunks from public GitHub repositories. Includes the path, source URL and chunk text. Public repositories you name, with a repository charge and a file charge. Results as JSON, CSV or Excel. Access through API or MCP.

Pricing

from $2.10 / 1,000 processed repositories

Rating

0.0

(0)

Developer

Muhammet Mustafa Dincer

Muhammet Mustafa Dincer

Maintained by Community

Actor stats

0

Bookmarked

1

Total users

1

Monthly active users

21 days ago

Last modified

Features

Limited permissions

Share

šŸ¤– What does the GitHub repo extractor do?

A GitHub repo extractor reads repository files and RAG chunks from public GitHub repositories. It can collect:

  • repository files and RAG chunks from public GitHub repositories
  • the path, source URL and chunk text
  • A saved baseline when the source compares the next run
  • JSON, CSV or Excel from the dataset
  • The same run through the Apify API or MCP

šŸ’” Why use the GitHub repo extractor?

People use a GitHub repo extractor when the same public page would otherwise be checked by hand.

  • Watch a change. The Actor keeps a baseline and writes the next difference.
  • Feed a sheet. The dataset opens as JSON, CSV or Excel.
  • Call it from code. The Apify API runs the same input.
  • Hand it to an agent. Apify MCP can call the Actor with that input.
  • Stay on the sample. The prefilled input is the short, cheap run.

šŸš€ How do you run the GitHub repo extractor?

  1. Open this Actor and click Try for free.
  2. Keep the prefilled sample, or set the prefilled fields.
  3. Leave the other fields on their defaults unless you need a narrower run.
  4. Click Run.
  5. Open the Dataset tab and download JSON, CSV or Excel.

Sample input from the prefilled schema:

{
"repositories": [
"https://github.com/expressjs/express"
],
"mode": "chunks",
"chunkSize": 512,
"chunkOverlap": 64,
"paths": [
"lib",
"Readme.md"
],
"redactSecrets": true,
"includeMetadata": true,
"buildContextFile": true,
"contextTokenBudget": 100000,
"maxRepositories": 100,
"maxFilesPerRepository": 500,
"maxFileKb": 256,
"maxArchiveMb": 100,
"maxChunksPerRepository": 5000
}

āš ļø What limits does this Actor have?

The input schema is the limit. Defaults and prefills are unchanged by this copy update.

  • repositories: at most 100 items.
  • chunkSize: maximum 4096, minimum 64.
  • chunkOverlap: maximum 2048, minimum 0.
  • contextTokenBudget: maximum 1000000, minimum 1000.
  • maxRepositories: maximum 100, minimum 1.
  • maxFilesPerRepository: maximum 5000, minimum 1.
  • maxFileKb: maximum 2048, minimum 1.
  • maxArchiveMb: maximum 500, minimum 1.
  • maxChunksPerRepository: maximum 10000, minimum 10.
  • Actor Start is priced in the table. The other events are billed only when the source charges them and the charge is accepted.
  • A spending limit that cannot pay for the next event stops that event. The source does not invent a result to replace it.

šŸ’³ How much does the GitHub repo extractor cost?

The table is the live pay-per-event price list (pricingInfos) for this Actor. It is not a guessed price.

EventWhat the price list calls itFreeBronzeSilverGoldPlatinumDiamond
apify-actor-startActor Start$0.0005$0.0005$0.0005$0.0005$0.0005$0.0005
repository-processedProcessed repository$0.003$0.0027$0.0024$0.0021$0.0021$0.0021
file-processedProcessed file$0.0001$0.00009$0.00008$0.00007$0.00007$0.00007

One Free-plan run that bills one repository-processed plus Actor Start is $0.0005 + $0.003 = $0.0035. 1,000 repository-processed events on the Free plan are $3.00, before Actor Start. These figures use only the live prices in the table.

apify-actor-start is in the live price list. Charged when the Actor starts running. Number of events charged depends on Actor memory (one event per GB, minimum one event). The source names repository-processed and charges it with Actor.charge when that event happens. One repository that was downloaded and had at least one readable file. Missing, private-without-token, oversized, blocked and empty repositories are not charged. The source names file-processed and charges it with Actor.charge when that event happens. One source, documentation or config file that was read, masked and chunked. Charged per file, so a 400-file monorepo costs more than a 5-file library; skipped files (lockfiles, binaries, build output, over the size limit) and chunk count never change the price.

šŸ“ What input does this Actor take?

Required fields are marked. Defaults and prefills are the quick run; this text does not change them.

FieldRequiredWhat it means
repositories (GitHub repositories)NoOne per line. Accepts https://github.com/owner/repo, a link into a branch or folder ...
datasetId (Read repositories from a dataset)NoOptional. Pick an Apify dataset whose items contain GitHub repository links, for example the outp...
mode (What to return)NoChunks writes one repository row plus one row per token-counted chunk, which is what an em...
chunkSize (Chunk size (tokens))NoToken budget per chunk, counted with the cl100k_base tokenizer that OpenAI embedding and chat mod...
chunkOverlap (Chunk overlap (tokens))NoText from the end of one chunk repeated at the start of the next, in whole lines, so a function t...
ref (Branch, tag or commit)NoRead this ref instead of the default branch. A /tree/… link or owner/repo@ref<...
paths (Folders or files)NoOnly read these folders or files (paths from the repository root, one per line, case does not mat...
includePatterns (Include patterns)NoGlob patterns a file must match to be read, for example .py or src/**/.ts</c...
excludePatterns (Exclude patterns)NoGlob patterns to leave out, for example **/*.test.ts or docs/ (a traili...
redactSecrets (Mask secrets)NoReplace private keys and well-known token formats (AWS, GitHub, Slack, Stripe, OpenAI, Google, np...
includeMetadata (Add repository metadata)NoAdd description, stars, forks, topics, default branch and last push from the GitHub API with one ...
buildContextFile (Write a Markdown context file)NoSave one CONTEXT-owner-repo.md per repository to the key-value store: directory tree...
contextTokenBudget (Context file budget (tokens))NoThe context file stops adding files when this many tokens are reached, so it always fits the mode...
maxRepositories (Maximum repositories per run)NoUpper bound on how many repositories are processed in one run, after the list and the dataset are...
maxFilesPerRepository (Maximum files per repository)NoStop after this many files. Files are read in priority order (README, license, docs, source, test...
maxFileKb (Maximum file size (KB))NoSkip files larger than this. Large files are usually data dumps, generated code or logs.
maxArchiveMb (Maximum archive size (MB))NoRefuse repositories whose compressed archive is larger than this, before reading anything. For a ...
maxChunksPerRepository (Maximum chunks per repository)NoSafety cap on chunk rows for one repository. A very small chunk size on a very large repository w...
githubToken (GitHub token (optional))NoA personal access token with read access to contents. Needed only for private repositories and fo...

šŸ“Š What output does this Actor return?

The dataset schema names every stored field.

FieldWhat the schema says
recordTypeRow kind: repository (one per repository, always written), chunk (one...
inputRepository rows only: the reference exactly as it was given. Stable b...
repositoryowner/name of the repository. On repository rows this is null only wh...
urlRepository rows only: the repository home page.
statusRepository rows only: processed (files were read and charged), empty ...
failureReasonRepository rows only, when status is not processed: invalid_reference...
messageRepository rows only: a sentence that explains a failure, an empty re...
ownerRepository rows only: the account that owns the repository.
nameRepository rows only: the repository name.
refBranch, tag or commit that was read. Null means the default branch wa...
commitShaExact commit the archive was built from. Chunk and file rows carry it...
subPathRepository rows only: the folders the run was limited to, from the Fo...
descriptionRepository rows only: the About text of the repository. Needs include...
starsRepository rows only: stargazers at the time of the run.
forksRepository rows only: forks at the time of the run.
openIssuesRepository rows only: open issues and pull requests.
topicsRepository rows only: topics set on the repository.
primaryLanguageRepository rows only: the language GitHub reports as the main one.
defaultBranchRepository rows only: the default branch.
pushedAtRepository rows only: when the last push happened, ISO 8601.
archivedRepository rows only: true when the repository is archived (read-only).
homepageRepository rows only: the homepage URL set on the repository.
licenseRepository rows only: SPDX identifier, detected from the LICENSE text...
licenseSourceRepository rows only: license_file or github_api, so you know how muc...
metadataStatusRepository rows only: ok, unavailable (the GitHub API refused or was ...
fileCountRepository rows only: files that were read and charged for.
archiveFileCountRepository rows only: every file in the archive, before any filter.
chunkCountRepository rows only: how many chunk rows this repository produced. N...
tokenCountTokens in the file text (repository and file rows) or in the chunk te...
charCountCharacters of text in this row.
languagesRepository rows only: files and tokens per language, top 15 by tokens.
skippedFilesRepository rows only: how many files were left out and why: excluded_...
truncatedRepository rows only: true when a limit stopped the run on this repos...
truncatedReasonRepository rows only: file_limit, chunk_limit, text_size_limit or bud...
secretsRedactedRepository rows: how many secret-looking values were replaced with [R...
secretTypesRepository rows only: which kinds of secrets were redacted.
archiveBytesRepository rows only: size of the downloaded archive.
directoryTreeRepository rows only: indented folder tree of the files that were rea...
contextFileKeyRepository rows only: key of the single-file Markdown digest in the r...
contextFileUrlRepository rows only: link to that digest. One file, directory tree p...
contextFileTokensRepository rows only: tokens in the digest, always within contextToke...
durationMsRepository rows only: how long this repository took.
scrapedAtRepository rows only: when the row was written, ISO 8601.
pathChunk and file rows: path inside the repository.
languageChunk and file rows: language from the file name, or null when the ty...
chunkIndexChunk rows: position of the chunk within its file, starting at 0.
fileChunkCountChunk rows: how many chunks the file produced.
textChunk rows: the chunk text. File rows: the whole file text (secrets r...
lineStartChunk rows: first line of the chunk in the file, 1-based.
lineEndChunk rows: last line of the chunk. Together with lineStart this is t...
citationChunk rows: path:lineStart-lineEnd, the string to show next to an ans...
sourceUrlChunk and file rows: GitHub link to the exact lines at the exact commit.
headingsChunk rows from Markdown-like files: the headings the chunk sits unde...
isPartialChunk rows: true when a single line was longer than the chunk size an...
sizeBytesFile rows: size of the file in the archive.
lineCountFile rows: number of lines.

One record from assets/sample-run-data.json shipped with this Actor, shortened where a string is long.

{
"recordType": "chunk",
"repository": "expressjs/express",
"ref": null,
"commitSha": "43fca52d28a422c8be48fd489cbd4f2d6152bab6",
"path": "Readme.md",
"language": "Markdown",
"chunkIndex": 1,
"fileChunkCount": 8,
"text": "```js\nimport express from 'express'\n\nconst app = express()\n\napp.get('/', (req, res) => {\n res.send('Hello World')\n})\n\napp.listen(3000, () => {\n console.log('Server is running on ...",
"tokenCount": 395,
"charCount": 1594,
"lineStart": 36,
"lineEnd": 87,
"citation": "Readme.md:36-87",
"sourceUrl": "https://github.com/expressjs/express/blob/43fca52d28a422c8be48fd489cbd4f2d6152bab6/Readme.md#L36-L87",
"headings": [
"Table of contents",
"Installation",
"Features",
"Docs & Community"
],
"isPartial": false
}

šŸ”Œ How do you call this Actor from the API?

Call mmdincer/github-repo-rag-extractor with the Apify API. The body is the input schema. MCP clients on Apify use the same input. Make and Zapier can start the Actor through Apify's integration. The input is the same JSON.

from apify_client import ApifyClient
client = ApifyClient("<APIFY_TOKEN>")
run = client.actor("mmdincer/github-repo-rag-extractor").call(run_input={"repositories": ["https://github.com/expressjs/express"], "mode": "chunks", "chunkSize": 512, "chunkOverlap": 64, "paths": ["lib", "Readme.md"], "redactSecrets": true, "includeMetadata": true, "buildContextFile": true, "contextTokenBudget": 100000, "maxRepositories": 100, "maxFilesPerRepository": 500, "maxFileKb": 256, "maxArchiveMb": 100, "maxChunksPerRepository": 5000})
items = client.dataset(run["defaultDatasetId"]).list_items().items
import { ApifyClient } from "apify-client";
const client = new ApifyClient({ token: "<APIFY_TOKEN>" });
const run = await client.actor("mmdincer/github-repo-rag-extractor").call({"repositories": ["https://github.com/expressjs/express"], "mode": "chunks", "chunkSize": 512, "chunkOverlap": 64, "paths": ["lib", "Readme.md"], "redactSecrets": true, "includeMetadata": true, "buildContextFile": true, "contextTokenBudget": 100000, "maxRepositories": 100, "maxFilesPerRepository": 500, "maxFileKb": 256, "maxArchiveMb": 100, "maxChunksPerRepository": 5000});
const { items } = await client.dataset(run.defaultDatasetId).listItems();

ā“ What else should you know?

Does the GitHub repo extractor need a login?

The sample run uses the public source and the prefilled input. A field that asks for your own key is optional unless the input schema marks it required.

What does the GitHub repo extractor charge for?

The primary event in the live price list is repository-processed (Processed repository). Actor Start is separate. An event the source does not call is not billed by the source.

Can this Actor run on a schedule?

Yes. Save the input and schedule it. The next run compares against the baseline when the source stores one.

Where do the results go?

Results land in the run dataset. Download JSON, CSV or Excel, or read them with the API.

You are responsible for the source terms and for privacy law that applies to you, including the GDPR if you handle personal data. This Actor stores the public fields described above. This Actor is not affiliated with GitHub.

Not affiliated with GitHub. Source license: Apache-2.0. Not affiliated with GitHub.

Other public Actors from mmdincer in this group:

Run the GitHub repo extractor again when you want a fresh GitHub check.

Run the GitHub repo extractor again when you want a fresh GitHub check.