Regions

Choose where sandboxes and agents run, set your account's default, and keep resources together.

A region is where a resource runs and keeps its data. NoClick names its regions itself, never after a cloud, so the same name keeps working whatever runs it underneath:

RegionWhere
us-eastThe eastern United States, where NoClick itself runs
us-westThe western United States
euThe European Economic Area
apAsia and the Pacific
import noclick

for region in noclick.regions():
    print(region.name, region.label, region.kinds, "(default)" if region.default else "")

noclick.regions(kind="sandbox") keeps the regions that place a kind of resource. Every region places sandboxes (sandbox), agents (agent), buckets (bucket), databases (database), apps (project) and machines (machine); us-east places browsers (browser), and eu and ap where the deployment runs them there (for now, NoClick's hosted platform doesn't); and us-east alone places dicts (dict) and queues (queue). Reading the list needs the scope of any of them: sandboxes, agents, storage, databases, apps, machines, browsers, dicts, queues or volumes.

Choose one

Pass region when you create the resource:

with noclick.Sandbox.create(region="eu") as sb:
    print(sb.region)   # eu

reviewer = noclick.Agent.from_name(
    "reviewer",
    create_if_missing=True,
    instructions="You review pull requests for our EU customers.",
    region="eu",
)

A resource keeps its region for life. An agent's can't change: Agent.from_name or update asking for another raises noclick.Conflict naming the agent's region, so create a new agent there instead. A name that isn't a region raises noclick.InvalidRequest, listing the regions.

Pinning a sandbox costs more: its provider charges 1.15 times as much in eu and ap and 1.75 times in us-east and us-west, and so does NoClick, for a sandbox and for the sandbox an agent on a coding harness runs in. A container app costs more to run in ap. Without a region, a sandbox costs the base price.

Your account's default

Set your account's default region in the console, under Settings. A resource created without region takes it, and the region list marks it with default. A child agent takes its parent's region before the default. With no region and no default, NoClick runs it wherever it has capacity, and its region is None: that is how everything ran before regions.

Keep things together

region=other.region puts a resource beside another, so the work between them stays close:

analyst = noclick.Agent.from_name("analyst")
with noclick.Sandbox.create(region=analyst.region) as sb:
    sb.exec("python -c 'print(1 + 1)'")

What a region covers

  • A sandbox runs in its region, and its files are on its own disk there.
  • An agent on a coding harness runs its whole sandbox in its region: the harness, its shell and files, and its calls to its model provider.
  • An agent on sdk runs its shell (the code capability) in its region. Its agent loop runs in NoClick's own service in us-east.
  • The code capability of a toolkit runs in your account's default region.
  • A bucket keeps its files in its region, which object storage takes as a location hint: it makes the bucket there when it has room there. Without a region, a bucket takes your account's default, else us-east.
  • Dicts and queues keep their data in NoClick's own database, in us-east, the one region that places them for now: region="us-east", or none, keeps one there, and another region, or an account default elsewhere, raises noclick.InvalidRequest naming us-east.
  • Volumes aren't placed by region yet: the sandbox provider's volume storage takes no location, so a volume has no region and region= on one is in invite-only beta. A sandbox or agent in any region mounts any volume.
  • Cards take no region: they're issued in the US, in dollars, to US businesses, whatever region your account and its users use.

NoClick itself runs in us-east: every conversation's history, every operation and the activity log are kept there whatever a resource's region. An agent's workspace files are kept in storage NoClick replicates across regions, so today a region says where work runs, not where an agent's files rest.

Data, apps and machines

Databases and apps take region the same way, keep it, and fall back to your account's default. With neither, they're kept in us-east, since data has to live somewhere. Machines are placed the same way. A database and the agent that queries it, side by side:

concierge = noclick.Agent.from_name("concierge")
bookings = noclick.Database.create("bookings", region=concierge.region)

An app's region places its server code near that region, so put it with the database it binds; its static files are served from everywhere, and its region says nothing about where data stays. That's its database's and bucket's region to say.

Browsers and their profiles take region too, in a region noclick.regions(kind="browser") lists: us-east on NoClick's hosted platform for now, and never us-west yet. Another region raises noclick.NotAvailable naming those that work. A profile's region is where its browsers run; its sign-ins are kept in the US whatever the region.