Automate prompt engineering
50x times faster than a human

Automate
prompt engineering
50x times faster than a human

Automate
prompt engineering
50x times faster than a human

Optimize prompts for your LLM app in minutes

with just a few lines of code

Optimize prompts for your LLM app in minutes

with just a few lines of code

from weavel import Weavel
from ape.common.metrics import JsonMatchMetric

wv = Weavel()

optimized_prompt = await wv.optimize(
    base_prompt=base_prompt,
    models=["claude-3-5-sonnet-20240620", "gpt-4o"],
    metric=JsonMatchMetric(),
    trainset=trainset,
)
from weavel import Weavel
from ape.common.metrics import JsonMatchMetric

wv = Weavel()

optimized_prompt = await wv.optimize(
    base_prompt=base_prompt,
    models=["claude-3-5-sonnet-20240620", "gpt-4o"],
    metric=JsonMatchMetric(),
    trainset=trainset,
)

Ape outperforms

Ape outperforms

Ape outperforms

Ape achieves an impressive 93% on the GSM8K benchmark,
surpassing both DSPy (86%) and base LLMs (70%).

Ape achieves an impressive
93% on the GSM8K benchmark,
surpassing both DSPy (86%) and base LLMs (70%).

Vanilla

54.5%

CoT

87.5%

DSPy

90.0%

Ape

94.5%

(Tested on gpt-4o)

(Tested on gpt-4o)