SDK for human-in-the-loop AI agent workflows
Top 37.5% on sourcepulse
HumanLayer provides an API and SDK for integrating human oversight into AI agent workflows, specifically for high-stakes function calls. It targets developers building agentic systems who need to ensure safety and reliability when AI agents interact with the real world, offering a mechanism for human approval and feedback.
How It Works
HumanLayer operates by instrumenting function calls within AI agent frameworks. It uses decorators like @hl.require_approval()
to intercept calls to sensitive functions, routing them for human review via channels like Slack or email. Alternatively, hl.human_as_tool()
allows agents to proactively solicit human input or feedback during execution. This approach deterministically guarantees human involvement, mitigating risks associated with LLM hallucinations or errors in critical operations.
Quick Start & Requirements
pip install humanlayer
npm install humanlayer
Highlighted Details
@hl.require_approval()
decorator for blocking function calls until human approval.hl.human_as_tool()
for general human interaction within agent workflows.Maintenance & Community
Licensing & Compatibility
Limitations & Caveats
Some integrations, like GripTape and Controlflow, are currently in Alpha status. Features such as SMS/RCS approvals, Discord approvals, and composite contact channels are still in the planning stages.
1 day ago
1 week