agentleFS
Jakob-BachJakob-Bach/Bundes-RAG/CLAUDE.md

Bundes-RAG

CLAUDE.md2 starsChanged 5 months agoMITView on GitHub

Bundes-RAG is a tool that lets a user describe, in natural language, which documents from the Bundestag's DIP (Dokumentations- und Informationssystem für Parlamentsmaterialien) to download and index, then answer natural-language questions about them via RAG, with citations to source documents and pages. User-facing output is localized (German by default, English available via the language setting; see i18n below). It has two equivalent interfaces sharing the same data directory: a CLI (src/bundesrag/cli.py) and a web UI (FastAPI backend in src/bundesrag/web/, Vue…

  • Reads credentials
  • Installs packages

The file

We split this CLAUDE.md into the rules it gives an agent

4 rules. About 0 are common, 1 is distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Very specific:

    After editing .py files, run uv run ruff check .

    line 41
  2. Very specific:

    Every chunk also carries the document-level fields (pdf_loader.document_metadata): doc_id, dokumentnummer, titel, drucksachetyp, …

    line 120
  3. Very specific:

    After each document is embedded into the vector store, its per-document metadata (DocumentInfo, see status below) is recorded in the …

    line 129
  4. Distinctive:

    Dependency injection: all pipelines take their LLM, vectorstore, and DIP client as constructor/function arguments (not constructed …

    line 299

≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

What this is

Bundes-RAG is a tool that lets a user describe, in natural language, which documents from the Bundestag's DIP (Dokumentations- und Informationssystem für Parlamentsmaterialien) to download and index, then answer natural-language questions about them via RAG, with citations to source documents and pages. User-facing output is localized (German by default, English available via the language setting; see i18n below). It has two equivalent interfaces sharing the same data directory: a CLI (src/bundesrag/cli.py) and a web UI (FastAPI backend in src/bundesrag/web/, Vue 3 + Vite SPA in frontend/).

Commands

uv sync                  # install/sync dependencies
uv run pre-commit install  # one-time: enable lint/format checks on commit
uv run pytest            # run the test suite
uv run pytest tests/test_dip_client.py::test_name  # run a single test
uv run ruff check .      # lint
uv run ruff format .     # format
uv run bundesrag download "Plenarprotokolle der 21. Wahlperiode."  # download docs
uv run bundesrag index  # index downloaded-but-not-yet-indexed docs
uv run bundesrag ask "Welche Gesetzesvorhaben gibt es bzgl. künstlicher Intelligenz?"  # query
uv run bundesrag status  # show downloaded/indexed counts and per-file status
uv run bundesrag clear  # delete all downloaded PDFs and reset the vector store
uv run bundesrag serve  # start the web UI at http://127.0.0.1:8000/
cd frontend && npm install && npm run dev  # frontend dev server (proxies /api to :8000)
cd frontend && npm run build  # build the SPA that `serve` hosts (frontend/dist)

Requires MISTRAL_API_KEY and DIP_API_KEY in .env (copy from .env.example). Tests use the settings fixture in tests/conftest.py, which builds Settings with fake keys and _env_file=None, so no real .env or network access is needed for unit tests.

After editing .py files, run uv run ruff check . --fix && uv run ruff format . before considering the change done — don't rely on pre-commit to be the first check. Lint config lives in ruff.toml.

Architecture

Five pipelines share the same Chroma vector store (src/bundesrag/vectorstore.py), all driven from src/bundesrag/cli.py (Typer app with download, index, ask, status, clear, and serve commands; help text is English docstrings, runtime output is localized via i18n).

download pipeline (ingestion/pipeline.py: run_download):

  1. query_agent/agent.py: QueryAgent — a Mistral LLM with structured output (with_structured_output(QueryAgentResult)) turns the NL prompt into DipQueryFilters (query_agent/schema.py). If the LLM can't produce valid filters, it returns a ClarificationRequest instead; QueryAgent.build_query loops asking the user (via an injected ask_user callable) up to MAX_CLARIFICATION_ROUNDS times. Proposed filters are shown to the user for confirmation (injected confirm_filters callable); declining prompts for feedback that is fed back into the LLM conversation.
  2. dip/client.py: DipClient calls the DIP API (list_drucksachen / list_plenarprotokolle), paginating via the API's cursor until it stops advancing. Note urheber/ressort_fdf are repeated-value filters with AND semantics across distinct values in the DIP API — querying for either of two ministries/fractions needs two separate download calls. Both endpoints serve Bundestag and Bundesrat documents mixed unless the zuordnung filter (BT/BR/BV/EK) is set; the query-agent prompt instructs the LLM to set it whenever the request names a chamber ("Bundestagsplenarprotokolle" → zuordnung="BT").
  3. Documents whose PDF already exists locally are filtered out first (counted as num_skipped in the summary), so repeating a query neither re-downloads nor re-queues them for indexing. If any new documents remain, the user is asked (via an injected confirm_count callable receiving a DownloadCounts with matched / already-downloaded / to-download quantities, all three shown in the dialogue) how many of the new ones to download; entering nothing downloads all of them, entering 0 aborts (DownloadAborted), and entering a smaller number keeps only that many, most recent (datum) first. When every match already exists locally, the confirmation is skipped entirely.
  4. The remaining documents are downloaded into data/pdfs/<endpoint>/<dokumentnummer>-<doc_id>.pdf (pipeline.pdf_dest). The DIP id is part of the name because the dokumentnummer does not identify a document: both endpoints serve Bundestag and Bundesrat documents mixed unless zuordnung is set, and the chambers' numbering schemes overlap (BR-Drucksachen are serial/year, BT-Drucksachen wahlperiode/serial), so two different documents can map to one file — the first downloaded would win while the manifest recorded the second one's metadata for it. It is also what makes the dest.exists() check in step 3 a reliable "already downloaded?" test. Individual download failures are counted (num_failed) and skipped rather than aborting the run. Each downloaded PDF is recorded as a PendingDocument in the data/pending_index.json manifest (ingestion/manifest.py) for the index command to pick up later. Aborting mid-run (Ctrl+C, web cancel) leaves no bad state: PDFs are streamed to a .part temp file and renamed only once complete, and the manifest update runs in a finally, so already-downloaded documents are still queued for indexing instead of being skipped-but-never-indexed on later runs.

index pipeline (ingestion/pipeline.py: run_index):

  1. Gets the pending entries and a StatusSummary from _scan_documents (the routine shared with run_status, see status below), which prunes pending entries whose PDF was deleted manually — so the indexing loop only sees files that exist instead of failing on the first missing one. An optional on_counts callback receives an IndexCounts (documents to index vs. already indexed, the latter taken from the status summary) before the loop starts; the CLI prints it as a localized line (index_counts), the web index job stores it on the job (counts in the job response) so the SPA shows the same text while the job runs.
  2. Each PDF is parsed page-by-page (ingestion/pdf_loader.py), chunked with RecursiveCharacterTextSplitter, and given deterministic ids ({doc_id}-p{page}-{chunk_index} — keyed on the DIP id, not the dokumentnummer, which isn't unique across chambers, see download above) so re-running index on overlapping document sets upserts rather than duplicating chunks in Chroma. Because a chunk id also encodes the chunk's position, that upsert only covers runs with identical chunk settings; the indexing loop therefore deletes the document's existing chunks (vectorstore.delete(where={"pdf_path": …})) before adding the new ones, so a re-index after a chunk_size change replaces rather than accumulates. Every chunk also carries the document-level fields (pdf_loader.document_metadata): doc_id, dokumentnummer, titel, drucksachetyp, wahlperiode, herausgeber, kind, datum, pdf_path, source_url. These are the DIP record's own values, stored rather than derived — the ask filters and the status table read them back, and deriving them instead (wahlperiode from the dokumentnummer, kind from the file path, a pre-rendered label instead of the title) is what used to make them wrong. Keys whose value is None are omitted, since Chroma stores scalars only; readers must therefore use .get().
  3. After each document is embedded into the vector store, its per-document metadata (DocumentInfo, see status below) is recorded in the indexed-docs manifest (data/indexed_docs.json, add_indexed_info) and the document is removed from the pending manifest individually (remove_pending, in that order — a crash in between leaves the document pending and re-indexed later rather than indexed-but-unrecorded). The per-document removal is why download and index are separate commands: indexing many documents takes considerably longer than downloading them and can fail partway (e.g. an API rate limit), so re-running index after a failure only reprocesses documents still listed as pending, instead of redoing the whole batch.

ask pipeline (rag/answer_agent.py: answer_question):

  1. rag/retriever.py: retrieve does a similarity search against the Chroma store for settings.retrieval_top_k chunks. Both interfaces can scope the question via optional metadata filters (rag/filters.py: AskFilters: wahlperiode, date range, document kind, herausgeber (BT/BR), drucksachetyp) — the web UI as a collapsible panel in the ask view, the CLI by prompting for a key=value;key=value string after the question (see below). Chroma's range operators are numeric-only (so the ISO datum string can't be range-filtered natively), so the filters are resolved document-level against the indexed-docs manifest and passed to the similarity search as a pdf_path $in where-filter. Every field is compared against what the manifest recorded from the DIP record — nothing is re-derived, which is the fix for two old bugs: the wahlperiode was parsed out of the dokumentnummer (giving 1067 for Bundesrat protocol 1067, whose actual wahlperiode is 21) and the kind read off the file path (excluding every document whenever the manifest paths didn't sit under the configured pdf_dir). A document missing the field a filter names never matches it. Documents missing from the manifest are excluded while a filter is active; run_status rebuilds it from chunk metadata if it's lost. When no document matches, retrieval and the chat call are skipped entirely (an empty $in is invalid in Chroma) and a localized notice (ask_no_filter_match) is returned as the answer. The values each filter offers come from filters.available_facets → AskFacets (the web UI via GET /api/ask/facets, the CLI by calling it directly): the distinct values present in the indexed corpus, so a filter can only be set to something that matches at least one document — drucksachetyp in particular is an open vocabulary that can't be hardcoded. The CLI's ask command prints those values (filters.filter_options, which drops categorical keys the corpus has no value for and adds the two free-form date keys) via cli._prompt_ask_filters and reads a key1=value1;key2=value2 string, parsed by filters.parse_filter_string: empty input means no filter, anything unparseable (unknown or repeated key, value not on offer, malformed date) raises a FilterParseError whose localized message is shown before asking again. Values are matched case-insensitively but stored as the corpus spells them, since _matches compares exactly. The filter keys are the AskFilters field names, so what the user types matches what the code and this document call them.
  2. Retrieved chunks are formatted into a numbered context block (format_context); each chunk's header carries the document label with its date appended (_dated_label) so the LLM can answer time-related questions. The label is rendered from the chunk's stored titel/drucksachetyp/dokumentnummer by pdf_loader.citation_label, which deliberately produces no date of its own — so _dated_label can just append one instead of sniffing the string for a date that a fallback label might already contain (which used to swallow the date of any real title that happened to contain one). The chat LLM is instructed (German system prompt that names the configured answer language, and points out the date in the excerpt headers) to cite passages by number, to say explicitly when the context doesn't answer the question rather than guess, and to answer in settings.language.
  3. A sources list is returned alongside the answer text: one Source per retrieved chunk — deliberately not deduplicated, since Source.index must match the context numbering so a [n] in the answer resolves to exactly the chunk the LLM saw as [n]. Each carries the formatted citation (citation_for: dated label, page, document number, similarity score), the retrieved chunk text, the page, and the source PDF URL. The CLI prints [n] citation lines; the web UI (ask view) renders each [n] in the answer as a link that scrolls to and highlights that source, links each citation to the source PDF deep-linked to its page (source_url#page=N), and shows the retrieved chunk text per source in an expandable panel so users can verify the answer against it.
  4. AnswerResult.ask_stats (an AskStats from rag/ask_stats.py: compute_ask_stats — the feature is named "ask stats" throughout, distinct from the Mistral usage stats and the status summary) reports how large the searched corpus is: the number of indexed documents (len(load_indexed_info)), the total chunk count (collection_chunk_count), and retrieval_top_k; when a filter is active it also reports the matched document count and matched chunk count (summed from the manifest's per-document num_chunks, since the vector store can't be cheaply counted per filter). The CLI prints a separator between the ask-stats line, the answer, and the usage block. Both interfaces preface the answer with a localized line from these figures (ask_stats_info / ask_stats_info_filtered) — the CLI via cli._echo_ask_stats, the SPA rendering AskResponse.ask_stats. The web ask view additionally shows the same figures before the question is submitted (ask_stats_hint / ask_stats_hint_filtered, JS-only), refreshed whenever a filter changes via POST /api/ask/stats (routes_sync.ask_stats, AskStatsRequest → AskStatsResponse; uses MetadataVectorstoreDep since counting needs no embeddings), so the strength of a filter can be judged up front.

status pipeline (ingestion/pipeline.py: run_status): wraps _scan_documents, which first prunes pending entries whose PDF no longer exists on disk (deleted manually) from the pending_index.json manifest — they can never be indexed, and a stale entry would otherwise make every index run fail on the missing file — then lists every PDF under data/pdfs/ and reports each as indexed unless it still appears in the manifest. On top of that, run_status (which, unlike _scan_documents, takes the vectorstore as an argument) adds the total chunk count (a plain collection.count() via vectorstore.collection_chunk_count) plus the chunk total the indexed-docs manifest accounts for (StatusSummary.num_manifest_chunks) — when the two differ (e.g. chunks left by an index run that crashed before recording its document, or data modified outside the tool), the CLI and the SPA show a localized warning (status_chunk_mismatch) — and the disk usage of data/pdfs/ and the Chroma directory, and attaches per-document metadata (DocumentInfo on FileStatus.info, defined in ingestion/manifest.py, matched to files by PDF path). It holds the DIP record's own fields — doc id, dokumentnummer, titel, drucksachetyp, wahlperiode, herausgeber, kind, datum, source URL — stored rather than derived, because the ask filters resolve against them; plus a chunk count and two page counts. num_pages is always the PDF's own page count (pdf_loader.pdf_page_count, None if unparseable) and num_pages_with_text how many of those pages produced chunks (None until indexed): the loader skips pages with no extractable text, so a single field would otherwise mean "total pages" before indexing and "pages that yielded chunks" after, and silently drop when a document was indexed. Note there is no stored citation_label — the displayed label is rendered from titel/drucksachetyp/dokumentnummer (web/schemas.document_info_response), so the raw title stays available and nothing has to sniff a label string. Both _document_info callers build the whole thing from the DIP record: for indexed documents run_index writes it per document into the indexed-docs manifest (data/indexed_docs.json), for not-yet-indexed files it comes from the pending manifest with the two chunk-derived counts None. Indexed files missing from the manifest (deleted or unreadable file) are rebuilt via _collect_index_info — a full, slow scan of all chunk metadata in Chroma that aggregates the document-level fields — and the result is persisted so later runs stay on the fast path. The rebuild is lossless because every DocumentInfo field except the page counts is stored on the chunks themselves. Since the manifest is derived data that this rebuild can reconstruct, load_indexed_info treats an unreadable/corrupt manifest file as empty (with a log warning) instead of failing the status run. The CLI prints the high-level stats (downloaded/indexed counts, chunk count, both disk usages) and the plain per-file list; the web UI (GET /api/status) shows the same stats and a per-file table that also includes each file's document kind and the per-document metadata. FileStatus.kind prefers the document's own recorded kind, falling back to the endpoint subdirectory under data/pdfs/ for PDFs no manifest knows about (document_kind — the file name alone doesn't carry it, and Drucksache and BT-Plenarprotokoll 21/5 would otherwise be indistinguishable). The web table's columns are click-sortable; the sort choice deliberately lives outside the component as module-scope refs in frontend/src/statusSort.js (so it survives tab switches, which destroy the view) and is persisted to localStorage under bundesrag.status_sort (so it survives reloads; invalid stored values fall back to unsorted). Sorting is purely client-side — GET /api/status is unaffected. run_index starts with the same _scan_documents call, using the pending entries it returns alongside the summary, so pruning and counting live in one place.

clear pipeline (ingestion/pipeline.py: run_delete_all): removes every PDF under data/pdfs/, calls vectorstore.delete_collection() to reset the Chroma collection, and clears data/pending_index.json and data/indexed_docs.json. The CLI asks for confirmation (--yes/-y to skip it) since this is destructive and irreversible.

Single-file delete (ingestion/pipeline.py: run_delete_file, web-only — the CLI has no counterpart): the web status table has a per-file delete button (POST /api/files/delete in routes_sync.py, body {pdf_path, confirmed} with the pdf_path string from GET /api/status). It deletes the document's chunks from the vector store first (vectorstore.delete(where={"pdf_path": …}), unconditional so chunks left by an index run that crashed between embedding and manifest update are covered too), then the PDF from disk, then the pending- and indexed-docs-manifest entries. The requested path must match a file the status scan reports — anything else raises FileNotFoundError (mapped to a localized 404) — so the endpoint can't be used to delete arbitrary files outside data/pdfs/.

Dependency injection: all pipelines take their LLM, vectorstore, and DIP client as constructor/function arguments (not constructed internally), which is how the test suite substitutes fakes/mocks without touching real APIs. create_query_agent / create_chat_llm are the only places that construct real ChatMistralAI instances, and import langchain_mistralai lazily inside the function body. get_vectorstore(settings, with_embeddings=False) builds the Chroma store without a Mistral embeddings client — the MistralAIEmbeddings constructor always attempts a Hugging Face tokenizer download that fails without HF_TOKEN (gated repo; a dummy tokenizer used only for embedding-batch sizing takes over). The failing request is usually subsecond but blocks on the network and can take ~10s under HF throttling, so callers that only run metadata operations (CLI status/clear, the web MetadataVectorstoreDep used by status/clear/single-file delete) skip it; index and ask need real embeddings and keep the default.

Config (config.py: Settings): a pydantic-settings BaseSettings loading from .env; holds API keys, model names, the output language, chunk/retrieval tuning knobs, and the per-million-token prices plus currency label for the estimated-cost statistic (*_price_per_mtok, price_currency; a None price suppresses the estimate). data_dir defaults to ./data, with pdf_dir/chroma_dir/log_file derived properties.

Usage tracking (usage.py): every pipeline that calls the Mistral API creates a UsageTracker and reports its OperationUsage (chat input/output tokens, embedding tokens, call counts, wall time spent waiting on the API) on its result (DownloadSummary.usage, IndexSummary.usage, AnswerResult.usage). Chat calls are read from the response's usage_metadata (UsageTracker.record_chat; non-Mapping values from test fakes are ignored) — the query agent's structured LLM is built with with_structured_output(..., include_raw=True) so the raw AIMessage stays available, which is why StructuredLlm.invoke may return either a plain QueryAgentResult (test stubs) or the include_raw dict, and why build_query re-raises a returned parsing_error. Embedding usage can't come from LangChain (it discards the embeddings API's usage field), so UsageTracker.track_embeddings is a context manager that temporarily attaches httpx event hooks to the MistralAIEmbeddings sync client and reads each response's usage — a no-op for vector stores without a real httpx client (fakes, with_embeddings=False). Each pipeline calls record_operation(settings, kind, usage) in a finally (kinds: OPERATION_KINDS = download/index/ask), which logs the numbers and accumulates them per kind in data/usage_stats.json (UsageTotals, i.e. OperationUsage + num_operations; corrupt file degrades to empty, operations with zero API calls are skipped, and clear deliberately leaves the file alone — it tracks spend, not document state). estimate_cost turns an OperationUsage into a cost via the price settings (None when a needed price is unset). Display: the CLI prints a localized block after each operation (cli._echo_usage) and per-kind all-time totals in status (from StatusSummary.usage_totals, filled by run_status via load_usage_totals); the web API returns the same as UsageResponse/UsageTotalsResponse (built in web/schemas.py usage_response/usage_totals_response, cost computed server-side; None when the operation made no API call) on ask/job results and GET /api/status, rendered by the SPA's UsageStats.vue component and a totals block in the status view. The usage_* locale keys exist in all four catalogs (Python and JS).

i18n (i18n.py, locales/): all user-facing runtime strings go through t(key, **kwargs), which looks them up in locales/de.py / locales/en.py (AVAILABLE_LANGUAGES = ("de", "en"), default de). The language is set once per process from settings.language (set_language, called in cli._init and web.app.create_app) — it's module-level state, not passed per call. LLM system prompts (query agent, answer agent) are written in German but embed the configured language's name (locales.LANGUAGE_NAMES) so clarification questions and answers come back in that language. Yes/no confirmations use cli._confirm with i18n.yes_no_tokens() instead of typer.confirm, which only ever accepts English y/yes/n/no and would silently reject a German "j". Typer help text is localized too (*_help locale keys passed as help= to the decorators), but it's resolved when cli.py is imported — before any command's _init() — so cli.py calls set_language(config.detect_language()) at module level; detect_language reads only the language setting so that --help works without API keys, falling back to the default for unsupported values. The Vue SPA has its own vue-i18n catalogs (frontend/src/locales/de.js/en.js, Composition API mode): main.js fetches the configured language from GET /api/config before mounting (falling back to German if the API is unreachable) and sets the vue-i18n locale plus <html lang>. Catalog keys that duplicate backend strings (download_done, index_done, delete_done, ask_download_count, …) deliberately reuse the Python locale key names so drift between locales/*.py and frontend/src/locales/*.js is greppable — when changing one of these strings, update both catalogs.

Logging (logging_config.py): the bundesrag package logger writes to data/bundesrag.log (file only, INFO level, no propagation). setup_logging is idempotent per log-file path and re-points the handler when the path changes (e.g. per-test tmp_path). CLI commands log details/tracebacks there and show the user only a generic localized error message (unexpected_error) on failure. The web endpoints and job workers log the same success stats and failure tracebacks as their CLI counterparts (with a web prefix), so the log reads the same regardless of which interface ran the operation.

Progress reporting (progress.py): long multi-step CLI operations print a localized step line (German: [Schritt n/total] <name>) before each step; per-item loops (downloads, indexing) use tqdm. run_download/run_index also accept an optional on_progress(num_done, total) callback (called with (0, total) before the loop, then once per item, including failed ones); the CLI leaves it unset, the web job routes use it to store progress on the job so the SPA can render a <progress> bar while polling. run_download/run_index similarly accept an optional should_cancel() callback, checked between items (the current item always finishes first); when it returns true the pipeline raises OperationCancelled. The CLI leaves it unset — Ctrl+C fills that role there — while the web job routes wire it to the job's cancel flag.

Web layer (src/bundesrag/web/): additive over the pipelines — the only pipeline changes made for it are the optional on_progress and should_cancel callbacks above and the optional ask filters (which the CLI has since grown a prompt for too). app.py: create_app (uvicorn factory used by the serve CLI command) stores Settings and a JobManager on app.state and mounts frontend/dist as static files (path overridable via BUNDESRAG_FRONTEND_DIST; if missing, the API still runs). Fast operations (/api/ask, /api/ask/stats — the pre-ask corpus figures — /api/ask/facets — the filter values present in the indexed corpus, fetched once when the ask view mounts to populate its filter dropdowns — /api/clear, /api/status, and /api/config — which exposes settings.language for the SPA's i18n bootstrap — in routes_sync.py) are plain sync endpoints; their HTTPException details are localized via t() (as are the job-route 400/404/409 details), while the job error field stays raw exception text. Long-running ones (/api/download, /api/index in routes_jobs.py) run in a background thread via jobs.py: JobManager and are polled by the frontend (GET /api/download/{job_id}). The CLI's interactive prompts (ask_user/confirm_filters/confirm_count) are bridged to HTTP without touching QueryAgent: the injected callables block on a threading.Event in JobManager.wait_for_answer, which sets the job to waiting_input; the frontend renders the matching form and POSTs to /api/download/{job_id}/respond, unblocking the worker thread. Running or waiting jobs can be aborted via POST /api/download/{job_id}/cancel / POST /api/index/{job_id}/cancel (JobManager.request_cancel): the cancel flag makes the pipeline's should_cancel check raise OperationCancelled (a job blocked in wait_for_answer is woken and raises immediately), which JobManager._run maps to the cancelled job status the SPA displays. This design requires running the server as a single process (the job store is an in-process dict). Web tests (tests/test_web_*.py) inject fakes via app.dependency_overrides on the dependencies.py provider functions.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.