Agent-Native Calendar
Agent-Native Google Calendar - manage events, sync, and public booking
作者による説明(英語の原文)
Keep Claude Code and Codex off each other's files: hook-enforced path leases, presence, messages.
この3つを1つのスコアにまとめることはしません。意見、測定、人気はそれぞれ別のものだからです。
このサーバーのやさしい解説はまだ書いていません。以下はレジストリから読み取った事実です。
使っているAIアプリを選んで、設定をコピーしてください。
AGENT_NAME, AGENT_LEASE_DB必要なもの
どのアプリを使っていますか?
上でアプリを選んでください。選んだアプリを覚えておくので、次からはボタンに「…にインストール」と表示されます。
Claude Desktop → Settings → Developer → Edit Config を開き、claude_desktop_config.json にこれを貼り付けます
{
"mcpServers": {
"agent-lease": {
"command": "uvx",
"args": [
"agent-lease-mcp"
],
"env": {
"AGENT_NAME": "your-value",
"AGENT_LEASE_DB": "your-value"
}
}
}
}ターミナルでこれを実行します
claude mcp add agent-lease --env AGENT_NAME=your-value --env AGENT_LEASE_DB=your-value -- uvx agent-lease-mcp動かす前に、空欄の値を入力してください。
プロジェクトの .cursor/mcp.json、または ~/.cursor/mcp.json に貼り付けます
{
"mcpServers": {
"agent-lease": {
"command": "uvx",
"args": [
"agent-lease-mcp"
],
"env": {
"AGENT_NAME": "your-value",
"AGENT_LEASE_DB": "your-value"
}
}
}
}ブラウザがアプリを開いてよいか確認し、そのあとアプリが設定を表示して確認を求めます。キーの値は空欄のままなので、自分で入力してください。
プロジェクトの .vscode/mcp.json に貼り付けます
{
"servers": {
"agent-lease": {
"type": "stdio",
"command": "uvx",
"args": [
"agent-lease-mcp"
],
"env": {
"AGENT_NAME": "your-value",
"AGENT_LEASE_DB": "your-value"
}
}
}
}ブラウザがアプリを開いてよいか確認し、そのあとアプリが設定を表示して確認を求めます。キーの値は空欄のままなので、自分で入力してください。
これはパソコンで動くサーバーですが、ChatGPTがつなげるのはインターネット上のサーバーだけです。ほかのアプリを選んでください。
選んだアプリは、この端末のCookieに保存されます。アカウントは不要です。
AGENT_LEASE_DB envこの設定は、作者のレジストリ登録情報から作成しています。READMEと違う場合は、READMEに従ってください。
パソコンで動くサーバーです。インストールすると、ツール一覧がAIアプリに表示されます。
誰でも見られる情報をチェックしており、コードは読んでいません。当てはまらない項目は数に入れていません。 · 2026年11月7日にチェック
レジストリ名は、リポジトリを所有するGitHubアカウント Buggy1111 で確認済みです
このリポジトリはまだGitHubから読み取っていません
このリポジトリはまだGitHubから読み取っていません
これはパソコンで動くため、インターネット上のエンドポイントはありません
パソコンで動き、代わりにローカルの設定を使います
パソコンで動くサーバーです。ツール一覧を読み取れるのは、インターネット上のエンドポイントがある場合だけです
レジストリでこのカテゴリにある有効なすべてのサーバーと比較しています。スターは、公開者がリポジトリの所有者である場合だけ数えます。
当てはまる基本チェック1項目のうち1項目に合格しました。コードは読んでいません。キーやトークンを追加する前に、サーバーがどんなアクセスを求めているかを確認し、必要な権限だけを持つキーを使ってください。
入力が必要なもの:AGENT_NAME
あなたのパソコンで動きます。必要なときにAIアプリが起動し、データは作者のサーバーを通りません(サーバー自体がオンラインサービスを呼び出す場合を除きます)。
GitHubリポジトリの最終更新は–、最新バージョン(0.2.0)がレジストリに届いたのは22 日前です。
Claude Desktop、Claude Code、Cursor、VS CodeなどのMCP対応アプリで使えます。パソコンにPython (uv)も必要です。
同じカテゴリには:Agent-Native Calendar, Excel MCP Server, MCP Server for Excel
同じカテゴリで、ほかの作者が作ったサーバー。スターの多い順。
カードの見方:★ GitHubスターi3つの柱:レビュー · チェック · 利用状況i更新=最新バージョンをレジストリに公開した日i
Agent-Native Google Calendar - manage events, sync, and public booking
Create and edit Excel files with AI: charts, PivotTables, formulas. No Excel needed.
Excel automation for AI - Sheets, Power Query, DAX, VBA, Tables, Ranges and more. Windows only.
作者のリポジトリから書かれたとおりにコピーしたものです。PopNx MCPは内容を確認・推奨していません。HTML、画像、スクリプトは取り除いています。リンクはこのサイトの外へ移動します。
Keep two coding agents (Claude Code and Codex, or two sessions of either) from overwriting each other's work in the same repository.
agent-lease gives them leases on paths, presence and a shared message log — and the lease is enforced by a PreToolUse hook, not by good intentions. An agent that tries to edit a file another agent is working on is refused before the edit happens.
Česky / Czech version
9 September 2026. A coordination file, docs/AGENT-HANDOFF.md, existed and both agents knew about it. At 22:28 they still both touched deploy/make-work-package.sh: one was editing it while the other was running it. Bash reads a script as it goes, the text shifted under the running process, and instead of a 3.7 GB installer the build produced a useless 198 MB one.
The lesson the whole project rests on: coordination that can be ignored will be ignored. Not out of malice — an agent at work simply does not look at the notice board.
The same collision was later replayed on purpose: Codex ran the script, Claude Code tried to edit it mid-run, and the hook refused the edit. The file stayed intact.
| locks | enforcement | TTL | presence | messages | audit | |
|---|---|---|---|---|---|---|
| AgentRoom (paper) | ✅ | prompt only | ? | ✅ | ✅ | ✅ |
| Agent Claim MCP | ✅ | prompt only | ✅ | ❌ | ❌ | ❌ |
| agent-orchestration | ✅ | prompt only | ❌ | ✅ | ✅ | ❌ |
| agent-lease-mcp | ✅ | PreToolUse hook | ✅ | ✅ | ✅ | ✅ |
Advisory locks get broken; AgentRoom documents this itself. Claude Code and Codex both have PreToolUse hooks with the same semantics (exit 2 = block, reason on stderr), so a lease can be enforced deterministically at the tool-call level. One script serves both clients.
claim.AGENT_LEASE_FAIL_CLOSED=1 flips this for unattended runs.| hook event | what happens |
|---|---|
| SessionStart | the room state is injected into context: who is here, what they hold, messages for you |
| UserPromptSubmit | new messages are delivered once, via a cursor |
| PreToolUse (Edit/Write/apply_patch…) | an edit of a file someone else holds is refused |
| PreToolUse (Bash) | a script being run is leased; obvious writes (>, tee, sed -i, cp/mv target) into a held file are refused |
| Stop / SessionEnd | all leases are returned when the agent finishes its turn |
Injections stay silent when there is nothing to say.
Hooks only fire when the agent acts, so an idle session is woken from outside, without spending model tokens:
agent-lease init claude-code --write --rewake adds an asyncRewake hook on SessionStart and Stop. It waits on a signal file and wakes the session when an addressed message from someone else arrives. Broadcasts and automatic receipts do not wake it.agent-lease-codex-wake service nudges a named session through codex queue (only message numbers, never their text). After a provider limit ends, it nudges once for unfinished work. Setup: /rename nox in Codex, AGENT_LEASE_CODEX_THREAD=nox in ~/.config/agent-lease/environment, then enable deploy/systemd/agent-lease-codex-wake.service.A message from another agent is information, not a human instruction. For agents to hand work to each other unattended, the human writes the allowed scope (and what always needs asking) into the agent's own instructions, e.g. ~/.codex/AGENTS.md. Template and details (in Czech): docs/ZPRAVY-A-POTVRZENI.md.
| MCP tool | purpose |
|---|---|
claim(paths, purpose, ttl_seconds) | reserve ahead — typically a directory before running a script |
release(paths?) | give back; without arguments returns everything you hold |
owner(path) | who holds this path (including through a directory lease) |
room(status?) | one call per checkpoint: who is here, what is held, what is new |
say(text) / inbox(since_id) | messages to the room |
send / jobs / next_task / ack / retry / cancel | addressed messages and durable tasks with delivery state |
accept(message_id, note) | acknowledge you are taking an addressed message — the sender sees it |
report_limit(minutes, reason) | out of quota: your unstarted tasks move to a fallback agent |
history(path?) | who touched what and how it ended — the answer to "why was I blocked" |
The same operations exist as a CLI (agent-lease room|claim|release|say|send|…), because Codex in non-interactive mode cannot approve MCP calls but can run Bash. agent-lease wait --for blocks without spending model tokens and wakes a background session when a message arrives.
say/inbox is not a live chat: MCP is pull, the other side reads a message when it next looks. For a live view there is a local web room: agent-lease web --open (loopback only, see Security).
uv tool install agent-lease-mcp
agent-lease init claude-code --write --rewake # writes all hooks, keeps a .bak backup agent-lease init codex --write agent-lease simulate # 2 s: replays a full scenario in a temp DB agent-lease doctor # checks it really works agent-lease web --open # live room in the browser
init without --write only shows what it would write. Manual setup below.
uv tool install agent-lease-mcp
This puts agent-lease-mcp, agent-lease, agent-lease-guard, agent-lease-context and agent-lease-release on your PATH.
MCP server (stdio; each client runs its own process, the shared state is a SQLite file):
# Claude Code
claude mcp add agent-lease -e AGENT_NAME=claude-code -- agent-lease-mcp
# Codex — ~/.codex/config.toml
[mcp_servers.agent-lease] command = "agent-lease-mcp" env = { AGENT_NAME = "codex" }
[sandbox_workspace_write] writable_roots = ["/home/YOU/.agent-lease"]
Hooks — without them this is just a polite notice board:
// ~/.claude/settings.json
{ "hooks": { "PreToolUse": [{ "matcher": "Edit|Write|MultiEdit|NotebookEdit|Bash", "hooks": [{ "type": "command", "command": "AGENT_NAME=claude-code agent-lease-guard" }] }], "SessionStart": [{ "hooks": [{ "type": "command", "command": "AGENT_NAME=claude-code agent-lease-context" }] }], "UserPromptSubmit": [{ "hooks": [{ "type": "command", "command": "AGENT_NAME=claude-code agent-lease-context" }] }], "Stop": [{ "hooks": [{ "type": "command", "command": "AGENT_NAME=claude-code agent-lease-release" }] }] } }
// ~/.codex/hooks.json — same events, AGENT_NAME=codex
{ "hooks": { "PreToolUse": [{ "matcher": "*", "hooks": [{ "type": "command", "command": "AGENT_NAME=codex agent-lease-guard" }] }] } }
AGENT_NAME must match between the server and the hooks, otherwise an agent blocks its own files. An agent called unconfigured-* in room means exactly that.
| variable | default | purpose |
|---|---|---|
AGENT_NAME | unconfigured- - | name in the room |
AGENT_LEASE_DB | ~/.agent-lease/room.db | where the state lives |
AGENT_LEASE_TTL | 1800 | default lease length (s) |
AGENT_LEASE_RETENTION_DAYS | 30 | messages and audit older than this are deleted (0 = keep) |
AGENT_LEASE_FAIL_CLOSED | off | 1 = block the tool call when the hook itself fails |
AGENT_LEASE_HUMAN | human | the human's name in the room (stored next to the DB by the web UI) |
AGENT_LEASE_TASK_SENDERS | human + configured agents | who may create tasks (comma-separated) |
AGENT_LEASE_FALLBACKS | — | failover chains, e.g. codex=claude-code;claude-code=codex |
A separate PreToolUse hook (agent-lease-jev-guard) for a different question — not "who holds this file" but "is this command destructive". Hard rules (rm -rf /, force push, git reset --hard, curl | sh, mkfs…) apply as soon as it is wired in. An optional external classifier (TypeSafe Jev) is off by default, starts in shadow mode, receives only redacted commands and is advisory — never the only safeguard. Details in ADR 0003.
accept) and is reminded on every prompt. Nothing gets lost silently. agent-lease overdue lists what nobody acknowledged.agent-lease limit / MCP report_limit remains available. Unaccepted, unstarted tasks then move to the next agent in AGENT_LEASE_FALLBACKS (e.g. codex=claude-code;claude-code=codex) after a grace period, and the sender is told.agent-lease bridge --agent codex) — an autonomous worker: takes a task, acknowledges it, runs codex exec / claude -p read-only and returns the result. --provider openrouter --model sends it to any model through OpenRouter as plain text without tools (read-only; good for review and a second opinion). Keys only from the environment. Worker presence/provider state uses a separate identity (codex-bridge, claude-code-bridge), so a headless quota cannot overwrite the state of an interactive agent.leased/started) can be accepted only with its lease token; the bridge skips a task an interactive session has accepted and, with --interactive-grace, leaves fresh tasks to a present interactive agent first.agent-lease broker) — single SQLite writer over a 0600 Unix socket; other tools use it automatically when it runs, so a sandboxed Codex does not need direct access to the database. Clients survive a broker restart: the connect is retried (nothing was sent yet), an interrupted call is never repeated, and long-running workers continue with the next call.--path worksets and a --priority; the scheduler skips paths held by another agent and the board shows the blocking path, owner and TTL. agent-lease notify --loop sends to Telegram only what waits on the human, each event at most once (TELEGRAM_BOT_TOKEN, TELEGRAM_CHAT_ID from the environment; --dry to test).agent-lease worker-activate and agent-lease failover-activate set a safe starting point without running or moving any task: only wo冒頭だけを表示しています。続きはリポジトリで読めます