Codefetch icon

Codefetch

266

Converts code into Markdown format for use with Large Language Models (LLMs) through a simple terminal command.

About

Codefetch simplifies the process of preparing code for analysis by Large Language Models (LLMs). It fetches code files from a specified directory, respecting .gitignore and .codefetchignore, and outputs them into a single Markdown file, complete with line numbers. Features include filtering by file extension, including or excluding specific files/directories, generating a project tree, and adding prompts for specific instructions to the LLM. Token limiting strategies and various token counting methods are also supported to optimize output for different AI models.

Key Features

  • Supports filtering files by extension and excluding directories.
  • Includes prompt support for guiding LLM analysis.
  • Offers token limiting strategies for large codebases.
  • 266 GitHub stars
  • Converts code to Markdown format with line numbers.
  • Generates a visual project tree representation.

Use Cases

  • Preparing code for analysis and review by LLMs.
  • Generating Markdown documentation from a codebase.
  • Integrating code snippets into AI-powered tools like bolt.new and cursor.com.
Craft Better Prompts with AnyPrompt
Sponsored