Releases: VoltAgent/voltagent
@voltagent/supabase@0.1.2
@voltagent/google-ai@0.2.0
Minor Changes
-
#29
82e27c2Thanks @foxy17! - feat(google-ai): Add initial Google AI provider package - #12Introduces the
@voltagent/google-aipackage to integrate Google's Generative AI capabilities directly into VoltAgent. This allows developers to leverage powerful models like Gemini within their agents.This initial version includes:
- The core
GoogleGenAIProviderclass for interfacing with the@google/genaiSDK. - Configuration options for API key authentication.
- Basic setup and usage examples in the README.
- Documentation outlining future support and considerations for Vertex AI.
- The core
Patch Changes
@voltagent/core@0.1.7
Patch Changes
e328613Thanks @omeraplak! - fix: preventReferenceError: module is not definedin ES module environments by adding guards around the CommonJS-specificrequire.main === modulecheck in the main entry point.
@voltagent/core@0.1.6
Patch Changes
-
#41
52d5fa9Thanks @omeraplak! - ## Introducing Toolkits for Better Tool ManagementManaging related tools and their instructions is now simpler with
Toolkits.Motivation:
- Defining shared instructions for multiple related tools was cumbersome.
- The logic for deciding which instructions to add to the agent's system prompt could become complex.
- We wanted a cleaner way to group tools logically.
What's New: The
ToolkitA
Toolkitbundles related tools and allows defining sharedinstructionsand anaddInstructionsflag at the toolkit level.// packages/core/src/tool/toolkit.ts export type Toolkit = { /** * Unique identifier name for the toolkit. */ name: string; /** * A brief description of what the toolkit does. Optional. */ description?: string; /** * Shared instructions for the LLM on how to use the tools within this toolkit. * Optional. */ instructions?: string; /** * Whether to automatically add the toolkit's `instructions` to the agent's system prompt. * Defaults to false. */ addInstructions?: boolean; /** * An array of Tool instances that belong to this toolkit. */ tools: Tool<any>[]; };
Key Changes to Core:
ToolManagerUpgrade: Now manages bothToolandToolkitobjects.AgentOptionsUpdate: Thetoolsoption accepts(Tool<any> | Toolkit)[].- Simplified Instruction Handling:
Agentnow only adds instructions fromToolkits whereaddInstructionsis true.
This change leads to a clearer separation of concerns, simplifies the agent's internal logic, and makes managing tool instructions more predictable and powerful.
New
createToolkitHelperWe've also added a helper function,
createToolkit, to simplify the creation of toolkits. It provides default values and basic validation:// packages/core/src/tool/toolkit.ts export const createToolkit = (options: Toolkit): Toolkit => { if (!options.name) { throw new Error("Toolkit name is required"); } if (!options.tools || options.tools.length === 0) { console.warn(`Toolkit '${options.name}' created without any tools.`); } return { name: options.name, description: options.description || "", // Default empty description instructions: options.instructions, addInstructions: options.addInstructions || false, // Default to false tools: options.tools || [], // Default to empty array }; };
Example Usage:
import { createTool, createToolkit } from "@voltagent/core"; import { z } from "zod"; // Define some tools first const getWeather = createTool({ name: "getWeather", description: "Gets the weather for a location.", schema: z.object({ location: z.string() }), run: async ({ location }) => ({ temperature: "25C", condition: "Sunny" }), }); const searchWeb = createTool({ name: "searchWeb", description: "Searches the web for a query.", schema: z.object({ query: z.string() }), run: async ({ query }) => ({ results: ["Result 1", "Result 2"] }), }); // Create a toolkit using the helper const webInfoToolkit = createToolkit({ name: "web_information", description: "Tools for getting information from the web.", instructions: "Use these tools to find current information online.", addInstructions: true, // Add the instructions to the system prompt tools: [getWeather, searchWeb], }); console.log(webInfoToolkit); /* Output: { name: 'web_information', description: 'Tools for getting information from the web.', instructions: 'Use these tools to find current information online.', addInstructions: true, tools: [ [Object Tool: getWeather], [Object Tool: searchWeb] ] } */
-
#33
3ef2eaaThanks @kwaa! - Update package.json files:- Remove
srcdirectory from thefilesarray. - Add explicit
exportsfield for better module resolution.
- Remove
-
#41
52d5fa9Thanks @omeraplak! - ## Introducing Reasoning Tools HelperThis update introduces a new helper function,
createReasoningTools, to easily add step-by-step reasoning capabilities to your agents. #24New
createReasoningToolsHelperFeature: Easily add
thinkandanalyzetools for step-by-step reasoning.We've added a new helper function,
createReasoningTools, which makes it trivial to equip your agents with structured thinking capabilities, similar to patterns seen in advanced AI systems.- What it does: Returns a pre-configured
Toolkitnamedreasoning_tools. - Tools included: Contains the
thinktool (for internal monologue/planning) and theanalyzetool (for evaluating results and deciding next steps). - Instructions: Includes detailed instructions explaining how the agent should use these tools iteratively to solve problems. You can choose whether these instructions are automatically added to the system prompt via the
addInstructionsoption.
import { createReasoningTools, type Toolkit } from "@voltagent/core"; // Get the reasoning toolkit (with instructions included in the system prompt) const reasoningToolkit: Toolkit = createReasoningTools({ addInstructions: true }); // Get the toolkit without automatically adding instructions const reasoningToolkitManual: Toolkit = createReasoningTools({ addInstructions: false });
How to Use Reasoning Tools
Pass the
Toolkitobject returned bycreateReasoningToolsdirectly to the agent'stoolsarray.// Example: Using the new reasoning tools helper import { Agent, createReasoningTools, type Toolkit } from "@voltagent/core"; import { VercelAIProvider } from "@voltagent/vercel-ai"; import { openai } from "@ai-sdk/openai"; const reasoningToolkit: Toolkit = createReasoningTools({ addInstructions: true, }); const agent = new Agent({ name: "MyThinkingAgent", description: "An agent equipped with reasoning tools.", llm: new VercelAIProvider(), model: openai("gpt-4o-mini"), tools: [reasoningToolkit], // Pass the toolkit }); // Agent's system message will include reasoning instructions.
This change simplifies adding reasoning capabilities to your agents.
- What it does: Returns a pre-configured
@voltagent/cli@0.1.3
@voltagent/core@0.1.5
Patch Changes
-
#35
9acbbb8Thanks @omeraplak! - fix: Prevent potential error when accessing debug option in LibSQLStorage - #34- Modified the
debugmethod within theLibSQLStorageclass. - Changed the access to
this.options.debugto use optional chaining (this.options?.debug).
This change prevents runtime errors that could occur in specific environments, such as Next.js, if the
debugmethod is invoked before theoptionsobject is fully initialized or ifoptionsbecomes unexpectedlynullorundefined. It ensures the debug logging mechanism is more robust. - Modified the
@voltagent/core@0.1.4
Patch Changes
-
#27
3c0829dThanks @omeraplak! - fix: improve sub-agent context sharing for sequential task execution - #30Enhanced the Agent system to properly handle context sharing between sub-agents, enabling reliable sequential task execution. The changes include:
- Adding
contextMessagesparameter togetSystemMessagemethod - Refactoring
prepareAgentsMemoryto properly format conversation history - Ensuring conversation context is correctly passed between delegated tasks
- Enhancing system prompts to better handle sequential workflows
This fixes issues where the second agent in a sequence would not have access to the first agent's output, causing failures in multi-step workflows.
- Adding
@voltagent/supabase@0.1.1
Patch Changes
-
#21
8c3506eThanks @omeraplak! - feat: Introduce Supabase Memory Provider (@voltagent/supabase)This new package provides a persistent memory solution for VoltAgent using Supabase.
Features:
- Stores conversation history, agent history entries, events, and steps in your Supabase database.
- Requires specific table setup in your Supabase project (SQL provided in the package README).
- Easy integration by initializing
SupabaseMemorywith your Supabase URL and key and passing it to yourAgentconfiguration.
See the
@voltagent/supabaseREADME and Documentation for detailed setup and usage instructions.closes #8