Overview

The easiest way to get things done is by using our proprietary computer-use agent—either through the Playground or via the agent endpoint. It’s optimized for long-running tasks and, based on our internal benchmarking, excels at leveraging the instance’s knowledge.

When given a task, the agent retrieves knowledge from the instance (which includes a summary of previous agent runs), captures a screenshot, and initiates a computer-use loop to interact with the instance. Internally, we use Anthropic’s Sonnet 3.7 model.

Run Agent

import os
from skylight_sdk import Skylight

with Skylight(
apikey=os.getenv("SKYLIGHT_APIKEY", ""),
) as skylight:

    res = skylight.agent.run(instance_id="<id>",
          query="Make a 5 slide pitch deck about Pied Piper")

When the agent is done, it will generate a summary, which will be used to update the instance’s knowledge.

Stop Agent

You can stop a running agent with the instance ID.

res = skylight.agent.stop(instance_id="<id>")

The response is a JSON with status and message confirming the agent was stopped successfully.

Get Agent State

You can check the current status of an agent with the agent ID.

Note: agent_id is different from instance_id. Every time you run the agent on an instance, it gets assigned a new agent_id.

res = skylight.agent.status(agent_id="<agent_id>")
print(res.agent_status)  # "running"
print(res.total_steps)   # 5

The response includes A JSON with information about the agent’s current state:

FieldTypeDescription
agent_statusstringCurrent status of the agent (e.g., “running”)
is_runningbooleanIndicates if the agent is currently active
total_stepsintegerNumber of steps executed so far
filesobject[]List of files downloaded by the agent
messagesstring[]List of steps executed by the agent
created_atstringTimestamp when the agent was created
querystringOriginal query given to the agent
agent_idstringUnique identifier for the agent
final_summarystring | nullSummary of agent execution (null if still running)

Pricing

The built-in Skylight agent is billed at $0.03 per agent step (tool call).