Letta Filesystem To Memfs logo

Letta Filesystem To Memfs

Organization
letta-ai
letta-filesystem-to-memfs

Migrates deprecated Letta Filesystem folders/files to MemFS using markdown document corpora, chunking, local lexical search, and QMD semantic search via the memfs-search skill. Use when replacing folders.files.upload, working with PDFs or document QA, or emulating open_file, grep_file, and search_file behavior.

Overview

Publisherletta-ai
Repositoryskills
Skill nameletta-filesystem-to-memfs
Stars
144
Forks
25
Bundled files
4
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 4 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by letta-ai on GitHub. Read the source before you install it.

Installation

Install the Letta Filesystem To Memfs AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/letta-ai/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/letta/letta-filesystem-to-memfs .claude/skills/letta-filesystem-to-memfs
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Letta Filesystem To Memfs in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Letta Filesystem To Memfs on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Letta Filesystem To Memfs is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Letta Filesystem to MemFS

Use this skill when a user wants the old Letta Filesystem behavior: upload documents, chunk them, attach them to an agent, and let the agent search/open them.

MemFS is not the same product. It is git-backed markdown memory. To mimic the old workflow, use the bundled CLI:

  1. Extract PDFs/docs to markdown text.
  2. Chunk the text into stable markdown files under documents/<corpus>/<doc>/chunks/.
  3. Write a small pinned index under system/filesystem/<corpus>.md.
  4. Index only the corpus chunk files in QMD for semantic search.
  5. Review the MemFS git diff. Commit only if asked.

Quick workflow

bash
# Set this to the skill directory shown in the skill load header.
SKILL_DIR="/path/to/letta-filesystem-to-memfs"

# From any directory. MEMORY_DIR should point at the target agent's memfs repo.
uv run --with pymupdf \
  "$SKILL_DIR/scripts/letta_fs_to_memfs.py" ingest \
  --memory-dir "$MEMORY_DIR" \
  --corpus product-docs \
  --source ./docs/ \
  --source ./guide.pdf \
  --source https://arxiv.org/pdf/2310.08560

cd "$MEMORY_DIR"
git status --short
git diff --stat

Search the chunk corpus lexically:

bash
uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" search \
  --memory-dir "$MEMORY_DIR" \
  --corpus product-docs \
  "memory hierarchy" \
  -n 5

Semantic search with QMD. The CLI creates a corpus-scoped QMD collection over chunk files only:

bash
uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" qmd setup \
  --memory-dir "$MEMORY_DIR" \
  --corpus product-docs

uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" qmd query \
  --memory-dir "$MEMORY_DIR" \
  --corpus product-docs \
  "memory hierarchy" \
  -n 5

Use qmd reindex after changing corpus files, and qmd search / qmd vsearch when you specifically want keyword-only or vector-only search.

Layout

The ingest script writes:

txt
system/filesystem/<corpus>.md
  Pinned index and operating instructions for the corpus.

documents/<corpus>/manifest.md
  Corpus manifest.

documents/<corpus>/<doc-slug>/manifest.md
  Per-document metadata and chunk table.

documents/<corpus>/<doc-slug>/chunks/chunk-0001.md
  Chunk content with frontmatter metadata.

documents/<corpus>/chunks.jsonl
  Machine-readable chunk export for custom indexing or debugging.

Old API mapping

Old FilesystemMemFS mimic
folders.create--corpus <name> creates documents/<corpus>/
folders.files.uploadletta_fs_to_memfs.py ingest --source <file-or-directory-or-url>
OCR/chunk/embed jobExtract + chunk locally; qmd setup / qmd reindex for semantic search
agents.folders.attachEnable MemFS, then review and sync repo changes when appropriate
open_fileRead chunk markdown files by path
grep_filerg or letta_fs_to_memfs.py search
search_fileletta_fs_to_memfs.py qmd query over the corpus chunk collection

Heuristics

  • Use system/filesystem/<corpus>.md for the small always-visible index only.
  • Do not pin full documents into system/; it will bloat the prompt.
  • Keep chunks outside system/, usually under documents/<corpus>/....
  • Passing a directory to --source recursively ingests supported files (.pdf, .md, .txt, .json, .csv, .html, .xml).
  • Use --glob / --exclude for messy directories. Defaults exclude .git, node_modules, .venv, and __pycache__.
  • URL downloads default to --max-download-mb 100; set 0 for unlimited.
  • Re-ingesting the same document slug replaces that document's old chunk directory, so stale chunks do not survive chunk-size changes.
  • Use chunk sizes around 2,000-4,000 characters with 200-500 character overlap.
  • Use the CLI's qmd subcommands when the user needs semantic search over many chunks.
  • Preserve source URLs, checksums, page markers, chunk numbers, and corpus names in the generated files.

CLI reference

bash
uv run --with pymupdf "$SKILL_DIR/scripts/letta_fs_to_memfs.py" ingest --help
uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" search --help
uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" qmd setup --help
uv run "$SKILL_DIR/scripts/letta_fs_to_memfs.py" qmd query --help

Compatibility wrappers remain for older examples:

bash
uv run --with pymupdf "$SKILL_DIR/scripts/ingest_documents.py" --memory-dir "$MEMORY_DIR" --corpus docs --source ./docs
uv run "$SKILL_DIR/scripts/search_corpus.py" --memory-dir "$MEMORY_DIR" --corpus docs --query "refund policy"

PDF notes

The ingest script uses PyMuPDF when it sees a PDF. Run it with uv run --with pymupdf ....

For scanned PDFs or complex tables, use the tools/extracting-pdf-text skill first, then ingest the extracted markdown/text file with this skill.

See references/design.md for design notes and edge cases.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Letta Filesystem To Memfs AI skill do?

Migrates deprecated Letta Filesystem folders/files to MemFS using markdown document corpora, chunking, local lexical search, and QMD semantic search via the memfs-search skill. Use when replacing folders.files.upload, working with PDFs or document QA, or emulating open_file, grep_file, and search_file behavior.

Why use Letta Filesystem To Memfs on TypingMind?

Because you install it once and use it with any model. Letta Filesystem To Memfs is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Letta Filesystem To Memfs in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/letta-ai/skills/tree/main/letta/letta-filesystem-to-memfs. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Letta Filesystem To Memfs?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Letta Filesystem To Memfs?

As many as you like. As long as a model supports skills, you can use Letta Filesystem To Memfs with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Letta Filesystem To Memfs AI skill free?

Yes. It is published on GitHub by letta-ai under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇