Skip to content
项目

关于

快速构建文本、语音和视频智能体。基于 Go 的高性能智能体后端,为每种语言提供 SDK。为搜索、知识、技能、电话、沙箱、记忆和持久化提供合理的默认设置。主权 AI。掌控你的 AI。

设计与媒体

这些数字如何统计

可以做什么

  • Public and more advanced demos/tutorials coming soon
  • Acceleration: Go + Edge servers means amazingly fast agents
  • Routing for LLM and STT
  • Connectors for Slack/WhatsApp/Linear etc

实测星标增长

24小时
+3
7天
+1
15天
+12
1个月
+26

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

StreamAgents

[!NOTE] Using Python for Agents no longer makes sense. For 0.7 we've moved to Go, with SDKs for other languages.

Stream Agents is a Go backend for building text, voice and video agents. You can build AI/agentic apps like Muse, Decagon and Harvey in a day. Built for speed & sovereign AI.

It's faster to build agents:

  1. Agents are defined in a folder structure + YAML
  2. SDKs handle chat/audio client and state
  3. All the components you need are integrated with sensible defaults. (Guardrails, Knowledge, Routing, Connectors, Sandboxes, skills, telephony)

Performance is excellent:

  1. Go runs with high concurrency and great performance
  2. The edge acceleration offloads your backend and lowers latency
  3. Audio forwarding is optimized with WARP similar to OpenAI

Sovereign AI

  1. The combination of routing, persistence and memory makes it easy to switch the underlying models.
  2. Stay in control of how costs scale.
  3. Start with the frontier models and run your own when it makes sense.

Skill

The skill enables you to build complex AI apps in hours:

  • Ask Claude/Cursor/Lovable to setup Stream, with getstream.io/SKILL.md

Quickstart

The heavy lifting is done in Go. But you can use the agents in any environment:

Pick your backend language:

Then add chat, voice and video to your app with a client SDK:

Agent Folders and CLI

The fastest way to define an agent is using the folder structure

You can quickly create a folder using the CLI

curl -fsSL https://getstream.io/cli.sh | bash
getstream agents init my-agent --template text

The structure looks something like this:

agents/my-agent/
  knowledge/       ← indexed markdown and URLs
    faq.md
    urls.yaml
  skills/          ← skills loaded as needed
    research.md
  simulations/
  agent.yaml       ← config for the agent
  routing.yaml     ← routing
  instructions.md  ← system prompt
  guardrail.md     ← prevent abuse

After you create an agent you can quickly test it

getstream agents test my-agent

Note that you can also configure agents through the SDKs or dashboard.

Client Side/ Browser & App

You can create a session for persistence. After the session is created, you can uses responses.create across all supported LLMs.

import { Client } from "@stream-io/stream-agents";

const api = new Client({ apiKey: "your_api_key" });
await api.setUser("jlahey", userToken); // a token your backend minted for this user

const session = await api.agent("support").sessions.create();
await session.responses.create("Do I have any open support cases?");

for await (const event of session.events()) {
  if (event.kind === "response_delta") console.log(event.text);
  if (event.kind === "responded") break;
}

Also note how the agent is referenced by use case. IE "support" and not the name of the model. The design here is that it should be trivial to switch from a frontier model to open or your own.

Full apps with chat, voice and tools, one per client SDK:

Tool Calling

Any backend SDK can provide tools to the agent. Tools are registered once for the app, and each agent's agent.yaml names the ones it uses in a tool group. Here's a Python based example:

import asyncio

from vision_agents.core.llm import ToolCallContext
from vision_agents.plugins import stream

client = stream.Client()


@client.tools.register()
async def customer_case_lookup(tool_call_context: ToolCallContext) -> list:
    """Look up the user's open support cases."""
    user = tool_call_context.user
    if not user.id:
        raise ValueError("unknown user")
    # pretend this calls your CRM
    return await crm.open_cases(user.id)


asyncio.run(client.run_dispatch())

Examples / What can you build

Stream's ask AI feature runs on this framework. It uses knowledge, skills, connectors and sandbox. The sandbox allows it to answer questions about the SDKs code. It replaces Inkeep and Zendesk for us:

https://github.com/user-attachments/assets/c931c5ff-f7fc-4f72-8b18-89f181ddb08a

Nora is our moderation support agent. Simple LLM, decision models and traditional classifier models spot abuse. Nora then reviews the context of a user's profile, past abuse etc to make a moderation decision.

  • Public and more advanced demos/tutorials coming soon

Simple Examples

Features included

Simulations & Monitoring

Agent simulations and monitoring are built-in.

Simulations play scripted callers against your agent so you can catch regressions before you ship.

https://github.com/user-attachments/assets/8b294cc6-e7cf-45c0-a2c9-122d91e131b5

Cost Transparency

It's very easy for AI costs to spiral out of control. We aim to give you the tools you need to keep costs under control

  • It's extremely easy to switch model
  • Session monitoring shows you stats about token usage. So you can optimize tools/skills etc to reduce token usage
  • Aggregated stats show token usage for skills, tools across all your tools
  • Tags allow you to track specific customers, products etc
  • Spending limits

Set daily, weekly and monthly spend limits in USD on the organization, API keys, users, apps and teams. See spend limits.

https://github.com/user-attachments/assets/7f4a028b-7cf3-4194-a894-fdbb72aa2109

Connectors

Connectors give an agent a provider's tools, or let people talk to it on a messaging channel. Add one in agent.yaml or the dashboard, with no code. Any other MCP server can be added as a custom connector. See the connectors docs.

  • Messaging channels: Slack bot, WhatsApp, SMS (Telnyx), iMessage (Linq)
  • Communication: Slack, Gmail
  • Documents: Notion, Google Docs, Google Drive
  • Scheduling: Google Calendar, Calendly, Cal.com
  • Project management and engineering: Linear, GitHub, Sentry
  • Customers and revenue: Salesforce, HubSpot, Gong
  • Commerce: Shopify, Instacart
  • Analytics: BigQuery, Metabase

Benchmarks (coming soon)

  • Agent development speed
  • Edge performance
  • Agent concurrency
  • Voice benchmark

Alternatives

How Stream Agents compares to the alternatives, see Stream vs alternatives:

  • OpenAI or Anthropic directly
  • Agent frameworks: Eve, AI SDK, LangChain
  • Routers: OpenRouter, Bifrost, LiteLLM
  • Voice AI frameworks: LiveKit, Pipecat, Retell, Agora, Vapi
  • Support SaaS: Sierra, Decagon, Serval

Free tier

You can run it yourself, or use the hosted version. Its free tier has generous limits:

  • $25 of inference and other costs included
  • 50k agent hosting minutes / month
  • 150k AI infra text messages
  • 500 concurrent agents
  • 10k monthly active agent users
  • 1M API calls
  • 1M records storage
  • Custom voices
  • Team collaboration

Past those limits, usage costs:

What Price
AI voice infra $0.002 / min
AI infra text $0.0001 / message
Audio RTC $0.30 / 1k participant min
SD video RTC $0.75 / 1k participant min
Stored records $1.50 / 1M after first 1M
Bandwidth $0.10 / GB
Tokens, telephony, knowledge, search & other forwarded costs cost + 5% + payment fees

See agent pricing.

探索相关项目

加载中…