Semantic Kernel — Microsoft AI Agent Framework
Semantic Kernel is Microsoft enterprise AI agent framework for Python, .NET, and Java. 27.6K+ GitHub stars. Multi-model, multi-agent, vector DB integration. MIT.
What it is
Semantic Kernel is Microsoft's open-source AI agent framework that provides a lightweight SDK for integrating LLMs into Python, .NET, and Java applications. It uses a plugin architecture where AI capabilities (called 'skills') are composed with traditional code functions. Semantic Kernel supports multiple AI models, multi-agent orchestration, and vector database integration.
Semantic Kernel is for enterprise developers building AI-powered applications on the Microsoft stack, as well as teams that need a framework supporting multiple programming languages and model providers.
The project is actively maintained with regular releases and a growing user community. Documentation covers common use cases, and the open-source nature means you can inspect the source code, contribute fixes, and adapt the tool to your specific requirements.
How it saves time or tokens
Semantic Kernel abstracts the differences between OpenAI, Azure OpenAI, Hugging Face, and other model providers behind a unified interface. You write your agent logic once and swap models without code changes. The planner component automatically breaks complex tasks into steps, reducing the prompt engineering needed to orchestrate multi-step workflows.
How to use
- Install the Semantic Kernel SDK for your language (pip, NuGet, or Maven).
- Configure a kernel instance with your AI model provider and API keys.
- Register plugins (functions) and invoke them through the kernel's planner or direct function calling.
Example
import semantic_kernel as sk
from semantic_kernel.connectors.ai.open_ai import OpenAIChatCompletion
kernel = sk.Kernel()
kernel.add_service(OpenAIChatCompletion(
service_id='chat',
ai_model_id='gpt-4',
api_key='your-key'
))
# Define a semantic function
summarize = kernel.add_function(
plugin_name='text',
function_name='summarize',
prompt='Summarize this text in 2 sentences: {{$input}}'
)
result = await kernel.invoke(summarize, input='Long document text here...')
print(result)
Related on TokRepo
- AI Tools for Agents -- Agent frameworks and orchestration tools
- Multi-Agent Frameworks -- Compare multi-agent approaches
Common pitfalls
- The Python and .NET SDKs have different API surfaces. Code examples from one language do not translate directly to another.
- The automatic planner can produce unexpected step sequences. For production use, define explicit function chains instead of relying on the planner for critical workflows.
- Vector store connectors require separate packages. The base SDK does not include database drivers for Pinecone, Weaviate, or Qdrant.
Before adopting this tool, evaluate whether it fits your team's existing workflow. Read the official documentation thoroughly, and start with a small proof-of-concept rather than a full migration. Community forums, GitHub issues, and Stack Overflow are valuable resources when you encounter edge cases not covered in the documentation.
Frequently Asked Questions
Semantic Kernel provides SDKs for Python, .NET (C#), and Java. The Python and .NET versions are the most mature, with Java support being newer. All three share the same plugin architecture and concepts.
Semantic Kernel is designed for enterprise environments with strong .NET support and Microsoft ecosystem integration. LangChain is Python-first with a larger community plugin ecosystem. Semantic Kernel uses a plugin/skill model; LangChain uses chains and tools.
Yes. Semantic Kernel has first-class support for Azure OpenAI Service. You can configure Azure-specific endpoints, deployments, and API versions directly in the kernel configuration.
A plugin is a collection of functions that the kernel can invoke. Functions can be semantic (LLM-powered with a prompt template) or native (regular code). Plugins are the primary unit of composition in Semantic Kernel.
Yes. Semantic Kernel is used in production at Microsoft and by enterprise customers. It is MIT-licensed, actively maintained, and follows semantic versioning for API stability.
Citations (3)
- Semantic Kernel GitHub— Semantic Kernel is Microsoft's AI agent framework
- Semantic Kernel Documentation— Plugin architecture for composing AI and native functions
- Semantic Kernel AI Connectors— Supports OpenAI, Azure OpenAI, and Hugging Face models
Related on TokRepo
Source & Thanks
Created by Microsoft. Licensed under MIT. microsoft/semantic-kernel — 27,600+ GitHub stars
Discussion
Related Assets
Claude-Flow — Multi-Agent Orchestration for Claude Code
Layers swarm and hive-mind multi-agent orchestration on top of Claude Code with 64 specialized agents, SQLite memory, and parallel execution.
ccusage — Real-Time Token Cost Tracker for Claude Code
CLI that reads ~/.claude logs and breaks down Claude Code token spend by day, session, and project — pluggable into your statusline.
SuperClaude — Workflow Framework for Claude Code
Adds 16+ slash commands, 9 cognitive personas, and a smart flag system to Claude Code in one pipx install.