@aigne/core is the foundation component of AIGNE Framework, providing the essential modules and tools needed to build AI-driven applications. This package implements the core functionalities of the framework, including agent systems, aigne environment, model integrations, and workflow pattern support.
Features
Multiple AI Model Support: Built-in support for OpenAI, Gemini, Claude, Nova, and other mainstream AI models, easily extensible to support additional models
Agent System: Powerful agent abstractions supporting AI agents, function agents, MCP agents, and more
AIGNE Environment: Flexible handling communication between agents and workflow execution
Workflow Patterns: Support for sequential, concurrent, routing, handoff, and other workflow patterns
MCP Protocol Integration: Seamless integration with external systems through the Model Context Protocol
TypeScript Support: Comprehensive type definitions providing an excellent development experience
Installation
Using npm
npm install @aigne/core
Using yarn
yarn add @aigne/core
Using pnpm
pnpm add @aigne/core
Basic Usage
import { AIAgent, AIGNE } from"@aigne/core";
import { OpenAIChatModel } from"@aigne/core/models/openai-chat-model.js";
// Create AI model instanceconst model = newOpenAIChatModel({
apiKey: process.env.OPENAI_API_KEY,
model: process.env.DEFAULT_CHAT_MODEL || "gpt-4-turbo",
});
// Create AI agentconst agent = AIAgent.from({
name: "Assistant",
instructions: "You are a helpful assistant.",
});
// AIGNE: Main execution engine of AIGNE Framework.const aigne = newAIGNE({ model });
// Use the AIGNE to invoke the agentconst userAgent = await aigne.invoke(agent);
// Send a message to the agentconst response = await userAgent.invoke(
"Hello, can you help me write a short article?",
);
console.log(response);
License
Elastic-2.0
FAQs
The functional core of agentic AI
We found that @aigne/core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.It has 2 open source maintainers collaborating on the project.
Package last updated on 12 Dec 2025
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Socket Firewall Free is now bundled into Docker Hardened Images, adding build-time and dependency-install supply chain protection on top of hardened base images for Node.js, Python, and Rust.
Impostor NuGet package Tracer.Fody.NLog typosquats Tracer.Fody and its author, using homoglyph tricks, and exfiltrates Stratis wallet JSON/passwords to a Russian IP address.