|
1 | | -# Stagehand Python API Library |
2 | | - |
3 | | -[)](https://pypi.org/project/stagehand-alpha/) |
4 | | - |
5 | | -The Stagehand Python SDK provides convenient access to the [Stagehand REST API](https://docs.stagehand.dev) from applications written in Python. |
6 | | - |
7 | | -It is generated with [Stainless](https://www.stainless.com/). |
| 1 | +<div id="toc" align="center" style="margin-bottom: 0;"> |
| 2 | + <ul style="list-style: none; margin: 0; padding: 0;"> |
| 3 | + <a href="https://stagehand.dev"> |
| 4 | + <picture> |
| 5 | + <source media="(prefers-color-scheme: dark)" srcset="media/dark_logo.png" /> |
| 6 | + <img alt="Stagehand" src="media/light_logo.png" width="200" style="margin-right: 30px;" /> |
| 7 | + </picture> |
| 8 | + </a> |
| 9 | + </ul> |
| 10 | +</div> |
| 11 | +<p align="center"> |
| 12 | + <strong>The AI Browser Automation Framework</strong><br> |
| 13 | + <a href="https://docs.stagehand.dev/v3/sdk/python">Read the Docs</a> |
| 14 | +</p> |
| 15 | + |
| 16 | +<p align="center"> |
| 17 | + <a href="https://github.com/browserbase/stagehand/tree/main?tab=MIT-1-ov-file#MIT-1-ov-file"> |
| 18 | + <picture> |
| 19 | + <source media="(prefers-color-scheme: dark)" srcset="media/dark_license.svg" /> |
| 20 | + <img alt="MIT License" src="media/light_license.svg" /> |
| 21 | + </picture> |
| 22 | + </a> |
| 23 | + <a href="https://stagehand.dev/discord"> |
| 24 | + <picture> |
| 25 | + <source media="(prefers-color-scheme: dark)" srcset="media/dark_discord.svg" /> |
| 26 | + <img alt="Discord Community" src="media/light_discord.svg" /> |
| 27 | + </picture> |
| 28 | + </a> |
| 29 | +</p> |
| 30 | + |
| 31 | +<p align="center"> |
| 32 | + <a href="https://trendshift.io/repositories/12122" target="_blank"><img src="https://trendshift.io/api/badge/repositories/12122" alt="browserbase%2Fstagehand | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a> |
| 33 | +</p> |
| 34 | + |
| 35 | +<p align="center"> |
| 36 | +If you're looking for other languages, you can find them |
| 37 | +<a href="https://docs.stagehand.dev/v3/first-steps/introduction"> here</a> |
| 38 | +</p> |
| 39 | + |
| 40 | +<div align="center" style="display: flex; align-items: center; justify-content: center; gap: 4px; margin-bottom: 0;"> |
| 41 | + <b>Vibe code</b> |
| 42 | + <span style="font-size: 1.05em;"> Stagehand with </span> |
| 43 | + <a href="https://director.ai" style="display: flex; align-items: center;"> |
| 44 | + <span>Director</span> |
| 45 | + </a> |
| 46 | + <span> </span> |
| 47 | + <picture> |
| 48 | + <img alt="Director" src="media/director_icon.svg" width="25" /> |
| 49 | + </picture> |
| 50 | +</div> |
| 51 | + |
| 52 | +## What is Stagehand? |
| 53 | + |
| 54 | +Stagehand is a browser automation framework used to control web browsers with natural language and code. By combining the power of AI with the precision of code, Stagehand makes web automation flexible, maintainable, and actually reliable. |
| 55 | + |
| 56 | +## Why Stagehand? |
| 57 | + |
| 58 | +Most existing browser automation tools either require you to write low-level code in a framework like Selenium, Playwright, or Puppeteer, or use high-level agents that can be unpredictable in production. By letting developers choose what to write in code vs. natural language (and bridging the gap between the two) Stagehand is the natural choice for browser automations in production. |
| 59 | + |
| 60 | +1. **Choose when to write code vs. natural language**: use AI when you want to navigate unfamiliar pages, and use code when you know exactly what you want to do. |
| 61 | + |
| 62 | +2. **Go from AI-driven to repeatable workflows**: Stagehand lets you preview AI actions before running them, and also helps you easily cache repeatable actions to save time and tokens. |
| 63 | + |
| 64 | +3. **Write once, run forever**: Stagehand's auto-caching combined with self-healing remembers previous actions, runs without LLM inference, and knows when to involve AI whenever the website changes and your automation breaks. |
8 | 65 |
|
9 | 66 | ## Installation |
10 | 67 |
|
|
0 commit comments