agentleFS
OpenMinedOpenMined/PySyft/CLAUDE.md

PySyft

CLAUDE.md10k starsChanged 13 days agoApache-2.0View on GitHub

Guidance for Claude Code in this repository. This file is checked in and shared with the team. Put personal instructions in a CLAUDE.local.md next to this file; git ignores it. Follow these guidelines when you write code, PR descriptions or reviews. The syft-pr-review skill rates PRs against the same guidelines. @dev-guidelines/guidelines.md @dev-guidelines/language.md If keeping an import at the top of a file causes a hard circular import, ask the user whether to resolve it now or later. Open PRs with…

  • Installs packages

Trending

Quiet since September.about the whole repository

Jan 2026: 0 mentionsFeb 2026: 0 mentionsMar 2026: 0 mentionsApr 2026: 0 mentionsMay 2026: 0 mentionsJun 2026: 0 mentionsJul 2026: 0 mentionsAug 2026: 0 mentionsSep 2026: 1 mentionOct 2026: 0 mentionsNov 2026: 0 mentionsDec 2026: 0 mentions
Jan 2026Jul 2026Dec 2026
Mentions a month of the OpenMined/PySyft repository that our weekly crawl found. There is no adoption data for this file yet.

Who's talking about OpenMined/PySyft

The biggest 5 of 66 mentions linking to the repository that our crawl found. Each line is their own headline.

See all 66

Talked about on GitHub, YouTube, Hacker News and Stack Overflow (66 times).

On GitHub · 50

45 more on GitHub

On YouTube · 7

2 more on YouTube

The file

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

5 rules. About 0 are common, 2 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    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
  1. Very specific:

    Follow these guidelines when you write code, PR descriptions or reviews.

    line 8
  2. Distinctive:

    If keeping an import at the top of a file causes a hard circular import, ask the user whether to resolve it now or later.

    line 14
  3. Very specific:

    When you run unit tests with pytest directly, pass -n auto.

    line 35
  4. Distinctive:

    File-first: All state communicated via synced files

    line 43
  5. Very specific:

    Read the file that matches your task before you start.

    line 91

≈ “Common” is an estimate: at least 1 in 5 of the 29,248 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

Guidance for Claude Code in this repository. This file is checked in and shared with the team. Put personal instructions in a CLAUDE.local.md next to this file; git ignores it.

Guidelines

Follow these guidelines when you write code, PR descriptions or reviews. The syft-pr-review skill rates PRs against the same guidelines.

@dev-guidelines/guidelines.md @dev-guidelines/language.md

If keeping an import at the top of a file causes a hard circular import, ask the user whether to resolve it now or later.

Pull requests

Open PRs with the open-pr skill. It runs pre-commit, writes a conventional-commit title, and fills in the PR template.

Commands

uv pip install -e .        # install (uses uv)

just test-unit-fast        # fast unit tests; always run these first
just test-unit             # all unit tests
just test-integration      # integration tests (slow, real API); only run in the nightly build

uv run pytest ./tests/unit/test_sync_manager.py                      # one file
uv run pytest ./tests/unit/test_sync_manager.py::test_function_name  # one test

When you run unit tests with pytest directly, pass -n auto.

Architecture

Syft-client is a privacy-preserving data collaboration framework enabling secure file syncing and job execution across peer-to-peer networks. It uses a file-first communication paradigm with transport-agnostic channels (currently Google Drive Files API).

Core Design Principles

  • File-first: All state communicated via synced files
  • Transport-agnostic: Works with any message-delivery mechanism
  • Offline-first: Full functionality when peers are offline
  • Peer-first: Explicit peer authorization required

Two modes

PySyft runs in one of two modes, and a setup uses only one of them. Check which mode a task is about before you change jobs, roles or approvals, because the flows differ. In both modes, the DOs and the DS use SyftboxManager as the main orchestrator.

Mode 1: DO and DS

There are two roles:

  • Data Scientist (DS): sees only the mock data. The DS submits a job to run on a DO's private data, and gets the results back.
  • Data Owner (DO): holds the private data. The DO reviews each job, approves it, runs it on the private data on its own machine, and returns the results to the DS.

Mode 2: Enclave

An enclave is a sealed confidential-compute environment (a TEE) that runs an open-source docker container with syft, and syncs through Google Drive like any other peer. This mode usually has three roles: two DOs, for example one with a private benchmark and one with a private model, and a DS who writes the analysis that brings their data together. The enclave runs the job, not a DO, and only once every DO has approved it, so no party sees another party's data. The code is in packages/syft-enclave; start with its docs/flow.md.

Workspace packages

The packages in packages/ are uv workspace members:

  • syft-job: job submission and execution (bash/Python jobs with venv isolation)
  • syft-datasets: dataset management and sharing
  • syft-rds: the remote data science client, datasets and jobs on top of the sync engine
  • syft-permissions: the permission system for datasites
  • syft-perms: the user-facing permission API
  • syft-bg: background services, with a TUI dashboard
  • syft-enclave: runs PySyft on an enclave
  • enclave-model-api-example: an example LLM inference API on top of syft-enclave
  • syft-restrict: verifies that JAX/Flax inference code only does math, and hides the model architecture
  • syft-migration: versioning and on-the-fly migration of syft objects
  • syft-notebook-ui: Jupyter notebook display utilities

More detail

Read the file that matches your task before you start. They are in dev-guidelines/architecture/.

  • sync-flow.md: how a sync pass moves changes between the DS and the DO, and how events and messages are stored. Read it when you work on sync, events or messages.
  • peers.md: how a DS requests access and the DO approves it. Read it when you work on peers.
  • datasets.md: how the DO creates a dataset and the DS reads it. Read it when you work on datasets.
  • jobs.md: how a job is submitted, approved, run, and its results returned. Read it when you work on jobs.

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.