Skip to content
CCinder
Installation

Getting Started

Installation

Install the browser SDK first, then add the server package only if you want hybrid fallback inference.

Recommended first setup

Start with the browser runtime only. Keep AI disabled until scan, graph, local resolution, and DOM execution work cleanly in your app.

Cinder is browser-first. The fastest path is to install the client SDK, tag one real page, prove the local-first flow, and only then decide whether you need fallback.

Using a coding agent? Skip ahead

Paste this to your agent - it installs the SDK, tags your real app, and configures it on its own, with no further input from you:

Code
1 line
Install usecinder in this project (npm install usecinder), then fetch https://usecinder.dev/get-started/prompt.md and follow it completely.

See Agent Onboarding for exactly what that does. Otherwise, keep reading for the manual path.

Install the browser SDK

The main browser package is usecinder (the exported singleton is still called Cinder - only the npm package name is usecinder).

bash
1 line
npm install usecinder

Optional packages

None of these are required for the local-first path - add them only when you need what they do.

PackageInstall when you wantMore
@usecinder/embeddingsTier 2: a free, client-side model that recovers typos/paraphrases before any network callTier 2: Embeddings
@cinder/relayTier 3: hosted, metered AI fallback - the only way to add tier-3 fallbackRelay Overview
@usecinder/cli (dev-only)Crawl your real app and audit every page for tagging gapsCLI Overview
bash
1 line
npm install @cinder/relay

Browser-first initialization

Use a local-first config for the first integration:

ts
14 lines
import { Cinder } from 'usecinder';

await Cinder.init({
  semantic: {
    scanOnInit: false,
    observeMutations: true,
  },
  ai: {
    enabled: false,
    mode: 'local',
    endpoint: '',
    apiKey: '',
  },
});

Why start this way

  • it proves the product core first
  • it keeps failure modes easier to inspect
  • it prevents fallback from hiding tagging or graph problems
  • it makes route/context scoping easier to debug

What the first page should look like

Your first page should be intentionally small:

  • one tagged route
  • one tagged context
  • one tagged action, field, filter, or output
  • standard DOM behavior where possible

If the first page is too large, it becomes harder to tell whether a problem comes from tags, graph shape, app timing, custom controls, or unsupported assumptions.

What to do immediately after init

After the runtime is ready:

  1. add semantic tags to a real page
  2. call await Cinder.scan(document)
  3. inspect Cinder.graph()
  4. execute a first command with await Cinder.run(...)
ts
6 lines
await Cinder.scan(document);
console.log(Cinder.lastScan());
console.log(Cinder.graph());

const result = await Cinder.run('open reports', document);
console.log(result.intent, result.dispatch, result.reflex);

When to enable fallback

Enable fallback only after the local path is already working for your common commands. Tier-3 AI fallback requires a Relay project - create one, then point ai.endpoint at it:

ts
14 lines
await Cinder.init({
  semantic: {
    scanOnInit: false,
    observeMutations: true,
  },
  ai: {
    enabled: true,
    mode: 'hybrid',
    endpoint: 'https://your-relay-host/v1/relay/infer',
    apiKey: 'ck_your_relay_project_api_key',
    provider: 'custom',
    timeoutMs: 10000,
  },
});

The browser runtime still stays primary. Fallback exists for unknown or weak local understanding, not as the default execution path.

Next steps

Continue reading