dist/codex/nlweb-protocol/skills/nlweb-setup/SKILL.md
Bootstrap a local NLWeb development environment from scratch — clone the repo, configure .env, install Python deps via `nlweb init-python`, run `nlweb init` for interactive LLM/retrieval selection, load sample Schema.org data, and verify with `nlweb check`. Use when starting a new NLWeb deployment from zero.
npx skillsauth add orcaqubits/agentic-commerce-claude-plugins nlweb-setupInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Fetch live docs first:
nlweb CLI flags.site:github.com/nlweb-ai/NLWeb docs/release_notes and read the most recent dated release note — config keys and required env vars change between releases.write_endpoint and verify which backends are enabled by default in config/config_retrieval.yaml on main.A working NLWeb dev environment has four parts:
.env file with provider credentials (OpenAI/Azure OpenAI key + retrieval backend secrets).:8000 with /ask, /mcp, /sites reachable.NLWeb ships with three retrieval backends enabled by default in config_retrieval.yaml:
qdrant_local (file-backed, fine for dev)nlweb_west (Azure AI Search — requires Azure credentials)shopify_mcp (queries Shopify's MCP endpoint, requires network)For most local-dev cases, disable the latter two by setting enabled: false so you don't get connection errors at startup. The write_endpoint should point to qdrant_local for dev.
text-embedding-3-small on Azure OpenAI.development (allows query-string config overrides) or production in config_webserver.yaml?NLWeb/ # cloned repo
├── AskAgent/python/
│ ├── app-aiohttp.py # main entry
│ ├── core/, methods/, webserver/ # core code
│ ├── llm_providers/, embedding_providers/, retrieval_providers/
│ └── data_loading/
├── config/
│ ├── config_llm.yaml
│ ├── config_embedding.yaml
│ ├── config_retrieval.yaml
│ ├── config_nlweb.yaml
│ ├── config_webserver.yaml
│ ├── config_oauth.yaml
│ ├── config_storage.yaml
│ ├── config_tools.yaml
│ ├── site_types.xml
│ └── prompts.xml
├── data/db/ # qdrant_local file store
├── .env # YOUR credentials (gitignored)
└── docs/, scripts/, demo/, tests/
git clone https://github.com/nlweb-ai/NLWeb && cd NLWebnlweb init-python (or manual python -m venv .venv && source .venv/bin/activate && pip install -r requirements.txt)nlweb init — interactive prompts walk through LLM + retrieval selection and write .envconfig/config_retrieval.yaml (nlweb_west, shopify_mcp for local-only dev)nlweb data-load <source> <site-name> — ingest sample content (use a small RSS feed for first run)nlweb check — runs connectivity diagnostics; resolve any red flagsnlweb app — start the server, hit http://localhost:8000//ask?query=hello&site=<site-name>&streaming=falseNLWeb expects credentials via env vars (never YAML). Common keys (verify live):
OPENAI_API_KEY, AZURE_OPENAI_API_KEY, AZURE_OPENAI_ENDPOINTANTHROPIC_API_KEY, GEMINI_API_KEYAZURE_SEARCH_ENDPOINT, AZURE_SEARCH_API_KEYQDRANT_API_KEY (only for remote Qdrant)SNOWFLAKE_USER, SNOWFLAKE_PASSWORD, SNOWFLAKE_ACCOUNTCLOUDFLARE_API_TOKEN, CLOUDFLARE_ACCOUNT_IDAfter setup, these should work:
curl http://localhost:8000/sites → JSON list including your loaded sitecurl 'http://localhost:8000/ask?query=test&site=<your-site>&streaming=false' → JSON with resultscurl -X POST http://localhost:8000/mcp -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' → ask, list_sites, optionally whonlweb check fails on Azure: usually AZURE_OPENAI_ENDPOINT missing trailing slash or wrong deployment name.preferred_provider in config_embedding.yaml./ask returns empty: site name in the query doesn't match the site value used during ingest, or the sites: allowlist in config_nlweb.yaml excludes it./who endpoint pinging nlwm.azurewebsites.net. Disable who_endpoint_enabled for offline dev.Always re-verify against the latest hello-world doc — the exact env-var names and CLI flags change.
development
Build with Spree's headless Next.js storefront — the official `spree/storefront` repo (Next.js 16 App Router with Server Actions and Turbopack, React 19 Server Components, Tailwind CSS 4, TypeScript 5, `@spree/sdk`, Sentry), server-only auth (httpOnly JWT cookies + publishable key), MeiliSearch faceted catalog, one-page checkout with Apple/Google Pay/Klarna/Affirm/SEPA, multi-region market routing, GA4 + JSON-LD SEO, and Vercel/Docker deployment. Use when forking or customizing the storefront, or evaluating headless adoption.
tools
Build Spree extensions as Rails engines — gem scaffolding, `bin/rails g spree:extension`, mounting routes/migrations/assets, the modern `prepend` decorator pattern (`*_decorator.rb` with `self.prepended(base)`), generators (`spree:model_decorator`, `spree:controller_decorator`), the four customization surfaces in preference order (Events > Webhooks > Dependencies > Decorators), Spree::Dependencies for swapping service objects, gem release/versioning, and the deprecated Deface engine. Use when building a reusable Spree extension or adding non-trivial customization to an app.
development
Build with Spree's event bus and Webhooks 2.0 — `Spree::Events` publication, `Spree::Subscriber` DSL with `subscribes_to` and `on`, wildcard matching, lifecycle events (`{model}.created/.updated/.deleted` via `publishes_lifecycle_events`), the canonical event catalog (order.*, payment.*, shipment.*, product.*), Webhooks 2.0 endpoints, HMAC-SHA256 signing (`X-Spree-Webhook-Signature`), exponential-backoff retries, and Sidekiq job orchestration. Use when wiring event-driven business logic, building webhook consumers, or replacing ActiveSupport callback chains.
tools
Cross-cutting Spree development patterns — the customization preference hierarchy (Events > Webhooks > Dependencies > Decorators), `Spree::Dependencies` service-object swapping, the `_decorator.rb` + `prepend` + `self.prepended` idiom, idempotent subscribers and webhook receivers, multi-store scoping discipline, prefixed IDs, calculator polymorphism (shipping/promotion/tax share the base), service-object composition with `dry-monads` or simple results, why to avoid `class_eval` reopening and Deface, and Spree-on-Rails idioms (Hotwire/Turbo Stimulus, ActiveStorage, Action Cable, Sidekiq). Use when designing the architecture of a Spree extension or solving cross-cutting concerns.