Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/yaalalabs/agent-kernel/ak-dev-new-framework-integrationnpx skills add yaalalabs/agent-kernel --skill ak-dev-new-framework-integrationgit clone --depth 1 https://github.com/yaalalabs/agent-kernelWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/yaalalabs/agent-kernel/ak-dev-new-framework-integration)<a href="https://agentmods.dev/skills/yaalalabs/agent-kernel/ak-dev-new-framework-integration"><img src="https://agentmods.dev/badge/skills/yaalalabs/agent-kernel/ak-dev-new-framework-integration.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00084 | $0.04459 |
| Opus 5 | $0.00042 | $0.02230 |
| Sonnet 5 | $0.00017 | $0.00892 |
| Haiku 4.5 | $0.00008 | $0.00446 |
Grade A, and why
ak-dev-new-framework-integration scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 428 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Adding a New Framework Integration
This guide walks through adding support for a new agent framework to Agent Kernel. Use the existing OpenAI adapter (ak-py/src/agentkernel/framework/openai/) as the canonical reference implementation.
Prerequisites
- Understand the architecture skill (
.agents/skills/ak-dev-architecture/SKILL.md) - Familiarity with the target framework's API
- The target framework must support async execution (or provide an async wrapper)
Step-by-Step
1. Create the Framework Adapter Directory
ak-py/src/agentkernel/framework/<name>/
├── __init__.py
└── <name>.py
Replace <name> with the framework's lowercase identifier (e.g., openai, langgraph).
2. Implement the Session State Class (if needed)
If the framework requires per-session state (e.g., conversation history), create a session data class:
class <Name>Session:
"""Stores framework-specific session data."""
def __init__(self):
self._history = [] # or whatever state the framework needs
def get_history(self):
return self._history
def add_to_history(self, item):
self._history.append(item)
def clear_session(self):
self._history.clear()
The session data is stored in the Agent Kernel Session via session.set("<name>", <Name>Session()) and retrieved via session.get("<name>"). This key must be the same string passed as your Runner's name (see Step 3) — hook authors reach it via Session.get_framework_session(), which resolves Agent.current().runner.name under the hood.
3. Implement the Runner
Subclass Runner from agentkernel.core.base:
from agentkernel.core.base import Runner, Session
from agentkernel.core.model import AgentReply, AgentReplyText, AgentRequest, AgentRequestText
from agentkernel.core.tool import ToolContext
FRAMEWORK = "<name>"
class <Name>Runner(Runner):
def __init__(self):
# must match the session key below — Session.get_framework_session() resolves it
# via Agent.current().runner.name
super().__init__(FRAMEWORK)
def _session(self, session: Session) -> <Name>Session:
"""Get or create framework-specific session data."""
data = session.get(FRAMEWORK)
if data is None:
data = <Name>Session()
session.set(FRAMEWORK, data)
return data
async def run(self, agent, session: Session, requests: list[AgentRequest]) -> AgentReply:
# 1. Create ToolContext for tool functions to access
tool_context = ToolContext(
runtime=Runtime.current(),
agent=agent,
session=session,
requests=requests
)
with tool_context:
tool_context.set()
try:
# 2. Get framework-specific session state
fw_session = self._session(session)
# 3. Convert AgentRequest models to framework-native format
# e.g., extract text from AgentRequestText
prompt = ""
for req in requests:
if isinstance(req, AgentRequestText):
prompt = req.prompt
# 4. Call the framework's execution API
result = await self._execute(agent, fw_session, prompt) # framework-specific
# 5. Update session state
fw_session.add_to_history({"input": prompt, "output": result})
# 6. Return as AgentReply
return AgentReplyText(response=str(result), prompt=prompt)
finally:
tool_context.reset()
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 428 lines · 84 tokens per session scan A 822705a7994b
ak-dev-new-framework-integration is a skill published in the GitHub repository yaalalabs/agent-kernel (166 stars, last pushed today), licensed Apache-2.0. It adds 84 tokens to every session and 4,459 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
notion
Notion workspace integration for searching pages, managing databases, creating postmortems, and exporting RCA findings.
datadog
Datadog monitoring integration for querying logs, metrics, monitors, events, traces, hosts, and incidents during RCA investigations.
scaleway
Scaleway cloud integration for managing instances, Kapsule Kubernetes clusters, object storage, and managed databases via CLI and Terraform.
bitbucket
Bitbucket code repository integration for managing repos, branches, PRs, issues, and CI/CD pipelines.
cloudbees
CloudBees CI integration for investigating builds, deployments, pipeline stages, and test results during RCA.
cloudflare
Cloudflare integration for DNS, CDN, WAF, edge diagnostics, and remediation with zone management, analytics, security events, and cache control.