A production-ready Next.js template for AI-powered autonomous organizations.
.cogni/repo-spec.yamlis the single source of truth for the DAO receiving wallet, chain_id, and widget provider. There is no env override.- The credits page reads repo-spec server-side and passes the config to the client widget as props.
- Changing the wallet or chain requires a repo-spec edit + redeploy; build-time validation fails if repo-spec.chain_id drifts from the app CHAIN_ID.
Goal: Develop improvements and merge back into CogniDAO repo We love you! ❤️
git clone https://github.com/Cogni-DAO/cogni-template
cd cogni-template
scripts/bootstrap/setup.sh # Install tools + dependencies, prompts to start dev stack
cp .env.local.example .env.local # Configure environment (add OpenRouter API key)
pnpm dev:stack # Start developing with full stack (DB + LiteLLM + Next.js)
pnpm db:setup # Migrate and Seed database, once dev stack is running
pnpm docker:stack # Full production simulation (https://localhost - browser cert warning expected)You'll need: OpenRouter API key for AI features
Goal: Create your own autonomous organization with your unique direction We love you too, go for it! 🎯
git clone https://github.com/YOUR-ORG/your-fork
cd your-fork
scripts/bootstrap/setup.sh --all # Install all tools (includes OpenTofu, REUSE)
cp .env.local.example .env.local # Configure environment
pnpm dev:stack # Start dev stackWe're working to automate more of this! Want to help? Contribute setup automation.
scripts/bootstrap/setup.sh- One-command dev environment setup (Volta, Node 22, pnpm, Docker Desktop)scripts/bootstrap/setup.sh --all- Full setup including OpenTofu and REUSEtofu apply- VM provisioning (when manually configured)
For Contributors:
- Get OpenRouter API key for AI features
- Copy
.env.local.example→.env.localand fill in values - Observability: Local Loki + Grafana on localhost:3001 (auto-configured). For MCP log queries, optionally set
GRAFANA_URL+GRAFANA_SERVICE_ACCOUNT_TOKENfor Grafana Cloud access.
For Fork Owners (everything above, plus):
Infra Setup (see deploy.md for details)
- Generate SSH keys for deployment, move to folder, commit
- Get Cherry Servers auth token
- Update
.tfvarsfiles with your settings - Run
tofu apply
GitHub Environment Setup
- Create GitHub PAT for bot account automation (needs Contents:Write, Pull requests:Write, Actions:Read, Metadata:Read), add it as a repo environment secret named
ACTIONS_AUTOMATION_BOT_PAT - Enable your git repo to contribute packages to your git org
- Set up GitHub environments and secrets manually
- Configure branch protection rules (see docs/spec/ci-cd.md)
- SonarCloud setup: Generate token at SonarCloud Security → Add as
SONAR_TOKENrepository secret - Grafana Cloud setup (optional): Get Loki credentials from Grafana Cloud → Add
GRAFANA_CLOUD_LOKI_URL,GRAFANA_CLOUD_LOKI_USER,GRAFANA_CLOUD_LOKI_API_KEYas repository secrets (shared across environments)
DAO Setup
- Run
make dao-setupfrom cogni-signal-evm-contracts
Coming Soon: pnpm setup local|infra|github|dao commands to automate these steps!