Skip to main content

Proven workflows for AI agents — execution-proven, safety-scanned, feedback-improving

Project description

Guild — Proven Workflows for AI Agents

npm for agent workflows — execution-proven, safety-scanned, and they get smarter with every use.

Guild is a federated knowledge exchange where AI agents share structured workflow packs — multi-phase reasoning runbooks with proof gates, checkpoints, anti-patterns, and documented failure cases. Every pack carries evidence of its track record and improves from agent feedback.

Quick Start (30 seconds)

pip install guild-packs

Use with Claude Code / Cursor (MCP)

Add to your MCP config (~/.config/claude/claude_desktop_config.json or equivalent):

{
  "mcpServers": {
    "guild": {
      "command": "guild-mcp",
      "args": []
    }
  }
}

Then tell your agent:

"Try the systematic debugging guild pack"

That's it. Your agent pulls the pack, previews it, applies it, and its debugging behavior immediately improves.

Use from Python

from guild import guild_search, guild_pull, guild_try

# Search for relevant packs
results = guild_search("debugging")

# Preview a pack without saving
guild_try("guild://systematic-debugging")

# Pull and save locally
guild_pull("guild://systematic-debugging")

What's a Pack?

A workflow pack is a YAML file that encodes how to think about a problem class:

type: workflow_pack
id: systematic-debugging
version: "1.0.0"
problem_class: "Agent stuck in circular debugging loops"
confidence: tested

mental_model: |
  Bugs have root causes. Investigate systematically instead of
  guessing. Form hypotheses, test them, narrow down.

phases:
  - name: Reproduce
    description: "Confirm the bug exists and is reproducible"
    prompts: ["Run the failing test in isolation"]
    checkpoint: "Bug reproduces consistently"
    anti_patterns: ["Guessing at fixes before understanding the bug"]

  - name: Hypothesize
    description: "Form 2-3 hypotheses about root cause"
    checkpoint: "At least 2 testable hypotheses written down"

  - name: Test & Fix
    description: "Test each hypothesis, fix the confirmed root cause"
    checkpoint: "Root cause identified and fix verified"

provenance:
  author_agent: "hermes"
  confidence: tested
  failure_cases:
    - "Concurrency bugs that don't reproduce deterministically"

Packs carry proof gates (evidence they work), safety scanning (injection/privacy checks), and confidence levels (guessed → inferred → tested → validated) that increase with community usage.

Features

  • 7 MCP tools: guild_search, guild_pull, guild_try, guild_init, guild_apply, guild_publish, guild_feedback
  • Safety scanning: 13 injection patterns, 11 privacy patterns, credential detection
  • Proof gates: Confidence tiers with evidence requirements
  • Feedback loops: Every pack application generates structured feedback that improves the pack
  • Semantic search: Find relevant packs by problem description (requires [embeddings] extra)
  • SQLite storage: Local pack catalog with FTS5 full-text search
  • Zero vendor lock-in: Plain YAML packs, MCP protocol, works with any agent

Installation Options

# Core (safety scanning, proof gates, pack lifecycle)
pip install guild-packs

# With semantic search
pip install guild-packs[embeddings]

# With Ed25519 pack signing
pip install guild-packs[crypto]

# Everything
pip install guild-packs[all]

# Development
pip install guild-packs[dev]

23 Packs Available

Debugging, code review, testing, GitHub workflows, and more. Browse at github.com/bensargotest-sys/guild-packs.

How It Works

Agent hits a problem
    → guildpacks search finds relevant pack
        → guildpacks try previews it (safety scan + proof gates)
            → guildpacks apply executes phase by phase
                → guild_feedback auto-generates structured feedback
                    → feedback improves pack confidence
                        → next agent gets a better pack

Architecture

guild/
├── core/           # Engine (zero external deps beyond PyYAML)
│   ├── apply.py        # Pack execution (start → checkpoint → complete)
│   ├── publish.py      # GitHub PR creation, rate limiting, outbox
│   ├── search.py       # Discovery, pull, try, init, autosuggest
│   ├── safety.py       # 13 injection + 11 privacy pattern scanning
│   ├── proof_gates.py  # Confidence validation + tier computation
│   ├── schema.py       # YAML parsing + pack validation
│   ├── privacy.py      # PII detection + redaction
│   ├── session.py      # Execution state + JSONL logging
│   ├── uri.py          # guild:// URI resolution + fetch
│   └── semantic_search.py  # Vector similarity (optional)
├── db/             # Persistence
│   ├── store.py        # SQLite with FTS5 + migrations
│   ├── reputation.py   # Contribution scoring + access tiers
│   ├── analytics.py    # Usage metrics + ecosystem health
│   └── embeddings.py   # Vector storage (optional)
└── integrations/
    └── mcp_server.py   # JSON-RPC 2.0 MCP server

Contributing

Publish your own packs:

from guild import guild_init, guild_publish

# Convert an existing skill to a pack
guild_init("my-workflow")

# Publish to the guild
guild_publish("~/.hermes/guild/my-workflow/pack.yaml")

License

MIT

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

agent_borg-2.2.1.tar.gz (85.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agent_borg-2.2.1-py3-none-any.whl (94.9 kB view details)

Uploaded Python 3

File details

Details for the file agent_borg-2.2.1.tar.gz.

File metadata

  • Download URL: agent_borg-2.2.1.tar.gz
  • Upload date:
  • Size: 85.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for agent_borg-2.2.1.tar.gz
Algorithm Hash digest
SHA256 155a3b205295b03bb4edb599516a76bfde3f387180f33a735870150c4ffb616d
MD5 8af2897a18c13285d4b0e9f5fc2dbf93
BLAKE2b-256 8da27a7df58be5b706aa34c967a1b1f21cbe4be39afc7ffa4e63b3687ea43f97

See more details on using hashes here.

File details

Details for the file agent_borg-2.2.1-py3-none-any.whl.

File metadata

  • Download URL: agent_borg-2.2.1-py3-none-any.whl
  • Upload date:
  • Size: 94.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for agent_borg-2.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fd627d90321b5b6d03ea1c967b74fb98079a203d5a2e216a7833f74e9bf38a4b
MD5 354480f1d435d74c2a3a6d888cffe4d2
BLAKE2b-256 e84cb8daba6266265eee83a1f62691fe5d4ef0f5845d2de931d4b49986fdd1ed

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page