Logo von Nats Agent Fabric

Nats Agent Fabric

Community
lithqube
nats-agent-fabric

Use this skill whenever users are building AI agents that communicate, register, or coordinate over NATS using the Synadia Agent Protocol or the Synadia Agents SDK — including exposing an agent as a discoverable NATS service, building a meta-agent/orchestrator that discovers and prompts other agents, fanning a prompt out to a fleet of agents and merging replies, streaming agent responses over NATS, human-in-the-loop mid-stream queries, agent heartbeats/liveness, or making a Go/other-language agent protocol-compliant. Triggers on the npm packages @synadia-ai/agents and @synadia-ai/agent-service, the PyPI packages synadia-ai-agents and synadia-ai-agent-service, the `agents.*` subject namespace, or phrases like "agent fabric", "agent discovery over NATS", "orchestrate a fleet of agents", "A2A on NATS", or "register my agent as a NATS service". Use this even when the user doesn't name Synadia — if they want heterogeneous AI agents to find and talk to each other over NATS, this skill applies. Do NOT use for plain JetStream stream/consumer design (use jetstream-architecture), server/cluster deployment (use jetstream-deployment), or troubleshooting a running cluster (use jetstream-operations).

Übersicht

Herausgeberlithqube
Repositorynats-jetstream-claude-skills
Skill-Namenats-agent-fabric
Sterne
28
Forks
2
Mitgelieferte Dateien
8
LizenzMIT
Links
  • Anweisungen in Markdown

    Eine SKILL.md-Datei, die das Modell bei Bedarf lädt. So werden nur dann Token verbraucht, wenn eine Anfrage tatsächlich dazu passt.

  • Funktioniert mit jedem LLM

    KI-Skills bestehen aus reinem Markdown, nicht aus anbieterspezifischem Code. Daher funktionieren sie mit GPT, Claude, Gemini, Grok oder einem lokalen Modell.

  • Mitgelieferte Dateien: 8

    Skripte, Vorlagen und Referenzmaterial, die das Modell bei der Arbeit lesen kann. Die Dateien sind schreibgeschützt und werden niemals ausgeführt.

  • Open Source

    Von lithqube auf GitHub veröffentlicht. Prüfen Sie vor der Installation die Quelldateien.

Installation

Installieren Sie den KI-Skill Nats Agent Fabric in TypingMind, um ihn mit jedem LLM zu nutzen, oder fügen Sie ihn einem anderen Agenten hinzu, der SKILL.md lesen kann.

1

In TypingMind installieren

TypingMind installiert einen Skill direkt aus seinem GitHub-Ordner. Dabei liest die App SKILL.md, bündelt die Ressourcendateien und speichert das Ergebnis lokal.

  1. Öffnen Sie die App und gehen Sie zu Plugins → Skills.
  2. Wählen Sie „Von GitHub installieren“.
  3. Fügen Sie die unten angegebene URL des Skill-Ordners ein und bestätigen Sie.
    https://github.com/lithqube/nats-jetstream-claude-skills/tree/main/nats-agent-fabric
  4. Aktivieren Sie den Skill in jedem Chat, in dem er verfügbar sein soll.
Plugins → Skills → Skill hinzufügen → Über GitHub-URL. Fügen Sie dann die Ordner-URL ein und klicken Sie auf „Weiter“.
2

In einem anderen Agenten installieren

Jeder Agent, der das Agent-Skills-Format unterstützt, kann diesen Skill nutzen. Kopieren Sie den Ordner in das Skill-Verzeichnis des jeweiligen Agenten.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/lithqube/nats-jetstream-claude-skills.git /tmp/nats-jetstream-claude-skills
mkdir -p .claude/skills
cp -r /tmp/nats-jetstream-claude-skills/nats-agent-fabric .claude/skills/nats-agent-fabric
Starten Sie Claude Code nach dem Kopieren neu, damit der neue Skill erkannt wird.

In TypingMind verwenden

Aktivieren Sie Nats Agent Fabric in einem beliebigen Chat in TypingMind. Den Rest übernimmt das Modell. Name und Beschreibung des Skills stehen im System-Prompt. Sobald eine Anfrage passt, lädt das Modell selbstständig die vollständigen Anweisungen — Sie müssen den Skill nie manuell aufrufen, und er verbraucht erst Token, wenn er tatsächlich genutzt wird.

Das Modell lädt Nats Agent Fabric automatisch, sobald eine passende Anfrage gestellt wird.

Funktioniert mit jedem KI-Modell

KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher ist Nats Agent Fabric nicht an das Modell gebunden, für das der Skill geschrieben wurde. Installieren Sie ihn einmal in TypingMind und nutzen Sie ihn mit GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder einem selbst betriebenen lokalen Modell — alles mit Ihren eigenen API-Schlüsseln.

  • Wird nur bei Bedarf geladen

    Der System-Prompt enthält nur den Namen und die Beschreibung. Die Anweisungen werden bei der ersten passenden Anfrage geladen. Ein ungenutzter Skill verursacht daher keine Kosten.

  • Modell im laufenden Chat wechseln

    Da der Skill aus Anweisungen statt aus Code besteht, funktioniert er auch nach einem Modellwechsel — das nächste Modell liest dieselbe SKILL.md-Datei.

Skill-Anweisungen

Dies ist der Inhalt von SKILL.md, den das Modell lädt. Lesen Sie ihn vor der Installation — ein Skill besteht aus Anweisungen, denen Ihr Modell folgt.

NATS Agent Fabric (Synadia Agent Protocol)

Build AI agents that register on a NATS bus, get discovered by callers, and stream replies — using the Synadia Agent Protocol for NATS and the Synadia Agents SDK.

The core idea: most agent libraries assume one process and one known endpoint. This protocol is built for the opposite shape — many agents, across many harnesses/runtimes/clouds, none known to the caller in advance. An agent is just a function from a prompt to a streamed reply (onPrompt); only the body differs. Agents register as ordinary NATS micro-services, so they inherit NATS accounts (multi-tenancy/isolation), cloud-to-edge connectivity, and a message-level audit trail "for free."

This is agent-to-agent coordination, not MCP — MCP standardizes tools/context for one agent; this standardizes discovery + transport across many agents on a shared bus. It is LLM-agnostic: it wraps harnesses (Claude Code, a DSPy ReAct loop, your own LLM service), not models.

Maturity note (read before quoting versions)

The protocol spec is v0.3 and the 0.x line is explicitly unstable. Package versions as of mid-2026: npm @synadia-ai/agents and @synadia-ai/agent-service at 0.5.2; PyPI synadia-ai-agents (~0.6) and synadia-ai-agent-service 0.4.1. Go SDK is planned, not released — for Go today, implement the wire protocol directly over nats.go micro (see examples/protocol-go.md).

Because SDK APIs may drift inside 0.x, teach the protocol (stable) and treat exact constructor/method names as current-but-verify. When generating code, tell the user to confirm the installed package version. The wire protocol is the durable contract that all SDKs and hand-rolled agents must honor.

When to defer to the JetStream skills

This skill is built on the NATS Services API (micro), not core JetStream — discovery, registration, and request/reply all use $SRV.* + queue groups. JetStream and KV enter the picture only for durable agent state and session handoff (roadmap / optional), covered in patterns/durable-state.md.

  • Designing the underlying streams/KV buckets that back durable agent memory → also read jetstream-architecture.
  • Deploying the NATS servers/accounts your agents connect to → jetstream-deployment.
  • Monitoring, troubleshooting, or tuning the running fabric → jetstream-operations.
  • Building the agent inside a Nuxt / Nitro app → the nuxt-nats skill wraps this SDK with defineNatsAgent / useAgents (a real reference implementation of a protocol-compliant TS host, incl. response.ask for human-in-the-loop).

Reference Files

Read these as needed — don't load all of them upfront:

  • concepts/protocol.md — the wire protocol: subject hierarchy, the four verbs, service registration rules, request envelope, response chunk types, stream termination, heartbeats, discovery, errors, versioning. Read this before writing any agent or caller, in any language — it's the contract.
  • concepts/architecture.md — caller (client) SDK vs host (agent) SDK, meta-agent vs worker shape, queue-group load-balancing, identity (agent/owner/name/session), and where JetStream/KV fit. Read when deciding what to build.
  • patterns/meta-agent.md — discover → fan-out → merge, liveness tracking without polling, and human-in-the-loop mid-stream queries. Read when building an orchestrator.
  • patterns/durable-state.md — using JetStream + KV for agent memory and session handoff. Read when agents need to remember or hand off work.
  • examples/typescript.md — caller + host with @synadia-ai/agents / @synadia-ai/agent-service. Read for TS/Node/Bun code.
  • examples/python.md — caller + host with synadia-ai-agents / synadia-ai-agent-service. Read for Python code.
  • examples/protocol-go.md — a protocol-compliant agent in Go over nats.go micro (no SDK yet). Read for Go, or any language without an SDK.

Workflow

Step 1: Figure out which side they're building. Host an agent (make my agent discoverable/promptable)? Call agents (orchestrate/meta-agent)? Or both? See concepts/architecture.md.

Step 2: Pick the language path. TS and Python have SDKs; Go and everything else implement the protocol directly. If they have no SDK for their language, route to examples/protocol-go.md as the template.

Step 3: Read concepts/protocol.md for the exact subjects, envelope, and chunk format — get these right regardless of SDK, because they're what makes agents interoperate.

Step 4: Implement. For hosts: register as service name agents, serve the prompt endpoint on a queue group, emit heartbeats. For callers: discover via $SRV, prompt, consume the typed chunk stream until the zero-byte terminator.

Step 5: If agents need memory or handoff, layer in JetStream/KV per patterns/durable-state.md.

Step 6: Wire identity and isolation — pick stable agent/owner/name tokens and use NATS accounts for tenant separation (defer infra to jetstream-deployment).

Core Principles

  • Honor the wire protocol exactly — service name MUST be agents, the prompt endpoint MUST use queue group agents, every response stream MUST start with a {"type":"status","data":"ack"} chunk and MUST end with a zero-byte message and no headers. These are what let a caller talk to an agent it has never seen.
  • Never construct endpoint subjects from identity (except the heartbeat subject agents.hb.{agent}.{owner}.{name}, which is fixed). Learn endpoints from the discovery ($SRV.INFO.agents) response — addressing is discovery-driven by design.
  • Discovery first, not hardcoded endpoints — the whole point is that callers don't know agents in advance. Use $SRV.PING.agents / $SRV.INFO.agents.
  • Stream, don't block — replies are a stream of typed chunks (response, status, query), consumed as an async iterator. Surface tokens as they arrive.
  • Forward-compatibility is mandatory — callers MUST silently ignore unknown chunk types and preserve unknown fields. The 0.x protocol will add types; don't crash on them.
  • Use queue groups for horizontal scale — multiple instances of the same agent share the agents queue group so prompts load-balance across them automatically.
  • Heartbeat for liveness — emit to agents.hb.* every ~30s; treat an agent offline after 3× missed intervals. Use the status request/reply endpoint to bootstrap liveness without waiting for the next beat.
  • Identity is agent/owner/name(/session) — choose stable, lowercase tokens (a–z 0–9 - _), never starting with $. These compose the subject namespace and the discovery metadata.
  • Isolate tenants with NATS accounts, not application logic — multi-tenancy comes from the bus, not your code.
  • Durable state is JetStream/KV, and it's optional — v0.3 transport is stateless micro; reach for streams/KV only when agents need memory or handoff.

Mitgelieferte Dateien

Das Modell liest diese Dateien bei Bedarf, während der Skill geladen ist. Sie werden als lesbare Dateien bereitgestellt und niemals ausgeführt.

Häufig gestellte Fragen

Was macht der KI-Skill Nats Agent Fabric?

Use this skill whenever users are building AI agents that communicate, register, or coordinate over NATS using the Synadia Agent Protocol or the Synadia Agents SDK — including exposing an agent as a discoverable NATS service, building a meta-agent/orchestrator that discovers and prompts other agents, fanning a prompt out to a fleet of agents and merging replies, streaming agent responses over NATS, human-in-the-loop mid-stream queries, agent heartbeats/liveness, or making a Go/other-language agent protocol-compliant. Triggers on the npm packages @synadia-ai/agents and @synadia-ai/agent-serv...

Warum Nats Agent Fabric in TypingMind nutzen?

Weil Sie den Skill einmal installieren und mit jedem Modell verwenden können. Nats Agent Fabric besteht aus reinem Markdown statt aus anbieterspezifischem Code. So funktioniert derselbe Skill mit GPT-5, Claude, Gemini, Grok oder einem lokalen Modell – und Sie können das Modell mitten im Chat wechseln, ohne dass der Skill seine Funktion verliert. TypingMind verwendet Ihre eigenen API-Schlüssel. Sie bezahlen die Anbieter daher direkt statt über ein Abonnement pro Nutzerplatz, und Ihre Skills und Chats bleiben in Ihrem eigenen Speicher.

Wie installiere ich Nats Agent Fabric in TypingMind?

Öffnen Sie in TypingMind Plugins → Skills → Von GitHub installieren und fügen Sie https://github.com/lithqube/nats-jetstream-claude-skills/tree/main/nats-agent-fabric ein. TypingMind liest die Datei SKILL.md, bündelt die zugehörigen Dateien und installiert alles als Skill, den Sie für jeden Chat einzeln aktivieren können.

Welche KI-Modelle können Nats Agent Fabric nutzen?

Jedes Modell, das Sie mit TypingMind verbinden. KI-Skills bestehen aus reinen Markdown-Anweisungen statt aus anbieterspezifischem Code. Daher können GPT, Claude, Gemini, Grok und lokale Modelle diesen Skill laden, wenn eine Anfrage dazu passt.

Wie viele KI-Modelle kann ich mit Nats Agent Fabric verwenden?

So viele Sie möchten. In TypingMind können Sie Nats Agent Fabric mit jedem Modell verwenden, das Skills unterstützt, etwa mit GPT, Claude, Gemini, Grok, DeepSeek, Mistral oder Llama. Dabei nutzen Sie Ihre eigenen API-Schlüssel.

Ist der KI-Skill Nats Agent Fabric kostenlos?

Ja. Der Skill wird von lithqube auf GitHub unter der Lizenz MIT veröffentlicht. Sie bezahlen nur Ihren eigenen KI-Anbieter für die verwendeten Token.

Was sind KI-Skills?

Ein KI-Skill ist ein wiederverwendbares Anweisungspaket, das einem KI-Modell vermittelt, wie es eine bestimmte Aufgabe erledigt. Es folgt dem offenen Format Agent Skills: Die Datei SKILL.md enthält den Namen und die Beschreibung des Skills. Hinzu kommen bei Bedarf Skripte, Vorlagen oder Referenzdateien für das Modell. Das Modell liest die Anweisungen nur, wenn Ihre Anfrage zum Skill passt. Ein installierter Skill verursacht daher erst Kosten, wenn er verwendet wird.

Wie unterscheiden sich KI-Skills von Plugins oder MCP-Servern?

Ein Plugin oder MCP-Server stellt einem Modell neue aufrufbare Tools bereit – Code, der auf einem System ausgeführt wird und ein Ergebnis zurückgibt. Ein KI-Skill vermittelt dem Modell stattdessen Wissen und Vorgehensweisen: wie es eine Aufgabe angeht, welche Schritte es befolgt und wie eine gute Ausgabe aussieht. Skills bestehen aus reinem Markdown und kommen daher ohne Server, API-Schlüssel und Laufzeitumgebung aus. Sie funktionieren mit jedem Modell.

Alle anzeigen

Jetzt eigenen KI-Arbeitsbereich einrichten

Abonnieren Sie unseren Newsletter und erfahren Sie mehr über neue Funktionen und kommende Gewinnspiele 👇