crewai-amorce
Secure CrewAI crews with Amorce in 1 decorator
Add Ed25519 signatures, human-in-the-loop approvals, and A2A compatibility to any CrewAI crew.
🚀 Quick Start
Installation
pip install crewai-amorce
Basic Usage (1 Decorator!)
from crewai import Crew, Agent, Task
from crewai_amorce import secure_crew
# Define your crew
researcher = Agent(
role='Research Specialist',
goal='Find accurate information',
backstory='Expert researcher'
)
writer = Agent(
role='Content Writer',
goal='Write engaging content',
backstory='Experienced writer'
)
# Secure the entire crew with one decorator
@secure_crew
crew = Crew(
agents=[researcher, writer],
tasks=[research_task, write_task]
)
# All agent interactions are now cryptographically signed
result = crew.kickoff()
That's it! Your CrewAI crew now has:
- ✅ Ed25519 cryptographic signatures
- ✅ Inter-agent authentication
- ✅ Trust Directory verification
- ✅ A2A-compatible messages
- ✅ Audit trail for all interactions
🛡️ Features
Crew-Wide Security
Every agent in the crew gets Amorce security automatically:
from crewai_amorce import secure_crew
@secure_crew
crew = Crew(
agents=[agent1, agent2, agent3],
tasks=[task1, task2]
)
# All 3 agents now:
# - Have cryptographic identities
# - Sign all communications
# - Verify each other's signatures
Human-in-the-Loop (HITL)
Require human approval for sensitive crew operations:
from crewai_amorce import secure_crew
@secure_crew(
hitl_required=['execute_code', 'make_payment', 'delete_file']
)
crew = Crew(
agents=[developer_agent, finance_agent],
tasks=[code_task, payment_task]
)
# Crew runs normally, but pauses for approval on sensitive actions
Secure Individual Agents
Use SecureAgent for fine-grained control:
from crewai_amorce import SecureAgent
henri = SecureAgent(
role="Electronics Seller",
goal="Maximize profit while maintaining 4.8★ rating",
backstory="Professional refurbisher",
tools=[inventory_db, pricing_api],
hitl_required=['confirm_sale', 'issue_refund']
)
# Henri's actions require human approval for sales
A2A Protocol Compatible
All crew communications use A2A format:
@secure_crew(a2a_compatible=True)
crew = Crew(agents=[...], tasks=[...])
# Agent-to-agent messages use A2A envelope
📖 Examples
Marketplace Demo (Henri - Seller Agent)
See the full Enhanced Marketplace Demo showing Henri selling to Sarah.
from crewai_amorce import SecureAgent
henri = SecureAgent(
role="Electronics Reseller",
goal="Maximize profit while maintaining 4.8★ rating",
backstory="Professional refurbisher with 500+ sales",
tools=[
inventory_database, # Check stock & condition
pricing_api, # Real-time market rates
shipping_calculator, # Calculate costs
receipt_generator # Generate signed docs
],
hitl_required=['confirm_sale', 'issue_refund'],
verbose=True
)
# Henri autonomously:
# 1. Receives offer from Sarah
# 2. Checks Sarah's reputation in Trust Directory
# 3. Calculates profit margin
# 4. Requests human approval to sell
# 5. Generates cryptographically signed receipt
Multi-Agent Research Crew
from crewai import Crew, Agent, Task
from crewai_amorce import secure_crew
# Create agents
researcher = Agent(
role='Senior Researcher',
goal='Uncover cutting-edge developments',
backstory='Renowned researcher'
)
analyst = Agent(
role='Data Analyst',
goal='Analyze research findings',
backstory='Statistical expert'
)
writer = Agent(
role='Tech Writer',
goal='Create comprehensive reports',
backstory='Award-winning writer'
)
# Secure the crew
@secure_crew(
hitl_required=['publish_report'] # Approval before publishing
)
crew = Crew(
agents=[researcher, analyst, writer],
tasks=[research, analyze, write],
verbose=True
)
# Run with full audit trail
result = crew.kickoff()
print(f"Crew ID: {crew.crew_id}")
print(f"All interactions signed: ✓")
🔧 Advanced Configuration
Custom Identity for Crew
from amorce import IdentityManager
from crewai_amorce import secure_crew
# Load existing identity
identity = IdentityManager.load_from_file("crew_identity.pem")
@secure_crew(identity=identity)
crew = Crew(agents=[...], tasks=[...])
Inter-Crew Communication
# Crew A discovers Crew B in Trust Directory
crew_a.discover_crews(capability='data_analysis')
# Crew A delegates task to Crew B (signed)
crew_a.delegate_to(crew_b, task='analyze_data')
🧪 Testing
# Run tests
pytest tests/
# With coverage
pytest --cov=crewai_amorce tests/
📚 Documentation
🤝 Contributing
Contributions welcome! See CONTRIBUTING.md
📄 License
MIT License - see LICENSE
🔗 Links
- Amorce: amorce.io
- GitHub: github.com/amorce/crewai-amorce
- PyPI: pypi.org/project/crewai-amorce
- Issues: github.com/amorce/crewai-amorce/issues
Built with ❤️ by the Amorce team
Metadata
Release files for crewai-amorce 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| crewai_amorce-0.1.0.tar.gz | 10.9 kB | Without provenance | Details for crewai_amorce-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| crewai_amorce-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for crewai_amorce-0.1.0-py3-none-any.whl |
Total release size: 20.5 kB
Release files / crewai_amorce-0.1.0.tar.gz
| Download URL | crewai_amorce-0.1.0.tar.gz |
|---|---|
| Size | 10.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2ab43e1d8f9095fa4223f73948ffb39dc0afdcd3c4012195908e2fe266e454e0
|
|
BLAKE2b-256 checksum How to use checksums |
160bb32f3756bd7e140f13013e0fa01110034c1e5e8b913371b6fd15812ad3d1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|
Release files / crewai_amorce-0.1.0-py3-none-any.whl
| Download URL | crewai_amorce-0.1.0-py3-none-any.whl |
|---|---|
| Size | 9.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d30376931a5907026cbaa54c440ab35f84d0df6c587c05985174c3f7e04138e4
|
|
BLAKE2b-256 checksum How to use checksums |
ecf54c1435206df9b16695e1cf702df5f46188c2c4c20b341bf73b40f408d3e1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|
Security for crewai-amorce 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.