Dry Stress Live

Developers

Test from your terminal, your CI, or your agent.

Use the HTTPS API with an API key today. The pip CLI and the MCP server are built and not yet published. Every run costs 5 credits; your app keeps calling your model with your own key.

pip CLI

Coming soon

Run it where your code runs.

Point dsl test at a Python function that takes a question and returns an answer. DSL runs Dry (20 questions, one at a time), then Stress (callers double 1, 2, 4 and so on up to --cap, default the most your plan allows, or 100 if DSL cannot be reached; any whole number from 1 to 100,000; a step above --max-users, default 256, is measured at that many threads), then a Soak at the stable load. Live answer grading is skipped: pip mode never sends your answers anywhere.

$ pip install dsl-ai
$ export DSL_API_KEY=dsl_...   # read from the environment, never a flag
$ dsl test myapp.rag:answer --questions questions.txt

What leaves your machine

Only numbers: step loads, p95 latencies, error percentages, exception class names from the dry run, the stable, slip and break loads, and the component names you choose. Never a question, an answer, or the text of an exception.

Find the slow part

import dsl_ai

@dsl_ai.component("vector_store")
def search(query): ...

with dsl_ai.component("reranker"):
    docs = rerank(query, docs)
  • Callers are Python threads on your machine, so the load it can drive is capped by that machine's CPU. A step above the cap is measured at the cap, and the report says so.
  • Results from your machine are marked unverified, and DSL never trains on them.
  • A call that never returns cannot be killed: its thread is abandoned and counted as a failed call.
DryStressSoakLive skipped
$ pip install dsl-ai
$ export DSL_API_KEY=dsl_••••••••
$ dsl test myapp.rag:answer --questions questions.txt
run run_… started
1 users: p95 0.412s, errors 0.0% -> pass2 users: p95 0.418s, errors 0.0% -> pass4 users: p95 0.431s, errors 0.0% -> pass8 users: p95 0.457s, errors 0.0% -> pass16 users: p95 0.512s, errors 0.0% -> pass32 users: p95 0.684s, errors 0.2% -> pass64 users: p95 1.27s, errors 3.1% -> warn
128 users: p95 2.903s, errors 24.6% -> fail 48 users: p95 0.951s, errors 0.4% -> pass 56 users: p95 1.106s, errors 1.5% -> warn 96 users: p95 1.884s, errors 4.2% -> warn 112 users: p95 2.417s, errors 15.8% -> fail
soak minute 0: p95 0.962s, errors 0.3% … soak minute 30: p95 0.961s, errors 0.3%
Stable at 48 users, slips at 56, breaks at 112 Soak: pass (p95 drift -0.1%)
Stable
Slip
Break
errors climbed → · limits: p95 2.0 s, errors 1.0%
Fix notebook: DSL writes it in about a minute. Open it in the app or ask dsl_notebook.
$
Sample runNumbers from a DSL test app on one Mac, not from a customer. Your output will differ.

MCP server + agent skill

Coming soon

Your coding agent runs the test. It asks you first.

The MCP server gives your agent four tools. The dsl-capacity-test skill tells it how to use them: check for side effects, get your yes before every run, read the fix notebook as a set of hypotheses, and never rerun without asking, because a rerun costs credits.

Agent session
How many users can our support bot hold? Use DSL.
Agent
First, side effects: support/bot.py:answer reads your vector store and calls your model. It writes nothing, sends no email and charges nothing, so it is safe to load.
Asks before each runA run costs 5 DSL credits, makes real calls on your own model key at rising load, and takes about an hour. Run it?
Yes, run it.
dsl_run(target="support.bot:answer", questions_file="tests/questions.txt")
run_id: run_… credits_charged: 5 estimated_minutes: 64
dsl_status(run_id)
status: done stable_users: 48 slip_users: 56 break_users: 112 unverified: true
dsl_notebook(run_id)
state: ready title: "Keep your app steady past 56 users"
Agent
The notebook says errors climbed from 1.5% to 15.8% as load rose and a provider rate limit is likely, which is a hypothesis to check. Your client has no retry yet. Here is a small diff that adds backoff. Shall I apply it?
Agent
Checking the fix needs a rerun, which costs another 5 credits. I will ask before starting it.
IllustrativeA scripted exchange with sample numbers. Tool names and fields match the MCP server.
dsl_run
Starts a test of module:function on this machine. 5 credits; returns at once with a run id. One test at a time.
dsl_status
Where the run is, every measured step, and the stable, slip and break loads.
dsl_notebook
The fix notebook. Pending for about a minute after the run, then ready.
dsl_cancel
Stops a test this server started. Credits come back only if nothing was measured yet.
$ pip install "dsl-ai[mcp]"
$ dsl skill install    # into ./.claude/skills
# register the server command: dsl mcp
# set DSL_API_KEY in the server's environment

The API key is read from the server's environment. It is never a tool argument, so it never enters the agent's context. Each test runs in its own process; what your function prints goes to a local log file, not to the agent.

API

Works today

Start a run over HTTPS, watch it live, fetch the fix.

Every request carries Authorization: Bearer with a dsl_ API key. Every route is scoped to your workspace; another workspace's ids return 404. Errors are problem+json.

# the key is shown once, when you create it
export DSL_API_KEY=dsl_...
export DSL_API_URL=https://[YOUR API HOST]

curl "$DSL_API_URL/v1/credits" \
  -H "Authorization: Bearer $DSL_API_KEY"

Keys. Create one in the app under Settings, API keys. DSL stores only a SHA-256 hash, so the secret is shown once. Revoking a key stops it at once.

Credits. GET /v1/credits returns your balance, your plan, your latest 10 ledger entries and your limits: the most users a run may ask for, and how many runs may be active at once.

Targets. POST /v1/targets registers the app to test. For an endpoint, its auth header is sealed with AWS KMS before it is stored. How secrets are handled

Prove you own the host. An endpoint target carries a token for its exact host. Publish it as the whole body of https://<host>/.well-known/dsl-verify.txt, or as a DNS TXT record at _dsl-verify.<host> with the value dsl-verify=<token>, then call POST /v1/targets/{id}/verify. DSL checks again before every run and about every 10 minutes during it. A DNS change can take up to the record's TTL to be seen.

IllustrativeSnippets follow the OpenAPI contract. The API host is a placeholder until launch.

Fix notebook

Every run ends with the fix to make first.

  1. 01The run finishes. Endpoint runs get the notebook at the end. For pip and MCP runs a DSL worker writes it shortly after, from the numbers your machine reported.
  2. 02Read it in the app. What was measured, the likely cause, reviewed fix code, other things to check and how to rerun.
  3. 03Copy a cell or download the .ipynb. DSL never runs the code. Treat it as a template for your own client and names.
  4. 04Or fetch it from code. GET /v1/notebooks/{id}, or dsl_notebook from your agent.
Keep your app steady past 56 users.ipynb

Errors rose from to as load rose. Likely cause: your model provider's rate limit. Worth checking before you add capacity.

pythoncopy
# Retry rate-limited calls with backoff.
# A template: adapt it to your own client.
for attempt in range(5):
    try:
        return client.answer(question)
    except RateLimitError:
        time.sleep(min(8, 0.5 * 2 ** attempt))

Rerun with the same settings to check it. Results of an unchanged app vary from run to run, so only a clear change counts.

Sample notebookShortened from a notebook DSL wrote for its own test app.

Sign-in and keys

People sign in with WorkOS. Code uses an API key.

In the browser

Sign in through WorkOS AuthKit. Your organization selects your workspace, and everyone in it sees the same runs and credits. The app sends a short-lived access token; DSL checks its signature, expiry and issuer on every request. Someone who signs in without an organization gets a personal workspace of their own.

From code, CI and agents

Create dsl_ keys in Settings. The secret is shown once and stored only as a SHA-256 hash. Keys belong to one workspace, list without their secret, and revoke at once. The CLI and MCP server read the key from the environment, never from a flag or a tool argument.

Four ways to connect

Pick where the load is generated.

ModeWhere it runsWhat DSL seesAnswer qualityCreditsStatus
EndpointDSL's workers call your public HTTPS staging URL.Timings, errors, and the sampled answers it grades.Graded at up to three loadsWorks today
pip CLIYour machine or CI, against your Python function.Numbers only. Results marked unverified.SkippedComing soon
MCP + skillYour machine, started by your coding agent after your yes.Numbers only. Results marked unverified.SkippedComing soon
Hosted sandboxAn isolated sandbox built from your repo at a pinned commit, with outbound traffic limited to hosts you list.Your app's code inside the sandbox, timings and graded answers.Graded at up to three loadsComing soon

CI gate

Planned

A check that fails a pull request when the stable load drops. Not built: there is no CI integration or app today. Once the pip CLI is published you can call dsl test from any CI job yourself; it exits 0 when the run is done and 1 when it fails, for example in the dry run.

Tell us what you need

Start with an endpoint today. Bring pip and MCP when they ship.

The free plan includes 10 credits a month: two runs.