| Directory | Component | Stack |
|---|---|---|
cli |
CLI (with MCP server) | Go, Cobra, mcp-go |
sdk/go |
Go SDK | Go |
sdk/python |
Python SDK | Python |
plugins/cq |
Agent plugin (skills, commands, hooks) | Markdown, Python |
scripts/install |
Multi-host installer | Python (stdlib only at runtime) |
server |
Remote knowledge server | Python, FastAPI, TypeScript, React |
git clone https://github.com/mozilla-ai/cq.git
cd cq
make setupThe quickest way to run everything is with Docker Compose.
Export the required secret first:
export CQ_JWT_SECRET=dev-secretStart all services (runs in the foreground):
make compose-upIn a separate terminal, create a user and load sample knowledge units:
make seed-all USER=demo PASS=demo123The remote API is available at http://localhost:3000.
For isolated component testing outside Docker, use make dev-api (remote API) and make dev-ui (dashboard).
To point your agent at a local API instance, set CQ_ADDR.
Add to ~/.claude/settings.json under the env key:
{
"env": {
"CQ_ADDR": "http://localhost:3000"
}
}Add to ~/.config/opencode/opencode.json or your project-level config, in the MCP server's environment key (not env):
{
"mcp": {
"cq": {
"environment": {
"CQ_ADDR": "http://localhost:3000"
}
}
}
}CQ_API_KEY is documented in the README but not yet implemented (see #63, #80).
| Command | Purpose |
|---|---|
make compose-up |
Build and start services |
make compose-down |
Stop services |
make compose-reset |
Stop services and wipe database |
make seed-users USER=demo PASS=demo123 |
Create a user |
make seed-kus USER=demo PASS=demo123 |
Load sample knowledge units |
make seed-all USER=demo PASS=demo123 |
Create user and load sample KUs |
| Command | Purpose |
|---|---|
make lint |
Format, lint, and type-check all components |
make test |
Type checks and tests across plugin server and server backend |