Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,6 @@ jobs:
uv export --frozen --no-dev --extra proxy --extra workspace --no-emit-project
--format requirements-txt |
uvx --from pip-audit==2.10.1 pip-audit -r /dev/stdin
- run: uv run ruff format --check src
- run: uv run ruff check src
- run: uv run ruff format --check src tests
- run: uv run ruff check src tests
- run: uv run python -m unittest discover -s tests
4 changes: 3 additions & 1 deletion SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ or container environment dumps. The user Quadlet mounts owner-only credential fi
Podman-managed secrets can also be mounted there.

Treat every MCP server as executable authority. Configure only reviewed endpoints,
allowlist tools, prefer `read_only=true`, and require application approval for writes.
allowlist tools and prefer `read_only=true`. Write confirmation is enabled by
default. Setting `confirm_writes=false` authorizes direct execution of the
server's allowlisted tools for everyone covered by its `access` setting.
Never mount the Podman socket into the yachiyo core or workspace container.

Group observation and learning are disabled by default. Administrators must explicitly
Expand Down
27 changes: 27 additions & 0 deletions config/config.example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,30 @@ timeout_seconds = 30
max_result_bytes = 262144
allow_insecure_http = true
actor_scoped_workspace = true

[[mcp.servers]]
name = "rss"
url = "http://169.254.1.1:8769/mcp"
enabled = false
bearer_secret = "rss_mcp_token"
allowed_tools = [
"add_subscription",
"update_subscription",
"remove_subscription",
"list_subscriptions",
"server_status",
"fetch_feed",
"list_entries",
"read_entry",
"search_entries",
"get_digest",
"mark_entry",
"star_entry",
"import_opml",
"export_opml",
"discover_feed",
]
read_only = false
access = "public"
confirm_writes = false
allow_insecure_http = true
52 changes: 52 additions & 0 deletions config/rss/frontier-ai.opml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
<?xml version="1.0" encoding="UTF-8"?>
<opml version="2.0">
<head>
<title>Frontier AI 一线研究与工程订阅</title>
<dateCreated>Tue, 01 Sep 2026 00:00:00 GMT</dateCreated>
<dateModified>Sun, 22 Nov 2026 12:00:00 GMT</dateModified>
</head>
<body>
<outline text="01 国内原生博客(稳定)" title="01 国内原生博客(稳定)">
<outline type="rss" text="科学空间 · 苏剑林" title="科学空间 · 苏剑林" htmlUrl="https://spaces.ac.cn/" xmlUrl="https://spaces.ac.cn/feed/" />
<outline type="rss" text="Yuxin Wu · Moonshot" title="Yuxin Wu · Moonshot" htmlUrl="https://ppwwyyxx.com/blog/archives/" xmlUrl="https://ppwwyyxx.com/blog/atom.xml" />
<outline type="rss" text="Yuxuan Tong · ByteDance Seed" title="Yuxuan Tong · ByteDance Seed" htmlUrl="https://tongyx361.github.io/blogs/" xmlUrl="https://tongyx361.github.io/blogs/index.xml" />
<outline type="rss" text="KVCache.AI · Mooncake" title="KVCache.AI · Mooncake" htmlUrl="https://kvcache.ai/blog/" xmlUrl="https://kvcache.ai/blog/index.xml" />
<outline type="rss" text="Zhihong Shao · DeepSeek" title="Zhihong Shao · DeepSeek" htmlUrl="https://zhihongshao.github.io/" xmlUrl="https://zhihongshao.github.io/feed.xml" />
<outline type="rss" text="Xunhao Lai · MiniMax" title="Xunhao Lai · MiniMax" htmlUrl="https://xunhaolai.github.io/" xmlUrl="https://xunhaolai.github.io/feed.xml" />
<outline type="rss" text="Atum · MiniMax" title="Atum · MiniMax" htmlUrl="https://atum.li/en/" xmlUrl="https://atum.li/rss-en.xml" />
<outline type="rss" text="Chengxing Xie · GLM/Z.ai" title="Chengxing Xie · GLM/Z.ai" htmlUrl="https://yitianlian.github.io/year-archive/" xmlUrl="https://yitianlian.github.io/feed.xml" />
<outline type="rss" text="Zhonglin Xie · ByteDance Seed" title="Zhonglin Xie · ByteDance Seed" htmlUrl="https://zhonglinxie.github.io/" xmlUrl="https://zhonglinxie.github.io/feed.xml" />
</outline>
<outline text="02 国外原生博客(稳定)" title="02 国外原生博客(稳定)">
<outline type="rss" text="Lilian Weng · Lil'Log" title="Lilian Weng · Lil'Log" htmlUrl="https://lilianweng.github.io/" xmlUrl="https://lilianweng.github.io/index.xml" />
<outline type="rss" text="Brendan Gregg · Systems Performance" title="Brendan Gregg · Systems Performance" htmlUrl="https://www.brendangregg.com/blog/" xmlUrl="https://www.brendangregg.com/blog/rss.xml" />
<outline type="rss" text="Boaz Barak · Windows on Theory" title="Boaz Barak · Windows on Theory" htmlUrl="https://windowsontheory.org/" xmlUrl="https://windowsontheory.org/feed/" />
<outline type="rss" text="OpenAI · Alignment Research" title="OpenAI · Alignment Research" htmlUrl="https://alignment.openai.com/" xmlUrl="https://alignment.openai.com/rss.xml" />
<outline type="rss" text="Nicholas Carlini · Writing" title="Nicholas Carlini · Writing" htmlUrl="https://nicholas.carlini.com/writing" xmlUrl="https://nicholas.carlini.com/writing/feed.xml" />
<outline type="rss" text="Den Delimarsky · Writing" title="Den Delimarsky · Writing" htmlUrl="https://den.dev/blog/" xmlUrl="https://den.dev/blog/index.xml" />
<outline type="rss" text="Andrej Karpathy · Blog" title="Andrej Karpathy · Blog" htmlUrl="https://karpathy.github.io/" xmlUrl="https://karpathy.github.io/feed.xml" />
<outline type="rss" text="Andy Jones · RL and Infrastructure" title="Andy Jones · RL and Infrastructure" htmlUrl="https://andyljones.com/" xmlUrl="https://andyljones.com/rss.xml" />
<outline type="rss" text="Jan Leike · Alignment Musings" title="Jan Leike · Alignment Musings" htmlUrl="https://aligned.substack.com/" xmlUrl="https://aligned.substack.com/feed" />
<outline type="rss" text="Transformer Circuits Thread" title="Transformer Circuits Thread" htmlUrl="https://transformer-circuits.pub/" xmlUrl="https://transformer-circuits.pub/feed.xml" />
<outline type="rss" text="Sander Dieleman · Generative Models" title="Sander Dieleman · Generative Models" htmlUrl="https://sander.ai/" xmlUrl="https://sander.ai/feed.xml" />
<outline type="rss" text="Alex Irpan · Sorta Insightful" title="Alex Irpan · Sorta Insightful" htmlUrl="https://www.alexirpan.com/" xmlUrl="https://www.alexirpan.com/feed.xml" />
<outline type="rss" text="Yi Tay · Blog" title="Yi Tay · Blog" htmlUrl="https://www.yitay.net/" xmlUrl="https://www.yitay.net/blog?format=rss" />
<outline type="rss" text="Fabian Pedregosa · Keep the Gradient Flowing" title="Fabian Pedregosa · Keep the Gradient Flowing" htmlUrl="https://fa.bianp.net/" xmlUrl="https://fa.bianp.net/blog/feed/rss.xml" />
<outline type="rss" text="Utku Evci · Blog" title="Utku Evci · Blog" htmlUrl="https://www.utkuevci.com/" xmlUrl="https://evcu.github.io/feed.xml" />
<outline type="rss" text="Elie Bursztein · AI and Cybersecurity" title="Elie Bursztein · AI and Cybersecurity" htmlUrl="https://elie.net/blog" xmlUrl="https://feeds.feedburner.com/inftoint" />
<outline type="rss" text="John Langford · Machine Learning Theory" title="John Langford · Machine Learning Theory" htmlUrl="https://hunch.net/" xmlUrl="https://hunch.net/?feed=rss2" />
<outline type="rss" text="Microsoft Research Blog" title="Microsoft Research Blog" htmlUrl="https://www.microsoft.com/en-us/research/blog/" xmlUrl="https://www.microsoft.com/en-us/research/feed/" />
<outline type="rss" text="AKS Engineering Blog" title="AKS Engineering Blog" htmlUrl="https://blog.aks.azure.com/" xmlUrl="https://blog.aks.azure.com/rss.xml" />
</outline>
<outline text="03 推理与扩散社区博客(已核对)" title="03 推理与扩散社区博客(已核对)">
<outline type="rss" text="vLLM Blog" title="vLLM Blog" htmlUrl="https://vllm.ai/blog" xmlUrl="https://vllm.ai/blog/rss.xml" />
<outline type="rss" text="PyTorch Blog" title="PyTorch Blog" htmlUrl="https://pytorch.org/blog/" xmlUrl="https://pytorch.org/blog/feed/" />
<outline type="rss" text="Hugging Face Blog" title="Hugging Face Blog" htmlUrl="https://huggingface.co/blog" xmlUrl="https://huggingface.co/blog/feed.xml" />
<outline type="rss" text="NVIDIA Technical Blog" title="NVIDIA Technical Blog" htmlUrl="https://developer.nvidia.com/blog/" xmlUrl="https://developer.nvidia.com/blog/feed" />
<outline type="rss" text="Modal Blog" title="Modal Blog" htmlUrl="https://modal.com/blog" xmlUrl="https://modal.com/blog/atom.xml" />
<outline type="rss" text="FlashInfer Blog" title="FlashInfer Blog" htmlUrl="https://flashinfer.ai/" xmlUrl="https://flashinfer.ai/feed.xml" />
<outline type="rss" text="DeepSpeed" title="DeepSpeed" htmlUrl="https://www.deepspeed.ai/" xmlUrl="https://www.deepspeed.ai/feed.xml" />
<outline type="rss" text="AMD ROCm Blogs" title="AMD ROCm Blogs" htmlUrl="https://rocm.blogs.amd.com/" xmlUrl="https://rocm.blogs.amd.com/blog/atom.xml" />
</outline>
</body>
</opml>
35 changes: 35 additions & 0 deletions config/rss/import_feeds.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
"""Import the Frontier AI subscriptions into the local rss-mcp service."""

import asyncio
from pathlib import Path

import aiohttp
from yachiyo.adapters.mcp import MCPError, _ServerClient
from yachiyo.config.models import MCPServerSettings

RSS_DIR = Path(__file__).resolve().parent


async def main() -> None:
token = (RSS_DIR.parent / ".secrets" / "rss_mcp_token").read_text().strip()
settings = MCPServerSettings(
name="rss",
url="http://127.0.0.1:8769/mcp",
allow_insecure_http=True,
allowed_tools=("import_opml",),
)
async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(total=30)) as session:
client = _ServerClient(settings, session, token)
try:
result = await client.call_tool(
"import_opml", {"opml": (RSS_DIR / "frontier-ai.opml").read_text()}
)
if not result.ok:
raise MCPError(result.content)
print(result.content)
finally:
await client.close()


if __name__ == "__main__":
asyncio.run(main())
26 changes: 26 additions & 0 deletions config/rss/yachiyo-rss.container
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[Unit]
Description=RSS MCP for Yachiyo

[Quadlet]
DefaultDependencies=false

[Container]
Image=localhost/yachiyo-rss-mcp:ab7f2ad
Pull=never
ContainerName=yachiyo-rss
UserNS=keep-id:uid=10001,gid=10001
User=10001
Group=10001
PublishPort=127.0.0.1:8769:8000
Volume=%h/.local/share/yachiyo-rss:/data:Z
Secret=yachiyo-rss-token,type=env,target=RSS_MCP_AUTH_TOKEN
Environment=RSS_MCP_REFRESH_INTERVAL=1800
DropCapability=all
NoNewPrivileges=true

[Service]
ExecStartPre=/usr/bin/mkdir -p -m 0700 %h/.local/share/yachiyo-rss
Restart=on-failure

[Install]
WantedBy=default.target
6 changes: 3 additions & 3 deletions docs/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ replies. The SQLite repository owns the transaction that records each reply.
The durable outbox provides at-least-once delivery. Telegram and Discord do not expose
a transaction spanning multi-part sends, so a process or network failure after a
platform accepts only part of a response can duplicate that accepted prefix on replay.
Model and remote read-only tool calls are likewise at-least-once across process crashes;
non-read-only MCP calls require a separately persisted user approval.
Model and direct MCP tool calls are likewise at-least-once across process crashes.
By default, non-read-only MCP calls require a separately persisted user approval.

## Data model

Expand All @@ -110,7 +110,7 @@ in a single transaction. Older v2 databases may retain unused vector tables.
environment variables. Effective configuration and logs never contain secret values.
- MCP accepts only configured HTTP endpoints, does not spawn commands, prefixes every
tool name, requires an explicit non-empty allowlist, limits response bytes, filters
access and requires persistent approval for every non-read-only tool.
access and checks whether the server requires approval for writes.
- Media and reverse-image integrations validate HTTPS hosts, resolved public IPs,
redirects, MIME types, magic bytes, response sizes and timeouts.
- The workspace MCP server is a separate container. It rejects traversal, `.git` file
Expand Down
47 changes: 47 additions & 0 deletions docs/podman.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,50 @@ give it a writable `/workspaces` directory, and mount only `workspace_mcp_token`
under `/run/secrets` with mode `0400` for UID 10001. The Podman socket stays on the
host. Enable the `workspace` entry in the core's MCP settings and configure an
administrator before using its private admin tools.

## Optional RSS server

The [rss-mcp](https://github.com/huangcheng/rss-mcp) sidecar stores subscriptions,
entries and digest delivery state in `~/.local/share/yachiyo-rss/rss.db`. Build the
revision used by the RSS Quadlet from the checkout root.

```sh
git clone https://github.com/huangcheng/rss-mcp.git /tmp/yachiyo-rss-upstream
git -C /tmp/yachiyo-rss-upstream checkout --detach ab7f2ad110537027baa48e943729d2345491e020
podman build -t localhost/yachiyo-rss-mcp:ab7f2ad /tmp/yachiyo-rss-upstream
```

Create the shared token once and register its value as a Podman secret.

```sh
(umask 077; set -C; openssl rand -hex 32 > config/.secrets/rss_mcp_token)
tr -d '\r\n' < config/.secrets/rss_mcp_token | podman secret create yachiyo-rss-token -
quadlets="${XDG_CONFIG_HOME:-$HOME/.config}/containers/systemd"
mkdir -p "$quadlets"
ln -sT "$PWD/config/rss/yachiyo-rss.container" "$quadlets/yachiyo-rss.container"
systemctl --user daemon-reload
systemctl --user start yachiyo-rss.service
```

Enable the loopback mapping in the core Quadlet using
`Network=pasta:--map-host-loopback,169.254.1.1` in its local drop-in. The RSS port
is published only on host loopback. If outbound feeds need the host proxy,
add the same pasta mapping and proxy environment settings to a local
`yachiyo-rss.container.d/local.conf` next to the installed RSS Quadlet. Copy the example RSS server entry to the
active TOML, enable both the MCP section and the RSS entry, then run the following
from a checkout with Yachiyo installed in its local Python environment.

```sh
.venv/bin/python config/rss/import_feeds.py
podman build --target core -f config/Containerfile -t localhost/yachiyo:2.0.0 .
systemctl --user daemon-reload
systemctl --user restart yachiyo.service
podman exec yachiyo yachiyo mcp check
```

The import preserves the three OPML folders as tags and skips existing URLs.
The sidecar refreshes feeds every 30 minutes. The public RSS entry lists all
15 tools from the pinned server. Anyone chatting with Yachiyo in a DM or group
can use them directly, including adding or removing feeds, importing or exporting
OPML, and marking articles read or starred. These changes affect the shared RSS
library. `get_digest` skips entries already delivered to any chat by default.
Loading
Loading