twagent CLI
Project description
Unified configuration framework for AI coding agents — Claude Code, Copilot CLI, Pi, VS Code, opencode. One canonical TOML, one CLI, two deploy modes.
What you get
- One config at
~/.config/twagent/config.tomldescribes every skill, subagent, prompt, instruction template, and MCP server you care about. - One CLI (
twagent apply) renders Jinja templates, symlinks file artifacts, and compiles MCP JSON in each agent's native shape. - Two deploy modes: globally (each agent's default profile to
~/.claude/,~/.copilot/, etc.) or locally (into the current directory).
twagent apply --global # sync everything globally
twagent apply -s tw-claude # local: drop a profile into cwd
twagent apply --global -s e2e-emea # swap MCP env for the day
twagent apply --global -s e2e-emea -a copilot-cli # one agent only
Mental model
┌──────────────┐ ┌─────────────┐
│ Registries │ → │ Profiles │ → apply (local | global)
│ │ │ (composable │ │
│ instructions │ │ bundles) │ ▼
│ skills │ │ │ per-agent paths
│ subagents │ │ extends... │ (global or cwd-relative)
│ prompts │ │ │
│ servers │ │ │
└──────────────┘ └─────────────┘
- Artifacts live in registries — globally unique
name+sourcepath. - Profiles bundle artifact references, composable via
extends. - Agents declare capabilities and per-kind paths (global and per-project).
global_profileis the bridge: each agent names exactly one profile as its default loadout. When you runtwagent apply --global, the agent'sglobal_profileis resolved (including allextendschains) and the resulting artifacts are deployed to the agent'spaths.global.*locations.--selectis polymorphic (profile or artifact names, mixed) and exhaustive (only kinds in the selection deploy).
How global_profile works
[agents.copilot-cli]
global_profile = "tw-copilot" # ← this is the default loadout
[profiles.tw-copilot]
extends = ["core", "pr_review", "web_research"]
instructions = ["AGENT-md"]
[profiles.core]
skills = ["bkmr-memory", "twmux", "skill-creator", "tw-comprehend"]
[profiles.pr_review]
skills = ["tw-review", "tw-add-pr-review", "tw-check-pr"]
Running twagent apply --global resolves the full extends tree and deploys
all referenced skills, instructions, and servers to the agent's global paths.
Each agent can have a different global_profile, so Claude, Copilot, and
Pi can share profiles (via extends) while each carrying a distinct default
set.
Without a global_profile, apply --global skips that agent entirely — it
only deploys agents that declare one.
Install
uv tool install twagent
# or, from a clone:
make install
Python 3.13+. Optional: fzf >= 0.35 improves the --interactive picker.
First deploy
twagent edit --init # bootstrap a commented starter config
$EDITOR ~/.config/twagent/config.toml
twagent apply --global -n # preview
twagent apply --global # deploy
→ Full walkthrough: Quick Start (10 min) and Tutorial (30 min, two-agent setup).
Documentation
| Read | When |
|---|---|
| Overview | What twagent is, who it's for, supported agents. |
| Quick Start | First deploy in 10 minutes. |
| Tutorial | Realistic two-agent setup with project overlay and MCP secrets. |
| Reference: Commands | Every command, every flag. |
| Reference: Configuration | Full TOML schema with worked examples. |
| FAQ | Common questions and gotchas. |
Develop
uv sync
make test
make format
make lint
make build
License
BSD-3-Clause.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file twagent-1.2.2.tar.gz.
File metadata
- Download URL: twagent-1.2.2.tar.gz
- Upload date:
- Size: 61.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c56173704fabf792c47360a12734066945f066a1963d3480410fd8e105db97e9
|
|
| MD5 |
97d780dd7959d5a860860a118a748095
|
|
| BLAKE2b-256 |
c2bf333acb0058bf3f8568c201ce8a01799cab72b6672c12c99b5a1b12cc19fd
|
File details
Details for the file twagent-1.2.2-py3-none-any.whl.
File metadata
- Download URL: twagent-1.2.2-py3-none-any.whl
- Upload date:
- Size: 44.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
de3139a08c8cdb4264d8b17246a542dc2b69440949001e0a4e30b40fedb04158
|
|
| MD5 |
4a9928caa0a2f229fd256c67b4664721
|
|
| BLAKE2b-256 |
7c1b9d5d2ed766d605235acfd5ae88bedb988d1e6ccadcb9cdd0221b5d79d72b
|