Agent skill

Polylith Sync

by DavidVujic in DavidVujic/python-polylith

Run poly sync to update each project's [tool.polylith.bricks] table with the bricks actually imported.

MITAuto-check passed

Install Polylith Sync

skills CLI
$ npx skills add DavidVujic/python-polylith --skill polylith-sync -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install DavidVujic/python-polylith polylith-sync --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/DavidVujic/python-polylith.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/polylith/polylith-sync .claude/skills/polylith-sync && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
polylith-sync
GitHub stars
553
Token cost
~1.3k tokens
SKILL.md length
563 words
Files
1
Skills in repo
37
Repo updated
First seen
Licence
MIT

At a glance

Run poly sync to update each project's [tool.polylith.bricks] table with the bricks actually imported.

  • SKILL.md covers Quick command, When to run, What it does and Command reference, plus 4 more sections
  • Calls uv, poetry and git

What it does

Polylith Sync is an agent skill from DavidVujic/python-polylith. Run poly sync to update each project's [tool.polylith.bricks] table with the bricks actually imported. Use this whenever a brick is added, removed, or its imports change — and before poly check or a release.

Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

The repository describes itself as: Tooling support for the Polylith Architecture in Python. The licence is MIT.

Example prompts

  • “/polylith-sync”

What it can do on your machine

Read from SKILL.md and the folder at commit a7a80f2. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • uv
    • poetry
    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use uv and git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Polylith Sync loads about 1.3k tokens when it runs. Until then it costs about 57 tokens; SKILL.md has 563 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~57
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from DavidVujic/python-polylith at commit a7a80f2, republished under its MIT licence (© DavidVujic). 563 words, ~1,277 tokens.

Download SKILL.mdSave it as .claude/skills/polylith-sync/SKILL.md (or your agent's skills folder).
name
polylith-sync
description
Run `poly sync` to update each project's `[tool.polylith.bricks]` table with the bricks actually imported. Use this whenever a brick is added, removed, or its imports change — and before `poly check` or a release.

Sync Skill

💡 Terminology: this skill uses Polylith terms like brick, project, and development project. If they're unfamiliar, load polylith-concepts first.

Quick command

bash
uv run poly sync --quiet

⚠ Agents must pass --quiet. poly sync has an interactive mode that will prompt on stdin and hang the process if no human is attached. --quiet suppresses output and disables the interactive prompts. Never use --verbose in an agent run — it is the opposite of --quiet and can trigger interactive mode. Save --verbose for humans who are debugging at a terminal.

Command prefix: If you do not know the package manager, list lock files with ls uv.lock poetry.lock pdm.lock 2>/dev/null (a pyproject.toml is always present, so it tells you nothing on its own). Use uv run poly (uv), poetry poly (poetry), pdm run poly (pdm), hatch run poly (hatch), or poly (activated venv). Examples below use uv run.

When to run

  • After poly create base / poly create component — registers the new brick in the development project.
  • After poly create project — only if the interactive prompt was skipped.
  • After adding a new import between bricks — picks up the transitively pulled-in brick.
  • Before poly check and before any release/CI run.

⚠ poly sync adds missing bricks but does not remove unused ones. Stale entries in [tool.polylith.bricks] must be deleted by hand. It also does not sync third-party libraries — use poly libs / poly check for those.

What it does

  • Per project under projects/: resolves the project's base(s), walks the import graph, and adds any imported brick missing from [tool.polylith.bricks].
  • For the development project (root pyproject.toml): always lists every base and every component in the workspace.

Command reference

OptionDefaultDescription
--directorycwdSync only projects whose path matches this directory.
--quietfalseSuppress all output and disable interactive prompts. Exit code unchanged. Required for agent runs.
--verbosefalsePrint detailed information about each sync operation. Can trigger interactive mode — for human/terminal use only.

Examples

bash
# Agent / CI default — non-interactive, no output
uv run poly sync --quiet

# Agent: only one project, still non-interactive
uv run poly sync --quiet --directory projects/user_api

# Human, at a terminal: verbose for debugging missing bricks (may prompt!)
uv run poly sync --verbose
Output

Nothing changed:

✔ project-a
✔ project-b
✔ development

A brick was added:

👉 the-cli
adding greeting component to the-cli
Show full SKILL.md (245 more words)Show less

Notes for the agent

  • Always run with --quiet. Without it, poly sync may drop into an interactive prompt and hang the process — agents cannot answer stdin prompts. Never combine with --verbose, which leans the other way and can trigger interactive mode.
  • The exit code is always 0 — poly sync is informational, not a gate. For a CI gate, follow it with poly check (load polylith-check).
  • If a brick is showing up in unexpected projects after sync, it's because something the project's base imports (transitively) imports that brick. Trace it with poly deps --brick <name> (load polylith-dependency-visualization).
  • Git reminder: If poly sync adds missing bricks to any pyproject.toml files, use your git tools to review the diff and ensure those changes are committed. Because --quiet suppresses output, the agent should rely on git diff (or re-run poly info) to confirm what changed.

Background — the development project

The root pyproject.toml doubles as a "development project": a single virtual environment that includes every brick and every dependency (production and dev-only). The development/ directory holds REPL scripts and notebooks that import bricks freely. poly sync keeps the development project complete by listing every brick in the workspace there. Per-project pyproject.tomls under projects/ only list the bricks each project actually uses.

Verification

After running poly sync, verify the changes by inspecting the [tool.polylith.bricks] section in the relevant projects/<name>/pyproject.toml or the root pyproject.toml to ensure the new bricks were added. Alternatively, run poly info (load polylith-workspace-inspection) to see the updated matrix.

© DavidVujic, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/polylith/polylith-sync of DavidVujic/python-polylith.

Open the folder on GitHubat commit a7a80f2

Compare with similar skills

Polylith Sync next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Polylith Sync compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Polylith Sync this skillDavidVujic/python-polylith553—~1.3kAutomated safety check: PassMIT
Claude-Mem Cloud Syncthedotmack/claude-mem97k—~1kAutomated safety check: NotesApache-2.0
Agent Sync Coordinatorruvnet/ruflo74k2 repos~4kAutomated safety check: PassMIT
I18n Syncaffaan-m/ECC274k—~1.8kAutomated safety check: PassMIT
Agent Project Board Syncruvnet/ruflo74k2 repos~2.9kAutomated safety check: PassMIT
Fal Lip Syncnexu-io/open-design100k—~308Automated safety check: PassApache-2.0

Similar skills

  • Claude-Mem Cloud Sync

    thedotmack/claude-mem

    Checks claude-mem cloud sync status and guides you through connecting a cmem.ai Pro account without the sync token ever passing through the chat.

    97k GitHub stars~1k tokensUpdated today
    Agent WorkflowsAuto-check: notes
  • Agent skill for sync-coordinator - invoke with $agent-sync-coordinator

    74k GitHub starsUsed in 2 repos~4k tokens
    Auto-check passed
  • I18n Sync

    affaan-m/ECC

    Translate and synchronize application JSON locale files using source-key usage, project terminology, and focused validation.

    274k GitHub stars~1.8k tokensUpdated 2 days ago
    Frontend & DesignAuto-check passed
  • Agent skill for project-board-sync - invoke with $agent-project-board-sync

    74k GitHub starsUsed in 2 repos~2.9k tokens
    Auto-check passed
  • Fal Lip Sync

    nexu-io/open-design

    Create talking head videos and lip sync audio to video via fal.ai.

    100k GitHub stars~308 tokensUpdated today
    Media & CreativeAuto-check passed
  • gbrain Sync

    garrytan/gstack

    Re-indexes a repository into gbrain and refreshes the agent search guidance in CLAUDE.md, safe to run again whenever search results look stale.

    136k GitHub stars~15k tokensUpdated today
    Agent WorkflowsAuto-check: notes

More from DavidVujic/python-polylith

All 37 skills in this repo
  • Polylith Base Creation

    DavidVujic/python-polylith

    Create a Polylith base with poly create base — the entry point of a deployable application (HTTP API, CLI, message-queue consumer, AWS Lambda handler, GCP Cloud Function, scheduled job).

    553 GitHub stars~757 tokensUpdated 3 days ago
    Auto-check passed
  • Polylith Check

    DavidVujic/python-polylith

    Validate a Polylith workspace with poly check — the canonical CI gate.

    553 GitHub stars~972 tokensUpdated 3 days ago
    Auto-check passed
  • Polylith Component Creation

    DavidVujic/python-polylith

    Create a Polylith component with poly create component — a reusable, isolated brick implementing business logic, a feature, a domain module, or a capability.

    553 GitHub stars~800 tokensUpdated 3 days ago
    Auto-check passed
  • Polylith Dependency Management

    DavidVujic/python-polylith

    Add or manage third-party dependencies in a Polylith workspace.

    553 GitHub stars~643 tokensUpdated 3 days ago
    Auto-check passed
  • Polylith Dependency Visualization

    DavidVujic/python-polylith

    Visualize brick × brick dependencies with poly deps — find circular dependencies, inspect a brick's public interface, and detect interface-bypass violations.

    553 GitHub stars~906 tokensUpdated 3 days ago
    Auto-check passed
  • Polylith Diff

    DavidVujic/python-polylith

    List Polylith bricks whose implementation changed since a git tag using poly diff.

    553 GitHub stars~1.1k tokensUpdated 3 days ago
    Auto-check passed

Questions about Polylith Sync

What does Polylith Sync do?

Run poly sync to update each project's [tool.polylith.bricks] table with the bricks actually imported. Polylith Sync is an agent skill from DavidVujic/python-polylith.bricks] table with the bricks actually imported.

How do I install Polylith Sync in Claude Code?

Run `npx skills add DavidVujic/python-polylith --skill polylith-sync -a claude-code`. Or copy the skill folder (.agents/skills/polylith/polylith-sync in DavidVujic/python-polylith) into .claude/skills/polylith-sync in your project. Claude Code loads it when a task matches its description.

How do I install Polylith Sync in Codex?

Run `npx skills add DavidVujic/python-polylith --skill polylith-sync -a codex`. Or copy the skill folder (.agents/skills/polylith/polylith-sync in DavidVujic/python-polylith) into .agents/skills/polylith-sync in your project. Codex loads it when a task matches its description.

Can I use Polylith Sync in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add DavidVujic/python-polylith --skill polylith-sync -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/polylith-sync, .gemini/skills/polylith-sync, .github/skills/polylith-sync and .opencode/skills/polylith-sync in your project.

What does Polylith Sync need to run?

Going by SKILL.md and its folder, Polylith Sync needs the command-line tools its instructions call (uv, poetry and git).

Does Polylith Sync access the network?

SKILL.md contains no URLs. Its commands use uv and git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Polylith Sync safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Polylith Sync use?

Polylith Sync is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Polylith Sync use?

About 1.3k tokens (SKILL.md is roughly 5.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Polylith Sync?

Skills that share tags, products or a category with Polylith Sync: Claude-Mem Cloud Sync (thedotmack/claude-mem, 97k stars), Agent Sync Coordinator (ruvnet/ruflo, 74k stars), I18n Sync (affaan-m/ECC, 274k stars) and Agent Project Board Sync (ruvnet/ruflo, 74k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Polylith Sync?

DavidVujic (a GitHub user) maintains it in DavidVujic/python-polylith, which has 553 GitHub stars. The repository holds 37 skills in this directory. The repository was last updated on October 4, 2026.

Source: DavidVujic/python-polylith on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.