Dev & Engineering golangmultimodalworkflow-orchestrationstructured-outputconversation-memorymiddleware

Blades

A Go framework for composing multimodal agents from models, tools, memory, middleware, and workflows.

FollowAgents review · FARS-2.0
Not yet reviewed
See the full review method →

What does this agent do, and when should you use it?

Blades is a multimodal AI Agent framework for Go, not a separately hosted chat application. Its common Agent execution contract is Run(context.Context, *Invocation), which returns Generator[*Message, error], and Agent, Chain, and ModelProvider can be composed around that model. The framework exposes pluggable ModelProvider, Tool, Memory, and Middleware components, while flow coordinates multi-step reasoning and transfers data and control between Agents. Model output can be collected in full with Generate or consumed incrementally through NewStreaming; the supplied example runs an OpenAI-backed agent through Runner in application code. It fits teams building agent behavior inside Go services, but the README does not document a standalone deployment, CLI, or installation command.

An application creates a ModelProvider, such as openai.NewModel("gpt-5", openai.Config{APIKey: os.Getenv("OPENAI_API_KEY")}), then creates an agent with blades.NewAgent plus WithModel and WithInstruction. The caller builds a blades.UserMessage, invokes blades.NewRunner(agent).Run(context.Background(), input), and reads Text() from the returned message. For extensions, Tool uses InputSchema and Handle to represent callable external capabilities; Memory saves and searches messages by session; Middleware adds behavior around Runner execution. Skills can be loaded with skills.NewFromDir("./skills") or skills.NewFromEmbed(embed.FS) and passed through WithSkills(...).

  1. A Go backend team embedding an OpenAI-backed, multi-turn question-answering agent in an existing service.
  2. A developer connecting several Agents or Chains into a multi-step reasoning workflow in a Go application.
  3. A team exposing database queries or API calls as model-callable functions with an InputSchema for invocation parameters.
  4. An application that needs session-scoped conversation memory so later turns can retain context.
  5. An engineering team adding logging, monitoring, authentication, or rate limiting around agent execution without changing Runner core logic.

What are this agent's strengths and limitations?

Pros
  • A shared Agent interface and Generator-based output model connect Agent, Chain, and ModelProvider as composable execution units.
  • The ModelProvider abstraction is explicitly pluggable, with OpenAI, DeepSeek, and Gemini named as services it can integrate.
  • It combines tools, session memory, streaming generation, and middleware for Go applications that need agent capabilities.
  • Skills can be loaded from a directory or packaged into the binary with embed.FS.
Limitations
  • The README lacks installation commands, a Go version, module-version guidance, and a standalone deployment path, leaving initial project setup to adopters.
  • The OpenAI example requires network access and OPENAI_API_KEY; cost and availability depend on the chosen model provider.
  • Persistent and more advanced memory strategies are left to extensions; the README explicitly identifies only an InMemory implementation.
  • No CLI, HTTP service surface, or production operations configuration is shown, so adopters must define the application boundary themselves.

How do you install or deploy this agent?

The README does not provide a copyable installation command, a required Go version, or module setup instructions, so an exact dependency-installation procedure is undocumented. The explicit prerequisites are a Go environment and, for the OpenAI example, OPENAI_API_KEY; the application must also be able to import github.com/go-kratos/blades and github.com/go-kratos/blades/contrib/openai.

How do you use this agent?

In a Go program, read OPENAI_API_KEY and create openai.NewModel("gpt-5", openai.Config{APIKey: os.Getenv("OPENAI_API_KEY")}). Create an agent with blades.NewAgent("Blades Agent", blades.WithModel(model), blades.WithInstruction("You are a helpful assistant that provides detailed and accurate information.")). Build input with blades.UserMessage("What is the capital of France?"), then run runner := blades.NewRunner(agent) followed by runner.Run(context.Background(), input). After checking err, call output.Text() to obtain the text response.

FAQ

Can I deploy it directly as a chat service?
The README presents it as a Go framework and shows Agent and Runner created in a Go program; it does not provide a standalone chat-service deployment or command.
Is it limited to OpenAI?
No. ModelProvider is presented as a pluggable interface, and the README names OpenAI, DeepSeek, and Gemini as model services that can be integrated, although application code supplies the integration.
What credential does the OpenAI example require?
The example reads its API key from the OPENAI_API_KEY environment variable.
How is conversation context retained?
The Memory interface stores and retrieves messages and supports session management. The README identifies an InMemory implementation; persistent storage must be extended by the adopter.

Related agents