Independent verification layer for software projects
Project description
Assay
Independent verification layer for software projects. Assay runs Playwright-based browser tests in Docker, captures screenshots and results, formats them as structured task packets, and delivers them to a Grain workflow via the ingest API.
Requirements
- Python 3.11+
- Docker (for
assay run) - Node.js 18+ (for the TypeScript browser SDK)
Install
uv tool install assay-kit
Or with pip:
pip install assay-kit
Or from source:
git clone https://github.com/Diwata-Labs/Assay.git
cd Assay
pip install -e .
Quick Start
1. Configure
Create assay.toml in your project root (all fields optional — defaults shown):
[project]
name = "my-project"
[runner]
docker_image = "assay-playwright:latest"
timeout_seconds = 300
[output]
directory = "./assay-output"
[serve]
host = "127.0.0.1"
port = 8000
[keys]
store = "~/.assay/keys.json"
[schedule]
store = "~/.assay/schedules.json"
2. Run a test
assay run --target https://your-app.example.com
Exit codes: 0 = pass, 3 = fail, 1 = inconclusive or error.
3. Start the ingest server
# Create an API key first
assay key create --name ci
# Start the server
assay serve
4. Schedule recurring runs
# Add a schedule (standard 5-field cron)
assay schedule add --cron "0 8 * * *" --suite smoke --target https://your-app.example.com
# List schedules
assay schedule list
# Start the scheduler (foreground; Ctrl+C to stop)
assay schedule run
# Remove a schedule
assay schedule remove <id>
Browser SDK
Install the TypeScript SDK in your web app:
npm install assay-sdk
import { AssaySDK } from "assay-sdk";
const sdk = new AssaySDK({
apiKey: "your-api-key",
endpoint: "http://localhost:8000",
});
// Capture a screenshot + metadata and POST to /ingest
await sdk.capture({ comment: "Optional human note" });
Docker Runner
The assay run command requires a pre-built Docker image containing Playwright.
Build locally
cd runner
docker build -t assay-playwright:latest .
Use a custom image
Set docker_image in assay.toml:
[runner]
docker_image = "myregistry.example.com/assay-playwright:latest"
Or override per-run (future flag — not yet wired in v0.1).
Development
# Install with dev dependencies
pip install -e ".[dev]"
# Run tests
pytest
# Lint
ruff check src/ tests/
# Type check
mypy src/assay
License
MIT
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 assay_kit-0.2.0.tar.gz.
File metadata
- Download URL: assay_kit-0.2.0.tar.gz
- Upload date:
- Size: 68.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a3fc5b7d2a03eb2f0d370da517b914629ca7ad7277906c86e7a27aadb4c761dc
|
|
| MD5 |
9b256139e37e8016acd70b145122d619
|
|
| BLAKE2b-256 |
e54d6c470743182395784d3c5c4f2b374ff444c0e120fa4324e25e83b04a1c04
|
File details
Details for the file assay_kit-0.2.0-py3-none-any.whl.
File metadata
- Download URL: assay_kit-0.2.0-py3-none-any.whl
- Upload date:
- Size: 40.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45949e3478c4c29db2d16c338fa69c2ee429a916d47aa2b85771d82f2c9bbca7
|
|
| MD5 |
1d3ceaf4f86dc3a4d06459cb7b96d727
|
|
| BLAKE2b-256 |
9f63b1eae275f227e23e3537cea4164868025f1679361d39f8603318f7c2c8e0
|