gitmyhub

llama-fs

TypeScript ★ 5.7k updated 10mo ago

A self-organizing file system with llama 3

LlamaFS automatically renames and sorts your messy files using AI. Point it at a folder and it figures out sensible names and folder structures based on what your files actually contain, no manual sorting needed.

PythonFastAPIElectronTypeScriptLlama 3Groq APIMoondreamWhispersetup: moderatecomplexity 2/5

LlamaFS is a file organizer that uses an AI model to automatically rename and sort files based on their content. The problem it addresses is the common situation where a Downloads folder or Desktop fills up with poorly named files over time. Instead of manually sorting them, you point LlamaFS at a directory and it figures out sensible names and folder structures based on what the files actually contain.

The tool works in two modes. In batch mode, you give it a folder and it suggests a reorganized file structure for you to review and apply. In watch mode, it runs in the background and observes how you personally organize files. If you create a folder called "2023 Taxes" and move a couple files into it, LlamaFS picks up the pattern and starts moving similar files there automatically on your behalf.

Under the hood, the tool uses the Llama 3 language model via Groq's fast cloud API to read and summarize file contents. For images it uses a model called Moondream, and for audio files it uses Whisper. Because all of this runs through a cloud API, there is a privacy concern about sending personal files to an external service. The project addresses this with an incognito mode that routes everything through Ollama instead, which runs the same Llama 3 model locally on your machine.

The backend is written in Python using FastAPI, and the frontend is an Electron desktop application. Most file decisions in watch mode are processed in under 500 milliseconds according to the README, which attributes this to smart caching that only updates the parts of the file index that changed.

Installation requires Python 3.10 or higher, a Groq API key for cloud mode, and optionally Ollama for the privacy-preserving local mode.

Where it fits