Different Ways to Create Recipes
Explore all methods for creating PraisonAI recipes
Create recipes with the CLI, by hand, or from existing examples—pick the path that fits your team.
from praisonaiagents import Agent
agent = Agent(name="Recipe Planner", instructions="Compare recipe creation approaches.")
agent.start("Should I use recipe init or a manual folder?")The user picks a creation method, scaffolds files, and runs the recipe with the same CLI entry point.
How It Works
How to Create Recipes Using CLI
- Initialize New Recipe
bash praisonai recipe init my-recipe - Navigate to Recipe
bash cd my-recipe - Customize Generated Files
Edit
agents.yamlto match your requirements.
How to Create Recipes Manually
- Create Directory Structure
bash mkdir my-recipe cd my-recipe touch agents.yaml - Write agents.yaml
yaml framework: praisonai topic: "{{task}}" roles: agent: role: Assistant goal: Complete the task tasks: main: description: "{{task}}" expected_output: "Task result" - Run Recipe
bash praisonai recipe run ./my-recipe --var task="Your task"
How to Create Recipes from Existing Agents
- Define Agent in Python
python from praisonaiagents import Agent agent = Agent( name="researcher", role="Research Specialist", goal="Research topics thoroughly", tools=["internet_search"] ) - Convert to YAML
Create
agents.yamlbased on your agent:yaml framework: praisonai topic: "{{task}}" roles: researcher: role: Research Specialist goal: Research topics thoroughly tools: - internet_search tasks: research: description: "Research {{task}}"
How to Create Recipes from GitHub
- Fork Repository
Fork the Agent-Recipes repository on GitHub.
- Clone Your Fork
bash git clone https://github.com/YOUR_USERNAME/Agent-Recipes cd Agent-Recipes - Create New Recipe Directory
bash mkdir my-new-recipe # Create agents.yaml - Customize and Push
bash # Edit files git add . git commit -m "Add my-new-recipe" git push
Recipe Creation Methods Comparison
| Method | Best For | Complexity |
|---|---|---|
CLI init | Quick start | Low |
| Manual | Full control | Medium |
| From Agent | Converting existing code | Medium |
| GitHub Fork | Contributing to community | Medium |
Best Practices
Use recipe init for a fast, valid start
The CLI scaffold produces a correct agents.yaml, so it is the lowest-risk way to begin a new recipe.
Go manual only when you need full control
Hand-authoring pays off for unusual structures, but skip it for standard recipes where the scaffold already fits.
Every method ends at the same run command
No matter how you create a recipe, praisonai recipe run executes it — so choose the method by authoring convenience, not runtime behaviour.