guardrails icon indicating copy to clipboard operation
guardrails copied to clipboard

[feat] Support for image inputs in prompts

Open whyrusleeping opened this issue 11 months ago • 1 comments

Description Allow passing images as a parameter to the model for models that support multimodal inputs

Why is this needed I'd like to use guardrails for structured image processing

Implementation details Seems like its a small amount of wiring to pass things through but i don't really know.

End result Ideally something like:

    raw, validated_output, *rest = guard(
        litellm.completion,
        model="claude-3-haiku-20240307",
        prompt_params={
            "image": img, # PIL image as input
            "annotation": ann,
        },
        max_tokens=1024,
    )

whyrusleeping avatar Mar 20 '24 19:03 whyrusleeping

Hi! This is a great idea, I'll look through litellm docs to see if this is supported currently.

zsimjee avatar Mar 20 '24 23:03 zsimjee

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 14 days.

github-actions[bot] avatar Aug 22 '24 03:08 github-actions[bot]

This issue was closed because it has been stalled for 14 days with no activity.

github-actions[bot] avatar Sep 05 '24 03:09 github-actions[bot]