Skip to main content

AgentMesh trust layer integration for LlamaIndex agents

Project description

LlamaIndex AgentMesh IntegrationAgentMesh trust layer integration for LlamaIndex - enabling cryptographic identity verification and trust-gated agent workflows.## OverviewThis integration provides:- TrustedAgentWorker: Agent worker with cryptographic identity and trust verification- TrustGatedQueryEngine: Query engines with access control based on trust- Secure Data Access: Governance layer for RAG pipelines with identity-based policies## Installationbashpip install llama-index-agent-agentmesh## Quick Start### Creating a Trusted Agentpythonfrom llama_index.agent.agentmesh import TrustedAgentWorker, VerificationIdentity# Generate cryptographic identityidentity = VerificationIdentity.generate( agent_name="research-agent", capabilities=["document_search", "summarization"],)# Create trusted agent workerworker = TrustedAgentWorker.from_tools( tools=[search_tool, summarize_tool], identity=identity, llm=llm,)# Create agent with trust verificationagent = worker.as_agent()### Trust-Gated Query Enginepythonfrom llama_index.agent.agentmesh import TrustGatedQueryEngine, TrustPolicy# Wrap query engine with trust policytrusted_engine = TrustGatedQueryEngine( query_engine=base_engine, policy=TrustPolicy( min_trust_score=0.8, required_capabilities=["document_access"], audit_queries=True, ),)# Query requires verified identityresponse = trusted_engine.query( "What are the quarterly results?", invoker_card=requester_card,)### Multi-Agent Trust Handoffspythonfrom llama_index.agent.agentmesh import TrustHandshake, TrustedAgentCard# Create agent card for discoverycard = TrustedAgentCard( name="research-agent", description="Performs document research", capabilities=["search", "summarize"], identity=identity,)card.sign(identity)# Verify peer before task handoffhandshake = TrustHandshake(my_identity=identity)result = handshake.verify_peer(peer_card)if result.trusted: # Safe to delegate task pass## Features### TrustedAgentWorkerAn agent worker that:- Has cryptographic identity for authentication- Verifies peer agents before accepting tasks- Signs outputs for verification by recipients- Supports capability-based access control### TrustGatedQueryEngineA query engine wrapper that:- Requires identity verification for queries- Enforces trust score thresholds- Restricts access based on capabilities- Provides audit logging of all queries### Data Access GovernanceControl access to your RAG pipeline:pythonfrom llama_index.agent.agentmesh import DataAccessPolicypolicy = DataAccessPolicy( allowed_collections=["public", "internal"], denied_collections=["confidential"], require_audit=True, max_results_per_query=100,)# Apply policy to indextrusted_index = TrustedVectorStoreIndex( index=base_index, policy=policy,)## Security ModelAgentMesh uses Ed25519 cryptography for:- Identity Generation: Unique DID per agent- Request Signing: All queries are signed- Response Verification: Outputs can be verified## API Reference| Class | Description || ----------------------- | ------------------------------------ || VerificationIdentity | Cryptographic agent identity || TrustedAgentWorker | Agent worker with trust verification || TrustGatedQueryEngine | Query engine with access control || TrustHandshake | Peer verification protocol || TrustedAgentCard | Agent discovery card || DataAccessPolicy | RAG access governance |## LicenseMIT License

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

llamaindex_agentmesh-3.3.0.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

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

llamaindex_agentmesh-3.3.0-py3-none-any.whl (12.1 kB view details)

Uploaded Python 3

File details

Details for the file llamaindex_agentmesh-3.3.0.tar.gz.

File metadata

  • Download URL: llamaindex_agentmesh-3.3.0.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: RestSharp/106.13.0.0

File hashes

Hashes for llamaindex_agentmesh-3.3.0.tar.gz
Algorithm Hash digest
SHA256 4290d527d28986c5aa7646a9cb691c74d571b289db2ad63c4bf9a6128d2d3ad9
MD5 5a747f02930ea492dbf042622e023f64
BLAKE2b-256 e03249408857e72c40d2289f38bb732f01135823b0a9acf9133098c58ec6e235

See more details on using hashes here.

File details

Details for the file llamaindex_agentmesh-3.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for llamaindex_agentmesh-3.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1aea3f511c3e412f0b6022b6a2c834950824f11e135acbbf9c7266d419bb08b6
MD5 762cb0c27ab8d01971e1f22b00666dfc
BLAKE2b-256 18f6d204f4bfad0fb2ee59af255d893030c68544a5186d4051f1fefcfa62ad85

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