Getting Started with Nexlem
Nexlem is a Claude Code-native content factory. One command produces a researched, quality-checked blog article plus all derived social media assets — no external services, no per-token billing, just your Claude Max subscription and a local SQLite database.
This guide walks you through installing Nexlem globally, initializing a project with the configuration wizard, and running your first content campaign.
1. Prerequisites
- Bun 1.x — runtime, package manager, and built-in SQLite driver; install from
bun.sh:
curl -fsSL https://bun.sh/install | bash - Claude Code — the agent runtime; install via
npm install -g @anthropic-ai/claude-codeor follow docs.claude.com - A Claude Max subscription — text generation is delegated to Claude Code subagents; no Anthropic API key is required, no per-token billing applies
- macOS or Linux (Windows via WSL2)
You do NOT need:
- An Anthropic API key
- Any third-party social publishing, image-generation, or AI-gateway service accounts
- A separate database server (SQLite via
bun:sqliteis built in)
2. Install
Nexlem is installed globally via your package manager — bun is recommended.
See docs/install.md for per-PM commands and verification steps.
3. Configure
Initialize a Nexlem project in your content project directory. Run this inside Claude Code:
/nexlem init
The wizard collects four configuration sections:
| Section | What it captures |
|---|---|
| project | Project name, primary language |
| business | Brand name, editorial voice, target audience, disclaimer rules |
| main-site | Site slug, base URL, publish hand-off target |
| gates | Quality-gate thresholds — fact-check, E-E-A-T, humanizer, SEO minimums |
The wizard writes three JSON(C) files:
config/project.jsonc— project-level defaultsconfig/business.jsonc— business identity and editorial voiceconfig/sites/<slug>.jsonc— per-site settings
All three are files you can edit by hand. Use /nexlem reconfigure to re-run the wizard
for any section.
Verify the configuration cascade:
node_modules/.bin/nexlem-sdk query setup.checkA valid output looks like:
{
"ok": true,
"checks": [
{ "name": "nexlem_exists", "status": "pass" },
{ "name": "config_valid", "status": "pass" },
{ "name": "hooks_installed", "status": "pass" },
{ "name": "manifest_present", "status": "pass" }
]
}4. Run Your First Campaign
Run inside Claude Code — The steps in this section require Claude Code because Nexlem delegates text generation to Claude Code subagents. The commands in §§ 2–3 above (install, setup, init, setup.check) run without Claude Code; the pipeline steps below do not.
Start a campaign with a topic and your site slug:
/nexlem run "Your article topic" --site <your-site-slug> --type full
The topic is a positional argument to
/nexlem run(not a--topicflag). The--topicflag exists only on/nexlem campaign create.
The --type full pipeline has 14 stages:
- Blog channel (stages 1–10, sequential): research → writer → fact-check → eeat → humanizer → seo → disclaimer → image-planner → quality-gate → atomizer
- Social channel (stages 11–14, parallel after atomizer): carousel, caption, reel-script, youtube-short
Nexlem assigns a campaign id and starts stage 1 immediately. Structured log lines appear in Claude Code's output stream:
{"level":30,"time":1747476000000,"event":"agent_start","campaign_id":"...","agent":"research","version":"1.0.0","step":1,"total":14}Check progress
/nexlem status
Output:
Campaign: Your article topic (<campaign-id>)
Status: running
Progress: 3/14 (research ✓ → writer ✓ → fact-check running)
Review the quality gate
After stage 9 (quality-gate) completes, the gate output at
campaigns/<id>/steps/09-quality-gate.json contains:
{
"verdict": "APPROVED",
"overall_score": 9.05,
"min_score_required": 7
}A score below your configured quality-gate threshold (the quality_gates_business
block in config/business.jsonc) produces "verdict": "REJECTED" and
halts the pipeline before the social fan-out.
Campaign complete
Campaign: Your article topic (<campaign-id>)
Status: completed
Progress: 14/14
Quality verdict: APPROVED
5. Resume an Interrupted Campaign
Each stage checkpoints to SQLite atomically on success. If a campaign is interrupted, re-run the same command or use the campaign id directly:
/nexlem campaign run <campaign-id>
Nexlem detects completed stages and skips them. Execution resumes from the first incomplete stage.
6. Multiple Sites and Batch Campaigns
Add additional sites to the same project:
/nexlem site add --slug second-site --url https://second-site.com
Queue and run a batch:
/nexlem campaign create --site <slug> --topic "Topic A" --keyword "keyword a"
/nexlem campaign create --site <slug> --topic "Topic B" --keyword "keyword b"
/nexlem run --batch --site <slug>
7. Editorial Calendar
Plan content ahead of time:
/nexlem calendar plan \
--site <slug> \
--topic "Top 5 compact hatchbacks" \
--date 2026-06-01
/nexlem calendar view --site <slug> --weeks 4
8. Inspect Metrics
After a few campaigns, view agent performance metrics:
/nexlem metrics agents --since 2026-05-01
/nexlem metrics campaigns --site <slug>
9. Dev-Mode Logging
For human-readable logs during local development:
bun run src/main.ts campaign run <id> | pino-prettyWhere to Go Next
| Document | What it covers |
|---|---|
docs/COMMANDS.md | Full reference for all commands, grouped by workflow |
docs/SDK_REFERENCE.md | All nexlem-sdk query handlers with JSON shapes |
docs/COOKBOOK.md | 3–5 real-world campaign recipes |
docs/CONFIG.md | Config cascade schema and Zod validation rules |
docs/AGENTS.md | All 16 registered agents (14 pipeline + 2 standalone tools) — purpose, inputs, outputs |
docs/STABILITY.md | Stability tiers for SDK queries and skill commands |
docs/RELEASING.md | How to cut a release and publish to npm |