Skip to content
CCinder
Writing Custom Intents

Guides

Writing Custom Intents

Extend local resolution with explicit app-side matchers instead of hiding domain logic inside the SDK core.

Use custom intent matchers when the default local planners are not enough for your app.

Typical example

ts
17 lines
Cinder.registerIntent({
  id: 'open-dashboard-shortcut',
  match({ normalizedInput }) {
    if (normalizedInput.normalized !== 'open dashboard') {
      return undefined;
    }

    return {
      intent: 'navigate',
      target: 'dashboard',
      confidence: 0.95,
      source: 'local',
      normalizedInput,
      steps: [{ type: 'navigate', target: 'dashboard' }],
    };
  },
});

Good use cases

  • explicit command shortcuts
  • app-specific composite behaviors
  • domain-specific local rules
  • preserving domain logic as opt-in, not hidden core behavior

Continue reading