home / skills / bdambrosio / cognitive_workbench / mc-craft
This skill crafts Minecraft items using the Mineflayer recipe system, leveraging available materials to produce desired items efficiently.
npx playbooks add skill bdambrosio/cognitive_workbench --skill mc-craftReview the files below or copy the command above to add this skill to your agents.
---
name: mc-craft
type: python
description: "Perform crafting via Mineflayer recipe system. Returns success/failure"
---
# Minecraft Craft Tool
Performs crafting using Mineflayer recipe system. Crafts items from inventory materials according to Minecraft recipes.
## Purpose
Item crafting for tool creation, material processing, and item production. Uses available inventory materials to craft items.
## Input
- `value`: Recipe/item name (preferred)
- `recipe`: Recipe/item name (alternative to value)
- `count`: Integer (optional, default: `1`)
## Output
Returns uniform_return format with:
- `value`: Text summary (success/failure message)
- `data`: Structured data dict (machine-readable). Key fields:
- `success`: Boolean
- `item`: String (item that was crafted)
- `count`: Integer (number of items crafted)
## Behavior & Performance
- Uses Mineflayer recipe system
- Requires appropriate materials in inventory
- Fails if materials insufficient or recipe invalid
- May require crafting table for complex recipes
## Guidelines
- Use `mc-inventory` first to check available materials
- Item name must match Minecraft item names (e.g., "minecraft:stick", "minecraft:wooden_pickaxe")
- Some recipes require crafting table - use `mc-open` on crafting table first
- Count parameter allows crafting multiple items at once
## Usage Examples
Craft single item:
```json
{"type":"mc-craft","recipe":"minecraft:stick","count":4,"out":"$craft"}
```
Craft tool:
```json
{"type":"mc-craft","value":"minecraft:wooden_pickaxe","count":1,"out":"$tool"}
```
This skill performs in-game crafting using the Mineflayer recipe system. It attempts to craft the requested Minecraft item using materials in the bot’s inventory and returns a clear success or failure result. The skill supports crafting counts and reports machine-readable output for automation.
The skill accepts a recipe or item name and an optional count, then queries the Mineflayer recipe system to perform the craft. It checks inventory materials and uses a crafting table if required (the table must be opened beforehand for table-only recipes). On completion it returns a structured result indicating success, the item crafted, and the number produced.
What input fields are required?
Provide a recipe or value with the Minecraft item name. Count is optional and defaults to 1.
What happens if materials are missing?
The skill returns a failure in the structured data. Use inventory checks to confirm materials before calling the skill.