Skip to main content
Prerequisites:
  • Node.js 20 or higher
  • pnpm installed globally
  • A local clone of agentlab with dependencies installed (pnpm install)
If you have not run the app yet, start with the Quickstart.

Everyday commands

All development commands run through pnpm.
1

Start the dev server

Runs the Express/tRPC server under tsx watch and serves the Vite React client. The server restarts on file changes.
2

Type-check the project

Runs tsc --noEmit across the client, server, and shared code. Use this before opening a pull request.
3

Run tests

Executes the Vitest suite once. Add --watch locally when iterating on a single test file.
4

Build for production

Builds the client with Vite and bundles the server with esbuild into dist/.

Repository layout

Database migrations

The database is managed with Drizzle ORM. Schema and generated SQL migrations live under drizzle/. To generate a new migration from schema changes and apply it locally, run:
This runs drizzle-kit generate followed by drizzle-kit migrate.

Change control

Agent Lab tracks meaningful changes to operating materials in docs/operations/change-control-register.md. Log an entry whenever you change:
  • workflow packages under workflows/
  • operating docs under docs/operations/
  • agent prompts
  • tracker schemas
  • kit manifests
Before marking a workflow-package change complete, run:
This executes scripts/verify-change-control.mjs, which fails if a tracked change is missing from the register. Fix any reported gaps before shipping.

Formatting

The repo uses Prettier. Format the whole tree with:

Troubleshooting

Agent Lab targets Node.js 20 or higher. Check your version with node --version and upgrade if needed. Tools like nvm or fnm make it easy to switch versions per project.
Add an entry describing the change to docs/operations/change-control-register.md, then rerun the command. If the change should be deferred, move it to docs/operations/scheduled-change-queue.md instead.
Confirm your database connection settings match drizzle.config.ts and that no earlier migration is pending. Regenerate with pnpm db:push after fixing the schema.