# Use and adapt anan-ai

Use the documented interfaces and source layout for **anan-ai**. The sections below retain the README’s examples and configuration details.

## Important Commands

```bash
pnpm --filter web dev
pnpm --filter admin dev
pnpm --filter web build
pnpm --filter admin build
pnpm --filter admin test
pnpm gates
pnpm test:e2e:web
pnpm admin:bootstrap-password
```

## Architecture Rules

If you are changing architecture-sensitive code:

1. Read `ARCHITECTURE.md`.
2. Read `CONVEX_RULES.md`.
3. Use the nearest package or app `README.md`.
4. Keep surfaces thin and push durable business behavior into the owning package, server boundary, or Convex module.
5. Keep Partners-owned data out of Anan.
6. Keep Anan workspace authorization and OAuth grants inside Anan.

## Commands in the root manifest

The captured [package.json](https://github.com/Up-to-code/anan-ai/blob/HEAD/package.json) declares the following scripts. Run them from the directory containing that manifest.

| Command | Script |
| --- | --- |
| `npm run dev` | `convex dev` |
| `npm run typecheck` | `tsc --noEmit` |
| `npm run test` | `vitest` |
| `npm run build` | `pnpm --filter @anan/base-logic build && pnpm --filter @anan/platform-core build && pnpm --filter @anan/auth build && pnpm --filter @anan/auth-sdk build && pnpm --filter @anan/domain-contracts build && pnpm --filter @anan/market-logic build && pnpm --filter @anan/crm-logic build && pnpm --filter @anan/offers-logic build && pnpm --filter @anan/workspace-logic build && pnpm --filter @anan/compliance-logic build && pnpm --filter @anan/convex-adapters build && pnpm --filter @anan/auth-client build && pnpm --filter @anan/web-foundation build && pnpm --filter @anan/ui build && pnpm --filter @anan/testing build && pnpm build:web && pnpm build:admin && pnpm --filter @anan/authorization build` |

## Troubleshoot a local change

1. Reproduce the smallest example from the [quick-start guide](/docs/up-to-code-anan-ai/quick-start-guide).
2. Compare required configuration and dependency versions with the README.
3. Check the linked issue tracker for the same error. Include the command, runtime version, and relevant error when reporting a problem; omit credentials.

## Source and help

- [GitHub repository](https://github.com/Up-to-code/anan-ai)
- [Original README](https://github.com/Up-to-code/anan-ai/blob/main/README.md)
- [Issues and existing reports](https://github.com/Up-to-code/anan-ai/issues)
- [Open the project website](https://anan-lit-web.vercel.app)
