SDKs & CLI
Exemplar Platform is not “SDK-only.” Most day-to-day configuration lives in the console UI; SDK and CLI embed or automate the same control plane from code and terminals.
This guide maps Marshal (agentic harness toolkit) and Relay (coding-agent governance) across three touchpoints—and where Python / TypeScript SDKs line up.
Three touchpoints
| Touchpoint | Best for | Packages / entry |
|---|---|---|
| Console UI | Org setup, policy authoring, Connect install snippets, Live wire / Pulse, HITL inbox, Behavior Guards | console.exemplar.dev |
| Marshal SDK | Embed memory, skills, prompts, HITL, MCP tools, session ingest, and in-process Relay adapters in agent frameworks | Python exemplar-harness-sdk · TypeScript @exemplar-dev/exemplar-harness-typescript-sdk |
| Marshal CLI | CI, operator runbooks, quick list/add/search of skills, prompts, memory | exemplar-cli |
Deep dives: Marshal SDK · Marshal CLI · Relay Connect · IDE agent skills
When to use which
| Job | Prefer |
|---|---|
| Author bash / path / MCP / prompt Control rules | UI — Relay → Rulebook |
| Tune Behavior Guards, Acknowledge incidents | UI — Relay → Guards / Pulse / Live |
| Install Cursor / Claude Code / Codex / OpenCode hooks | UI Connect snippets or exemplar-skills (/exemplar-relay) — not SDK/CLI policy editors |
| Seat engineers, Enforcement mode | UI — Relay seats & org settings |
| Call memory / skills / prompts / HITL from an agent runtime | SDK (Python or TypeScript) |
| Enforce org Relay policy inside LangChain, Claude Agent SDK, Mastra, … | SDK harness.relay({ surface }) |
| Script skills/prompts/memory in CI | CLI |
| Browse Tools & MCP catalog, copy MCP configs | UI — Marshal → Tools & MCP |
Marshal — feature × touchpoint
Marshal is Exemplar’s agentic harness toolkit. Registries and ops often start in the UI; runtimes consume them via SDK/CLI.
| Capability | Console UI | SDK (Py / TS) | CLI (exemplar-cli) |
|---|---|---|---|
| Memory — add / search / recall | View / operate in console | Yes | Yes (exemplar memory …) |
| Skills — create / search / install | Skill management | Yes | Yes (exemplar skills …) |
| Prompts — templates / build / run | Prompt management | Yes | Yes (exemplar prompts …) |
| HITL — approval gates | HITL Approvals inbox | Yes (harness.hitl()) | — |
| Evals / guardrails | Configure & review | Via platform APIs / gateway clients as documented | — |
| Tools & MCP | Catalog, Connect snippets | harness.tools() + framework adapters | — |
| Context Lake / connectors | Enable connectors, browse context | Context used via memory / tools / gateway | — |
| Gateway | Keys, routing, cache, failover | OpenAI-compatible clients + SDK helpers | — |
Docs: Memory · Skills · Prompts · HITL · SDK client usage · CLI commands · Tools & MCP
Relay — feature × touchpoint
Relay policy is authored and observed in the UI. IDE coding agents attach via hooks you install from Connect (or exemplar-skills). The Marshal SDK can evaluate the same Control + Enforcement stack for framework agents running in your process—not as a replacement for Cursor/Claude rule editors.
| Capability | Console UI | SDK Relay adapters | CLI |
|---|---|---|---|
| Control rules (bash, path, MCP, prompt) | Rulebook — primary authoring | Evaluates rules at runtime (decide / observe / evaluate) | — |
| Enforcement (observe / soft / enforce) | Org setting | Honored on evaluate | — |
| Behavior Guards | Guards · Sample · Configure · Acknowledge | Pattern detectors when hooks fire | — |
| Connect IDE surfaces (Cursor, Claude Code, Codex, OpenCode) | Relay → Connect + verify | — (use Connect / skills) | — |
| Framework Relay (LangChain, Claude Agent SDK, Mastra, …) | Same org rules apply | Yes — harness.relay({ surface }) | — |
| Live wire / Pulse / Session Trace | Primary ops surface | Events appear when SDK/IDE hooks call Relay | — |
| Audit / retention | Console + plan limits | Writes to same audit trail | — |
| Seats | Seats & policy | Auth via API key + seat entitlements | — |
IDE hooks ≠ SDK. Cursor, Claude Code, Codex, and OpenCode install hooks from Relay → Connect (or /exemplar-relay). You do not configure those IDE rulesets through exemplar-cli or by pasting SDK code into the editor. Rulebook + Guards stay in the UI; hooks only forward tool events to Relay.
Docs: Relay · Connect surfaces · Control rules · Behavior Guards · SDK Relay in Client usage · live adapters on Live SDK examples
SDK language parity (Python ↔ TypeScript)
Both SDKs target the same Marshal / Relay APIs. Naming differs (snake_case vs camelCase).
| Area | Python | TypeScript | Notes |
|---|---|---|---|
| Client | Harness.from_env() | Harness.fromEnv() | Product name Marshal; class still Harness |
| Memory | harness.memory(...) | harness.memory(...) | Parity on add / search / recall |
| Skills | harness.skills() | harness.skills() | Parity |
| Prompts | harness.prompts() | harness.prompts() | Parity |
| HITL | harness.hitl() | harness.hitl() | Console decides; SDK waits |
| MCP tools | harness.tools() | harness.tools() | See Frameworks |
| Session ingest | Yes | Yes | Framework helpers differ by runtime; set auto_judge_run / auto_session_eval for Insights + Session Evals — Evals |
| Relay adapters | Broad Python matrix (ADK, Agno, CrewAI, Pydantic AI, Semantic Kernel, …) | Claude hooks, OpenAI Agents, LangChain/LangGraph, Mastra | See adapter table on Client usage |
CLI covers skills / prompts / memory scripting—not full SDK feature parity (no HITL wait loop, no framework Relay adapters).
Auth quick reference
| Surface | Key type | Typical env |
|---|---|---|
| Marshal SDK / CLI / Tools & MCP clients | Org API key (eis_*) | EXEMPLAR_API_KEY |
| Relay IDE hooks (Connect) | Personal key with Relay scope | EXEMPLAR_API_KEY in hook / bridge env |
| Optional Relay API origin | — | EXEMPLAR_RELAY_BASE |
Create keys under Account Settings → Tokens.
Live examples (not simulated)
Curated demos that POST to the live Exemplar API: Live SDK examples · exemplar-platform-samples.
| Area | Start here |
|---|---|
| Memory / skills / prompts / HITL | Python examples/live/*_demo.py |
| Framework + MCP | langchain_demo, agno_demo, google_adk_demo, … |
| In-process Relay | Python examples/relay/ · TypeScript examples/relay/ |
| Session ingest (TS) | examples/ingest/ |