Official Python SDK for Virtuals API/GAME
Project description
Virtuals Python API Library
The Virtuals Python API Library is a Python library that provides a simple way to interact with the Virtuals API.
Currently, this library supports the GAME API for configuring and deploying agents on the Virtuals Platform. This complements and extends the functionality of the Agent Sandbox by providing another way to evaluate and develop agents on Virtuals. With more programmatic interactions, this opens up more functionalities and possibilities to integrate it into your own applications.
Documentation
For a walkthrough of some documentation and SDK and usage, please refer to the notion documentation page.
Installation
pip install virtuals_sdk
Usage
from virtuals.game import Agent
# Create agent with just strings for each component
agent = Agent(
api_key=VIRTUALS_API_KEY,
goal="Autonomously analyze crypto markets and provide trading insights",
description="HODL-9000: A meme-loving trading bot powered by hopium and ramen",
world_info="Virtual crypto trading environment where 1 DOGE = 1 DOGE"
)
# list available functions that can be added to agent
print(agent.list_available_default_twitter_functions()) # ['wait', 'reply_tweet', 'retweet', 'like_tweet', ...]
# selects functions to be enabled
agent.use_default_twitter_functions(["wait", "reply_tweet"])
# Simulate one step of the full agentic loop on Twitter/X from the HLP -> LLP -> action
response = agent.simulate_twitter(session_id="123")
# deploy agent! (NOTE: supported for Twitter/X only now)
agent.deploy_twitter()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file virtuals_sdk-0.1.2.tar.gz.
File metadata
- Download URL: virtuals_sdk-0.1.2.tar.gz
- Upload date:
- Size: 9.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
252ee1fc3d4dc104fdf29525e784a6ac512a348f30024523d09ccd251a7cb90c
|
|
| MD5 |
629a0ac3c5c6bfda26ea4d07396ca044
|
|
| BLAKE2b-256 |
c358e73097d4c572b513b548add788f0f5bdf3d8bbf7989ceea45939f7303e81
|
File details
Details for the file virtuals_sdk-0.1.2-py3-none-any.whl.
File metadata
- Download URL: virtuals_sdk-0.1.2-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4d648e80c7f62a66e2e0da738f54da437ce5213050637d81604f0b4adaa99f82
|
|
| MD5 |
dc266af64bcce2240beccd9f7fb509fa
|
|
| BLAKE2b-256 |
085091d14a979ec9841e5ba8811bf5d112f8a4cfc6cfa1347255b343979ea9e7
|