# AGENTS.md

Make humans and AI agents work as one team — open-source and self-hostable.

## Setup

```
pnpm install
```

## Commands

```
pnpm build                 # produce a build
pnpm test                  # run the test suite, must pass before any commit
pnpm typecheck             # type check without emitting
pnpm lint                  # lint
pnpm dev:web
pnpm dev:docs
pnpm dev:desktop
pnpm dev:desktop:staging
```

## Layout

- `server/`   1598 source files
- `packages/` 1572 source files
- `apps/`     603 source files
- `scripts/`  24 source files
- `e2e/`      18 source files
- `examples/` 9 source files

## Conventions

- Tests live alongside the code they cover, following `apps/desktop/scripts/package.test.mjs`.
- CI defines what passing means. See `.github/workflows/ci.yml`, and keep it green.
- TODO: add the two or three conventions a newcomer always gets wrong here.

## Gotchas

- `server/internal/daemon/daemon.go` is 383KB. It will not fit comfortably in context, so read it in parts.
- Copy `.env.example` before running anything that needs configuration.

---

Drafted by agentreadme.com from what is in this repository. Everything marked TODO
needs a human. Check it in as AGENTS.md at the root.
