This repository contains various examples demonstrating how AI agents can interact with and pay humans to complete tasks using LangGraph for AI Agent development and Payman for handling payments and task creation.
The LangMan Examples
repository provides multiple examples to help developers understand how to integrate LangGraph and Payman. Each example showcases a different use case or integration pattern.
- LangMan-Simple: Demonstrates a basic AI agent setup using LangGraph and Payman to automate task creation and payment processes.
- LangMan-Webhook: Shows how to integrate webhooks for asynchronous updates to the AI once human completes task and is paid.
- (More examples will be added in the future)
- Create AI-driven workflows using LangGraph
- Pay humans for services and tasks via Payman
- Automate task creation, payment processing, and AI-human collaboration
- Provide multiple examples to illustrate different integration scenarios
Before using any of the examples, ensure you have the following installed:
- Bun - Fast all-in-one JavaScript runtime
Additionally, you'll need:
- OpenAI API key
- Payman API key
-
Clone the repository:
git clone https://github.com/PaymanAI/langman-examples.git
cd langman-examples
-
Choose an example to get started: Navigate to the desired example directory, such as
examples/langman-simple
.cd examples/langman-simple
-
Install dependencies:
bun install
-
Set up environment variables:
- Copy
.env.example
to.env
- Fill in your OpenAI and Payman API keys in the
.env
file
- Copy
Each example has its own README file containing detailed setup instructions and usage guidelines. Please refer to the individual README files for further information:
langman-examples/
├── examples/
│ ├── langman-simple/
│ │ ├── src/
│ │ ├── .env.example
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── package.json
│ │ └── tsconfig.json
│ ├── langman-webhook/
│ │ ├── src/
│ │ ├── .env.example
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── package.json
│ │ └── tsconfig.json
├── .gitignore
├── README.md
├── LICENSE
├── biome.json
└── package.json
Contributions are welcome! If you would like to add a new example or improve an existing one, please feel free to submit a pull request.
- LangGraph for AI workflow management
- Payman for task creation and payment processing
- OpenAI for the language model
For any questions or issues, please open an issue in the GitHub repository or contact the maintainers directly.