🍕🔥 Pizza is great! 🔥🍕

Guida Rapida

Inizia a utilizzare TomatoPy in pochi minuti! Questa guida ti accompagnerà attraverso le basi della creazione e manipolazione degli ingredienti virtuali.

TomatoPy ti consente di affettare, tagliare, cucinare e assaporare i pomodori usando solo Python!

Utilizzo di base

Creare il tuo primo pomodoro

from tomatopy import Tomato

# Create a fresh tomato
my_tomato = Tomato(
    ripeness=0.8,  # 80% ripe
    variety="San Marzano",
    weight=150  # grams
)

# Check tomato properties
print(my_tomato.ripeness)  # 0.8
print(my_tomato.variety)   # "San Marzano"

Impostare la tua cucina virtuale

from tomatopy import Kitchen

# Initialize your kitchen
kitchen = Kitchen()

# Configure kitchen settings
kitchen.set_temperature(180)  # Celsius
kitchen.set_humidity(65)      # Percentage

Operazioni di cottura di base

# Crea una salsa dal tuo pomodoro
sauce = kitchen.cook(
    my_tomato,
    method="simmer",
    duration="30m",
    temperature=100
)

# Check sauce properties
print(sauce.consistency)  # "smooth"
print(sauce.volume)       # 250  # ml

Lavorare con più ingredienti

from tomatopy import Ingredient, Recipe

# Create additional ingredients
garlic = Ingredient("garlic", amount=3, unit="cloves")
basil = Ingredient("basil", amount=10, unit="leaves")

# Create a recipe
marinara = Recipe("Classic Marinara")
marinara.add_ingredient(my_tomato)
marinara.add_ingredient(garlic)
marinara.add_ingredient(basil)

# Cook the recipe
sauce = kitchen.cook_recipe(marinara)

Test di assaggio

from tomatopy import TasteTester

# Create a taste tester
tester = TasteTester()

# Analyze your sauce
profile = tester.analyze(sauce)

# Get taste metrics
print(profile.acidity)     # 0.7
print(profile.sweetness)   # 0.3
print(profile.umami)       # 0.8

Prossimi passi

Tips and Tricks

Pro Tip: Use the debug() method to inspect ingredient properties:

my_tomato.debug()  # Prints detailed information about the tomato

Note: All measurements in TomatoPy use the metric system by default. Use the convert_to_imperial() method if needed.

Was this helpful?