Skip to main content

License PyPI Python version

🕺 Groovy

Hi there! This is groovy, a Python library that makes it easy to build, debug, and share workflows or flows (e.g. autonomous applications that perform actions using your browser or desktop).

Build flows with a simple high-level Flow class that can wrap any kind of application. Since groovy is "batteries-included", you can write your first Flow to control a browser in just a single line.

🔎 Debug flows with an intuitive Gradio user interface, that exposes agent thought while it runs and allows users to "step-in" and intervene at any point.

🤗 Share flows on Hugging Face Spaces publicly (or with specific collaborators) and reuse flows from the community

Screen Recording 2025-01-29 at 1 30 30 AM (online-video-cutter com)

Installation

$ pip install groovy[full]

Key Features

1. Get started immediately ✨

No need for Run instant browser automations with a single command. No need for complex setup or boilerplate code:

groovy flow "Find the next upcoming event in San Francisco related to board games"

2. Customize Flows

Create interactive automation apps using the Flow class. You can define input parameters that users can customize before running the flow:

from groovy import Flow
import gradio as gr

flow = Flow(
    task="Find the next upcoming event in {} related to {}",
    inputs=[
        gr.Textbox(label="Location", value="San Francisco")
        gr.Textbox(label="Activity", value="board games"),
    ]
)

flow.launch()

Run Flows Programmatically

The Flow class can also be run programmatically so that it can be used as part of larger programs. Here's an example:

from groovy import Flow
import csv

flow = Flow(task="Find the next upcoming event in {} related to {}")

cities = [
    "San Francisco", "New York", "Chicago", "Los Angeles", "Seattle",
    "Austin", "Boston", "Denver", "Portland", "Miami"
]

results = []
for city in cities:
    event_info = flow.run(city, "board games")
    results.append({"city": city, "event": event_info})

with open("board_game_events.csv", "w", newline="") as f:
    writer = csv.DictWriter(f, fieldnames=["city", "event"])
    writer.writeheader()
    writer.writerows(results)

3. Easy Sharing via Hugging Face Spaces

Share your automation workflows with others by publishing to Hugging Face Spaces. Just navigate to your project folder and run:

groovy publish

This will create a public (you can change visibility to private) Hugging Face Space where others can access and use your automation.

4. Use Community Workflows

Take advantage of existing workflows created by the community. Run any published workflow locally, e.g.:

groovy run https://huggingface.co/spaces/abidlabs/Activity_Finder

Roadmap aka leftover TODOs

  • Support structured generation in .run() -- how would this work?
  • Support max_steps / max_time in .run()
  • Make it easier to modify the default agent
  • Allow task to be an arbitrary function of inputs, not just a format string
  • Add Flow.run(**input) which runs the flow programmatically without the Gradio UI
  • Add support for browser-use and desktop apps
  • Make screen recording more robust
  • Generally improve troubleshooting
  • Add support for using the user's default browser
  • Add more examples

Contributing

Contributions are welcome! Feel free to submit bug reports and feature requests or submit pull requests

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

groovy-0.0.12.tar.gz (17.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

groovy-0.0.12-py3-none-any.whl (18.3 kB view details)

Uploaded Python 3

File details

Details for the file groovy-0.0.12.tar.gz.

File metadata

  • Download URL: groovy-0.0.12.tar.gz
  • Upload date:
  • Size: 17.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for groovy-0.0.12.tar.gz
Algorithm Hash digest
SHA256 192411f74d7a7fddb4214143c58710686828ce3c43be8bafe31de0cb7caabee2
MD5 22a9f013ba59e897359b5abb13ef3247
BLAKE2b-256 87dcf66de082837dcc46f6e1cd6f7db9320490c41c5ca947d48049f4acb22b79

See more details on using hashes here.

File details

Details for the file groovy-0.0.12-py3-none-any.whl.

File metadata

  • Download URL: groovy-0.0.12-py3-none-any.whl
  • Upload date:
  • Size: 18.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for groovy-0.0.12-py3-none-any.whl
Algorithm Hash digest
SHA256 0a744dfb6d7ef4db691af862fbc0ad3c86d63ba35208fe85b855e6b50e83f9bd
MD5 888b99d2e37b363e7d3e6c53825305b0
BLAKE2b-256 e41a166436eeb8b2ff7aab37cd30bf64d1142158ae94cdab4c559a2c2d1289b1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page