惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

宝玉的分享
宝玉的分享
T
Threat Research - Cisco Blogs
H
Hacker News: Front Page
N
News and Events Feed by Topic
Know Your Adversary
Know Your Adversary
Cisco Talos Blog
Cisco Talos Blog
SecWiki News
SecWiki News
C
Cisco Blogs
D
Darknet – Hacking Tools, Hacker News & Cyber Security
T
Tor Project blog
K
Kaspersky official blog
Forbes - Security
Forbes - Security
Webroot Blog
Webroot Blog
Schneier on Security
Schneier on Security
P
Privacy & Cybersecurity Law Blog
H
Heimdal Security Blog
Y
Y Combinator Blog
The GitHub Blog
The GitHub Blog
S
SegmentFault 最新的问题
V
Vulnerabilities – Threatpost
T
Tenable Blog
T
Tailwind CSS Blog
P
Privacy International News Feed
WordPress大学
WordPress大学
大猫的无限游戏
大猫的无限游戏
小众软件
小众软件
博客园 - Franky
Hacker News: Ask HN
Hacker News: Ask HN
Jina AI
Jina AI
C
Cybersecurity and Infrastructure Security Agency CISA
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
雷峰网
雷峰网
Vercel News
Vercel News
A
About on SuperTechFans
爱范儿
爱范儿
Simon Willison's Weblog
Simon Willison's Weblog
AWS News Blog
AWS News Blog
The Last Watchdog
The Last Watchdog
Engineering at Meta
Engineering at Meta
Spread Privacy
Spread Privacy
Security Archives - TechRepublic
Security Archives - TechRepublic
博客园 - 司徒正美
量子位
博客园 - 三生石上(FineUI控件)
J
Java Code Geeks
Hacker News - Newest:
Hacker News - Newest: "LLM"
Recorded Future
Recorded Future
H
Hackread – Cybersecurity News, Data Breaches, AI and More
Martin Fowler
Martin Fowler
Project Zero
Project Zero

Hacker News - Newest: "AI"

AI can't read an investor deck AI as an attorney? Student uses ChatGPT, Gemini to sue UW over alleged racial discrimination Hacking MCP Servers in AI Systems – The Rug Pull: Tool Changes After Approval GitHub - MeepCastana/KubeezCut: Free Web based video editor GitHub - GenAI-Gurus/awesome-eu-ai-act: Curated tools, official sources, OSS, templates, and guides for EU AI Act compliance. Can AI judge journalism? A Thiel-backed startup says yes, even if it risks chilling whistleblowers Coming soon: 10 Things That Matter in AI Right Now DARPA built an AI to fact-check enemy weapons claims What explains heterogeneity in AI adoption? When AI Meets Muscle: Context-Aware Electrical Stimulation Promises a New Way to Guide Human Movements - Department of Computer Science AI Changed How We Build. It Did Not Change What Matters. Linux rules on using AI-generated code - Copilot is OK, but humans must take 'full responsibility for the… Meta spins up AI version of Mark Zuckerberg to engage with employees Code Mode: Let Your AI Write Programs, Not Just Call Tools | TanStack Blog GitHub - Delavalom/graft: Go framework for building AI agents. Type-safe tools, multi-provider (OpenAI, Anthropic, Gemini, Bedrock), zero vendor SDKs. India's TCS tops estimates, says new AI models did not dent services demand Gen Z's fading AI hype Strong feeling: we are in a folded AI reality GitHub - machinarii/total-recall-catalog: A reference catalog of latest knowledge retrieval, memory & RAG systems GitHub - mensfeld/code-on-incus: Give each AI agent its own isolated machine with root, Docker, and systemd. Active defense detects and stops threats automatically.. Quantization, LoRA, and the 8% Problem: Benchmarking Local LLMs for Production AI Iran war: We spoke to the man making Lego-style AI videos that experts say are powerful propaganda Powell, Bessent discussed Anthropic's Mythos AI cyber threat with major U.S. banks GitHub - immartian/bellamem: Persistent belief-graph memory for AI agents. Retrieves decisive context by importance — not recency, not RAG, not /compact. recursive-mode: The Repo-Native Operating System for AI Engineering After the attack on Sam Altman's home, will AI CEO's go on the offensive? The biggest advance in AI since the LLM Opus 4.6 vs GPT 5.4 One Prompt Unity World Generation Test “AI polls” are fake polls Client Challenge Can AI be a 'child of God'? Inside Anthropic's meeting with Christian leaders How to Switch AI Chatbots and Why You Might Want To GitHub - MattMessinger1/agentic_refund_guardrail: Safe refund policy layer for AI agents — Python + TypeScript. Same behavior, shared tests. Adam/papers/emergent_values_whitepaper.md at master · strangeadvancedmarketing/Adam Ask HN: How do you stop playing 20 questions with your AI coding tools How far can automation and AI support psychotherapy? - @theU GitHub - stagas/rtdiff: realtime git diff gui and AI-assisted commits A Mac Studio for Local AI — 6 Months Later A History of the Early Years of AI at the University of Edinburgh Why AI Coding Tools Still Feel Stuck on Localhost MSN AI Datacenters Are Becoming Strategic Targets twitter.com Penn Researchers Use AI to Surface Unreported GLP-1 Side Effects in Reddit Posts Show HN: MoodSense AI (ML and FastAPI and Gradio, Deployed on Hugging Face) Moodsense Ai - a Hugging Face Space by aman179102 AI models are terrible at betting on soccer—especially xAI Grok GitHub - xialeistudio/echoic GitHub - HimashaHerath/github-dev-wrapped: AI-powered weekly GitHub activity reports deployed to GitHub Pages GitHub - alejandrobalderas/claude-code-from-source: Architecture, patterns & internals of Anthropic's AI coding agent — reverse-engineered from source maps AI and Tech brief: Ireland ascendant GitHub - Titovilal/context0: Context0 - Never Surrender Training for a Marathon with an AI Coach: What Worked and What Didn't Cyber Pulse: Agentic Intel - Apps on Google Play I Built an AI PR Reviewer That Catches Bugs by Not Looking for Bugs Gen Z workers are so fearful AI will take their job they’re intentionally sabotaging their company’s AI rollout | Fortune How AI Is Reimagining the Game of Golf–For Both Players and Courses GitHub - nattergabriel/reseed: A CLI tool for managing and distributing agent skills across projects Is SVG the final frontier? My AI workflow evolved from prompts to a near-autonomous workflow MLSharp Help - 3DGS Viewer & Generator I put my cognitive field based AI's runtime on GitHub Is Numble the first AI-proof game? A3: Kubernetes for autonomous AI agent fleets | Emergent Principles Deepali Vyas ("The Elite Recruiter") GitHub - msmarkgu/RelayFreeLLM: A restful API designed to route user prompts to various AI model providers. Unionized ProPublica staff are on strike over AI, layoffs, and wages Unleashing the Advantage of Quantum AI We're heading for an AI-fueled 'dementia crisis,' brain scientist warns The AI-Assisted Breach of Mexico's Government Infrastructure [pdf] GitHub - stef41/lmscan: 🔍 Detect AI-generated text and fingerprint which LLM wrote it. Open-source GPTZero alternative. Zero dependencies, works offline. MSN GitHub - visionscaper/collabmem: Enabling long-term collaboration with Agentic AI - building up episodic and world model memory over time with in-context awareness We gave an AI a 3 year retail lease in SF and asked it to make a profit | Andon Labs AI Code is Hollowing Out Open Source, and Maintainers are Looking the Other Way What leaked "SteamGPT" files could mean for the PC gaming platform's use of AI AI is the boss at this retail store. What could go wrong? GitHub - Wuzu11517/agentic-proxy: Local proxy meant to help reduce With Drones, Geophysics and ArtificiaI Intelligence, Researchers Prepare to Do Battle Against Land Mines A Single Operator, Two AI Platforms, Nine Government Agencies: The Full Technical Report 在 Steam 上购买 FriedrichAI: Offline AI 立省 10% GitHub - inevolin/resume-cli: Hit Claude usage limits? Resume any AI coding session elsewhere. Switch tools at zero friction. GitHub - atripati/ark: AI Runtime Kernel — a context operating system for AI agents. Eliminates tool bloat, loads only what’s needed, and gives LLMs their reasoning space back. How to Build a Secure AI PR Reviewer with Claude, GitHub Actions, and JavaScript This Startup Wants You to Pay Up to Talk With AI Versions of Human Experts Intel Arc Pro B70 Brings 32GB VRAM to Local AI for $949 WordPress 7.0: The Good, the AI, and the Still Missing AI on the couch: Anthropic gives Claude 20 hours of psychiatry IatroBench: Pre-Registered Evidence of Iatrogenic Harm from AI Safety Measures AI Agents Know About Supabase. They Don't Always Use It Right. The history and future of AI at Google, with Sundar Pichai Inside an AI‑enabled device code phishing campaign How Meta Used AI to Map Tribal Knowledge in Large-Scale Data Pipelines AI for Systems: Using LLMs to Optimize Database Query Execution Forecasting the Economic Effects of AI Introducing Tinker: Play with AI, bring your ideas to life AI sheds light on an ancient gaming mystery People really hate AI but not as much as Iran—or Democrats | Fortune What is an AI Product Engineer? Phoebe Gates wants her $185 million AI startup to succeed with 'no ties to my privilege or my last name': 'I have a chip on my shoulder' | Fortune
Agent Capsule - A pattern for building production AI agents as document folders powered by coding-agent as runtimes
armagnac2 · 2026-04-28 · via Hacker News - Newest: "AI"

Agent Capsule - A pattern for building production AI agents as document folders powered by coding-agent as runtimes

A pattern for building production AI agents as documents, not agent code.

This document presents the core concept, offering a concise and accessible overview to guide implementation.

The Core Idea

Most production agents are built with an Agent SDK (OpenAI, LangChain, LangGraph, etc.). You write code for tool dispatch, memory, sub-agents, session state, and so on. Every new capability requires a code change and a deployment.

The idea here is different: use an existing coding-agent (like claude-code) as agent's runtime engine, and define the agent as a folder of documents. This folder of documents could be also prompted using a coding agent - making the process of agent building, practically prompting.

The runtime already knows how to read a project, load instructions, use tools, maintain memory, and stream output.

This changes the development cycle. Instead of writing more code for any change, you prompt the coding agent to update folder structure and agent's documents. Iterating and delivering significantly faster.

Example: Building an Exec Assistant Agent with a prompt

You are an executive assistant agent for busy managers and executives.

  1. Build CLAUDE.md system file.
  2. Prep timeblocks - Every week, retrieve all upcoming events for the next 3 weeks. For each event, analyze preparation needs and create dedicated "prep" time blocks on the calendar, well in advance of each event. Ensure all context is available on the calendar event.
  3. As you perform these actions, update agent documentation and memories to reflect the evolving needs and preferences of the executive. Use knowledge folder for it. Build any skills and scheduled tasks you need to accomplish the above.

Example directory tree for an agent built using the Capsule pattern:

agent-exec-assistant/
├── CLAUDE.md                # System prompt: identity, rules, behavior
├── skills/
│   ├── prioritize-tasks.md  # Skill: prioritization logic and heuristics
│   ├── calendar-sync.md     # Skill: calendar management and integration
├── knowledge/
│   ├── preferences.md       # Learned knowledge about the user/executive
│   └── org-policies.md      # Knowledge base entry for company policies
├── memory/
│   ├── recap-2024-06.md     # Memory—summarized learnings from June 2024
│   └── last-session.md      # State from the previous session
├── settings.json            # Tools, API credentials, permissions
└── version.json             # Versioning of the agent template

To transition from a local and personal agent to a production grade multi-user agent, we use an orchestration layer that:

  1. Takes a template agent folder
  2. Provisions isolated user workspaces
  3. Runs agent capsules to process inputs This solves important challenges: how do you run this for many users, keep their memories separate, update the shared agent, inject credentials, handle triggers, and capture output.

Architecture

The architecture has two layers:

  • Agent Layer - the files and state that define what the agent is.
  • Execution Layer - the infrastructure that runs the agent safely for one or many users.

Agent Layer

Template - the reusable agent folder. It contains the developer-controlled files: CLAUDE.md, skills, agents, tool configs, settings.json, and version.json.

Workspace - a persistent per-user or per-org folder created from the template. It contains the template files plus user preferences and agent memory. This is where state lives.

The workspace usually has three layers:

  • Layer 1: Template - shared, developer-controlled, versioned.
  • Layer 2: User/org preferences - validated customizations.
  • Layer 3: Agent memory - facts, summaries, entities, and learned context written by the runtime.

Capsule - an ephemeral secured runtime process spawned against one workspace. It reads the workspace, executes one prompt or session, writes memory back, returns output, and exits. The capsule is stateless. The workspace stores the state.

One template can be used to create many isolated workspaces:

                          EA Agent Template
                 ┌────────────────────────────────┐
                 │ ea-agent/                      │
                 │ ├─ CLAUDE.md                   │
                 │ ├─ skills/                     │
                 │ ├─ settings.json               │
                 │ └─ knowledge/                  │
                 └───────────────┬────────────────┘
                                 │
                      fork one workspace per user
                                 │
                 ┌───────────────┴────────────────┐
                 ▼                                ▼
      ┌───────────────────────────┐    ┌───────────────────────────┐
      │ Liran's EA Agent          │    │ Mike's EA Agent           │
      │ Workspace                 │    │ Workspace                 │
      │                           │    │                           │
      │ template-derived files:   │    │ template-derived files:   │
      │ - CLAUDE.md               │    │ - CLAUDE.md               │
      │ - skills/                 │    │ - skills/                 │
      │ - settings.json           │    │ - settings.json           │
      │                           │    │                           │
      │ user-specific state:      │    │ user-specific state:      │
      │ - knowledge/              │    │ - knowledge/              │
      │ - review preferences      │    │ - review preferences      │
      │ - learned repo context    │    │ - learned repo context    │
      └───────────────────────────┘    └───────────────────────────┘

Execution Layer

Runtime Engine - a coding agent responsible for the main mechanism - loading prompt, using skills, calling mcps, etc. Examples include Claude Code, OpenCode, and Pi.

Capsule Orchestrator - the infrastructure and tooling to manage templates, workspaces and agent capsules. This layer is also responsible to facilitate input and output channels between capsules to the user.

When input arrives, the orchestrator starts a capsule against the right workspace:

User Input / Webhook / Schedule
              │
              ▼
 ┌────────────────────────────┐
 │        Orchestrator        │
 └────────────────────────────┘
              │ spawn runtime_engine(input, workspace)
              ▼
 ┌──────────────────────────────────────┐
 │   Runtime Engine: claude-code        │
 │   Workspace:                         │
 │     Liran (template: pr-agent)       │
 │                                      │
 │   Execute with full context          │
 └──────────────────────────────────────┘
              │ generated response
              ▼
 ┌─────────────────────────────┐
 │        Orchestrator         │
 │  routes output to web/slack │
 └─────────────────────────────┘
              │
              │ agent's output (+streaming)
              ▼
         User / App

Operations

Create. Copy the template into a new workspace, initialize preferences, and create an empty memory area.

Run. Spawn a capsule for a one-shot prompt, webhook, or scheduled task and return output.

Connect. Open a resumable interactive session against a workspace.

Update. Ship a new template version by replacing Layer 1 while preserving preferences and memory. Breaking changes can run migrations.

Delete. Remove the workspace and revoke credentials.

The Orchestrator

To manage Workspaces at scale, you need a thin code layer (an Orchestrator) that sits between your product and the agent runtime. This infrastructure handles:

  • Provisioning & Workspace management - Creating Workspace directories from templates when users sign up.
  • Trigger handling - Receiving chat messages, scheduled events, or webhooks, and spawning the runtime process against the correct Workspace.
  • Scheduling - Owning the scheduler and firing scheduled skills or tasks against the correct Workspace at the right time.
  • Credential management - Storing OAuth tokens securely and injecting them as environment variables when spawning the runtime.
  • Output routing - Capturing the runtime's streaming stdout and delivering it to the right destination (Web UI, Slack, etc.), including streaming support.

Canopy is an open-source reference implementation of the Agent Capsule pattern. It includes the specs and a basic CLI for provisioning and running Workspaces; the broader orchestration layer is still being built.

Everything that requires intelligence lives in documents. Everything that requires traditional software engineering lives in the orchestration infrastructure.

Discussion & Security

The Agent Capsule pattern is a shift toward "Agent as Data." By treating an existing, highly capable coding agent (like Claude Code, OpenCode, or Pi) as a generic execution engine, the agent itself becomes just a directory of text files.

This approach leverages existing capabilities built into modern coding agents, which already handle substrate functions like context loading, following instructions, tool usage, MCP, file operations, streaming, and session management. The capsule pattern treats these as runtime features and shifts all product-specific behaviors into the document layer.

Robust security is essential for production use. Required controls include:

  • Workspace isolation — Each workspace must remain strictly separated.
  • Validated user and agent writes — Only authorized changes should be permitted at each layer.
  • Template immutability — The foundational (template) layer must not be alterable at runtime.
  • Secure credential management — Secrets and OAuth tokens should be safely stored and used.
  • Tool allowlisting — Only approved tools should be accessible by the agent.
  • Sandboxed execution — Any code or learned skills must run in a tightly controlled environment.

Additionally, each layer (template, user, agent memory) must be composed so that higher layers cannot override or weaken safety rules set by lower ones. All sensitive operations—such as invoking agent tools or modifying memory—should be narrowly scoped and fully auditable to minimize risk.

In summary: the capsule specifies what the agent is, while the orchestrator controls where and how the agent is permitted to run.