# Recipes & Ingredients

### Recipes

At design-time, resource assignments can be defined through so-called *Recipes*. Each recipe specifies the process of how to find the best-fitting allocation for a specific problem. At run-time, as soon as such an allocation is required, the corresponding recipe is executed on the basis of the currently available resources.

### Ingredients

Each recipe consists of so-called *ingredients*, which provide different types of functionality within the allocation process. They can be seen as building blocks plugged together in recipes. Currently, there are four different types of ingredients:

* **Input**. They are used as inputs for an allocation process and define on which resource types the allocation should be done. At run-time, they are replaced by the list of currently known resource instances of the type set in the input ingredient.
* **Transformer**. Transformers are used to modify the list of resource instances. The modification can either be that each instance is altered (*map*), *filtering* for e.g. certain attribute values, or *reducing* the set to a new object.
* **Algorithm**. Docker images can be used to process incoming resource instance lists and to compute the optimized allocation/result based on the input. The output of an algorithm ingredient is again a list of resource instances.
* **Output**. Output ingredients write the input they receive back to the database. They are used to persist the allocation result and can only be used at the end of a recipe, as they do not have any outgoing connectors.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://rembrandt.gitbook.io/docs/concepts/recipes-and-ingredients.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
