agentskit.js

Activation recipes

Problem-led quickstarts that move from a first AgentsKit result to a second ecosystem component.

Activation recipes are short, executable paths for discovering AgentsKit through a result. Each path names at least two components, shows an observable output, and ends with one next action.

These recipes are local and advisory. They do not publish, merge, comment on pull requests, or change the Registry or distribution ledger.

#Start here: first result without a provider key

Install the runtime packages and run the existing first-agent fixture:

npm install @agentskit/core @agentskit/runtime tsx
cat > agent.ts <<'EOF'
import type { AdapterFactory } from '@agentskit/core'
import { createRuntime } from '@agentskit/runtime'

const localAdapter: AdapterFactory = {
  createSource(request) {
    const task = request.messages.at(-1)?.content ?? 'your task'
    return {
      async *stream() {
        yield { type: 'text' as const, content: `Agent ready. I received: ${task}` }
        yield { type: 'done' as const }
      },
      abort() {},
    }
  },
}

const runtime = createRuntime({ adapter: localAdapter })
const result = await runtime.run('Plan my first production agent')
console.log(result.content)
EOF
npx tsx agent.ts

Expected output includes:

Agent ready. I received: Plan my first production agent

Continue with Chat so the same task becomes interactive:

npx @agentskit/chat-cli init ./chat-app --renderer react --yes

The first success metric is time_to_first_result. The next-component metric is second_component_completion.

#Prioritized catalog

PriorityRecipeComponentsObservable resultNext actionMetric
R0First result without a keyAgentsKit + Chatruntime output and Chat taskopen Chat startertime_to_first_result
R0Registry agent in ChatRegistry + AgentsKit + Chatcopied research agent runs in the same rendererask the docs-first questionsecond_component_completion
R0Docs-first local ChatPlaybook + Chat + Doc Bridgeverified answer with a source pathresolve the handoffdeterministic_answer_rate
R0Handoff before editingDoc Bridge + PlaybookstartHere, edit roots, and checksrun advisory reviewhandoff_resolution_rate
R0Review before mergeCode Review + Playbook + Doc Bridgeadvisory findings and a separate gateadd cited retrievalreview_completion_rate
R1Cited document answerAgentsKit + Chat + Doc Bridgeanswer with a valid source IDcompare adapterscitation_coverage
R1Provider swap evaluationAgentsKit + Playbook + Code Reviewfixture invariants preserved across adaptersrun bounded agentprovider_swap_pass_rate
R1Sandboxed code agentAgentsKit + Registry + Code Reviewbounded run, cleanup, and review resultreturn to zero-key startsandboxed_run_success

#Component handoffs

#Registry to Chat

npx agentskit add research

Run the copied source-owned agent with a local adapter or cassette, then keep the Chat renderer unchanged. A provider key is optional for the fixture path.

#Docs-first handoff

npx ak-docs demo --text
npx agents-playbook list
npx agents-playbook run no-any named-exports --cwd "$PWD"

The result should expose a source path, edit root, checks, and an explicit unresolved path for questions outside the deterministic fixture.

#Review before merge

npx @agentskit/code-review --help

For a real local review, use an already configured provider, keep the review advisory, limit files, and preserve the report. Do not grant the recipe permission to comment, merge, release, or publish.

#Quality contract

  • Every recipe has two or more named components.
  • Every recipe has a copy/paste command, expected output, CTA, and metric.
  • The zero-key path remains available without Ollama or another provider.
  • Analytics may record only recipe identity, component, CTA, duration, and safe error codes.
  • Model suggestions remain advisory; deterministic checks and human review retain authority.

Explore nearby

✎ Edit this page on GitHubΒ·Found a problem? Open an issue β†’Β·How to contribute β†’

On this page

Ask the docs
Ask anything about AgentsKit. Answers come from the docs corpus and cite their sources.