#
Fal

> All supported Fal models can be found here

Founded in 2021 by Burkay Gur and Gorkem Yurtseven, fal.ai was born out of a shared passion for AI and a desire to address the challenges in AI infrastructure observed during their tenures at Coinbase and Amazon.

##
Supported tasks

###
Automatic Speech Recognition

Find out more about Automatic Speech Recognition here.

Language

Client

Provider

Settings

    import os
    from huggingface_hub import InferenceClient

    client = InferenceClient(
        provider="fal-ai",
        api_key=os.environ["HF_TOKEN"],
    )

    output = client.automatic_speech_recognition("sample1.flac", model="openai/whisper-large-v3")

###
Image Segmentation

Find out more about Image Segmentation here.

Language

Client

Provider

Settings

    import os
    from huggingface_hub import InferenceClient

    client = InferenceClient(
        provider="fal-ai",
        api_key=os.environ["HF_TOKEN"],
    )

    output = client.image_segmentation("cats.jpg", model="briaai/RMBG-2.0")

###
Image To Image

Find out more about Image To Image here.

Language

Client

Provider

Settings

    import os
    from huggingface_hub import InferenceClient

    client = InferenceClient(
        provider="fal-ai",
        api_key=os.environ["HF_TOKEN"],
    )

    with open("cat.png", "rb") as image_file:
       input_image = image_file.read()

    # output is a PIL.Image object
    image = client.image_to_image(
        input_image,
        prompt="Turn the cat into a tiger.",
        model="Qwen/Qwen-Image-Edit",
    )

###
Text To Image

Find out more about Text To Image here.

Language

Client

Provider

Settings

    import os
    from huggingface_hub import InferenceClient

    client = InferenceClient(
        provider="fal-ai",
        api_key=os.environ["HF_TOKEN"],
    )

    # output is a PIL.Image object
    image = client.text_to_image(
        "Astronaut riding a horse",
        model="tencent/HunyuanImage-3.0",
    )

###
Text To Video

Find out more about Text To Video here.

Language

Provider

Settings

    import os
    from huggingface_hub import InferenceClient

    client = InferenceClient(
        provider="fal-ai",
        api_key=os.environ["HF_TOKEN"],
    )

    video = client.text_to_video(
        "A young man walking on the street",
        model="meituan-longcat/LongCat-Video",
    )

Update on GitHub