Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
77ca362
feat: init Go module with goldmark dependency
xcapaldi Mar 3, 2026
503fef0
feat: parse from markdown to goldmark ast
xcapaldi Mar 3, 2026
cfe325b
feat: define recipe and component structs
xcapaldi Mar 5, 2026
f097803
feat: implement RecipeMD parser with canonical test suite
xcapaldi Mar 5, 2026
bfdec47
fix: invert recipe parsing strategy -- split first
claude Mar 9, 2026
baa00bc
feat: implement crude recipemd and recipemd-find CLI tools
claude Mar 9, 2026
17055f3
feat: reduce to 1 goldmark parser pass
xcapaldi Mar 13, 2026
80d5d99
feat: refactor rendering and support simple extensions
xcapaldi Mar 13, 2026
72f7af5
fix: rewrite rendering and use template for Markdown rendering
xcapaldi Mar 13, 2026
3e7ed90
feat: expose flags for the GFM and frontmatter parser options in CLI
xcapaldi Mar 13, 2026
c8120c5
fix: fix fenced code and GFM task list bugs and add golden tests
xcapaldi Mar 13, 2026
6714cd4
fix: drop duplicate regression tests
xcapaldi Mar 13, 2026
3471d85
fix: refactor rendering logic
xcapaldi Mar 13, 2026
f71e213
feat: bump to Go v1.26.0
xcapaldi Mar 13, 2026
2cc8b14
fix: add unit tests
xcapaldi Mar 13, 2026
93a4a87
feat: refactor recipemd and recipemd-find CLIs
xcapaldi Mar 13, 2026
32cc59d
fix: remove unused benchmark
xcapaldi Mar 15, 2026
27482f4
feat: drop CLI tools in favour of focused examples
claude Mar 13, 2026
0cbb4e2
feat: collect all parse errors with position info
claude Mar 16, 2026
af19e84
feat: change Parse to accept io.Reader instead of []byte
claude Mar 16, 2026
5f751d5
feat: Add RenderHTML method for HTML output
claude Mar 14, 2026
8118028
Add thorough godoc documentation to all exported symbols
claude Mar 15, 2026
c786019
fix: gofmt codebase
xcapaldi Mar 17, 2026
cdf9f87
docs: add reflink limitation to HTML renderer
xcapaldi Mar 17, 2026
c385726
docs: write README as a valid RecipeMD recipe
claude Mar 14, 2026
d088df1
docs: fix badges in README
xcapaldi Mar 17, 2026
187b637
docs: agent skill to work with recipemd format
xcapaldi Mar 28, 2026
2a1fe54
Add InlineIngredients function for amount injection into instructions
claude Mar 20, 2026
bb7b4dc
Rework inline ingredients as a parser option with render-time injection
claude Mar 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
155 changes: 155 additions & 0 deletions .agents/skills/recipemd-format/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,155 @@
---
name: recipemd-format
description: Read, write, and edit recipes in RecipeMD format. Use when working with .md recipe files that follow the RecipeMD specification or when creating new recipes in structured Markdown.
license: MIT
---

# RecipeMD Format

[RecipeMD](https://recipemd.org/specification.html) is a Markdown-based format for structured recipes.
A recipe is a valid CommonMark document with a defined three-section layout.

## When to use

- Editing or reviewing `.md` files that contain recipes
- Creating new recipes in plain Markdown
- Converting recipes from other formats to RecipeMD

## Document structure

Three sections separated by `---` (thematic breaks):

```
# Title <-- Preamble (required)
...
---
- ingredients <-- Ingredients (required)
---
instructions <-- Instructions (optional)
```

## Preamble

The preamble is everything before the first `---`. It must start with an H1 title.

| Element | Format | Required |
|---------|--------|----------|
| Title | `# Recipe Name` (H1 heading) | Yes |
| Description | Markdown paragraphs after the title | No |
| Tags | `*tag1, tag2, tag3*` (italic paragraph) | No |
| Yields | `**4 servings**` (bold paragraph) | No |

Tags and yields each occupy their own paragraph. Multiple yields are comma-separated within one bold span: `**4 servings, 800 ml**`.

## Ingredients

Everything between the first and second `---`. Ingredients are unordered list items.

### Basic ingredient

```markdown
- ingredient name
```

### With amount

Wrap the amount in emphasis (single `*`):

```markdown
- *200 g* spaghetti
- *2* eggs
- *1 tbsp* olive oil
```

The amount is always the first element in the list item. The format is `*[number][unit]*` where unit is optional.

### Ingredient groups

Use H2 or deeper headings to create named groups:

```markdown
## Marinade

- *2 tbsp* soy sauce
- *1 tbsp* sesame oil

## Stir Fry

- *200 g* tofu
- *1* bell pepper, sliced
```

Groups can nest (H3 inside H2, etc).

### Linked ingredients

Link an ingredient name to another recipe file:

```markdown
- *200 ml* [tomato sauce](./tomato-sauce.md)
```

## Instructions

Everything after the second `---`. Free-form Markdown -- any valid CommonMark content (paragraphs, lists, images, tables, etc).

The second `---` and instructions section are optional. A recipe with only a preamble and ingredients is valid.

## Amount number formats

Amounts support several number formats:

| Format | Examples |
|--------|----------|
| Integer | `3`, `12` |
| Decimal | `1.5`, `0.75` |
| Decimal (comma) | `1,5` |
| Fraction | `1/2`, `3/4` |
| Mixed number | `1 1/2`, `2 3/4` |
| Vulgar fraction | `½`, `¼`, `¾`, `⅓`, `⅔` |

## Complete example

```markdown
# Carbonara

A classic Roman pasta.

*Italian, pasta*

**2 servings**

---

- *200 g* spaghetti
- *100 g* guanciale
- *2* eggs
- *50 g* Pecorino Romano

## Sauce

- *1 tbsp* black pepper, coarsely ground

---

Boil pasta. Render guanciale. Whisk eggs with cheese and pepper.
Toss together off the heat.
```

## Common mistakes

- Missing `---` between sections (preamble, ingredients, instructions must be separated by thematic breaks)
- Using `**bold**` for amounts instead of `*italic*` (amounts use single emphasis)
- Placing amounts outside emphasis markers: `200 g spaghetti` instead of `*200 g* spaghetti`
- Using ordered lists for ingredients (must be unordered `- `)
- Forgetting that tags use italic (`*...*`) and yields use bold (`**...**`)

## Frontmatter (non-standard extension)

Some tools support YAML (`---`) or TOML (`+++`) frontmatter before the recipe content.
This is not part of the official spec but my be useful when combining RecipeMD with note management systems.
Parsers that support this strip the frontmatter before applying the standard rules.

## Reference

Full specification: https://recipemd.org/specification.html
Loading