AI-native knowledge base & Evernote/Obsidian alternative with instant sync & native MCP. Free on Cloudflare or self-hosted via Docker.
HTML ai-agentcloudflarecloudflare-d1cloudflare-r2cloudflare-workersdockerelectronevernoteevernote-alternativeknowledge-basemcpnote-takingobsidian-alternativeoffline-firstpersonal-knowledge-basepwaself-hostedsqlitetiptapweb-clipper
---
import { Icon } from "astro-icon/components";
import { deploymentPrompts, manualDeploymentCopy } from "@/deployment-prompts";
import { getLocalizedPath } from "@/i18n";
const { locale = "zh-CN" } = Astro.props;
const isEnglish = locale !== "zh-CN";
const copy = isEnglish
? {
oneClick: "Option B: Manual Online Deployment",
agent: "Option A: Deploy with an AI Agent",
docker: "Option C: Docker Deployment",
recommended: "Recommended",
agentIntro:
"Copy the prompt below directly into an AI Agent (such as Codex, Claude, Cursor, WorkBuddy, Antigravity, OpenClaw, Hermes Agent, etc.). During execution, if access to GitHub or Cloudflare is required, review the requested permissions and follow the prompts to authorize access.",
agentGuide: "Detailed requirements: AI Agent Cloudflare Deployment",
agentGuideHref:
"https://github.com/tianma-if/edgeever/blob/main/docs/agent-deploy-cloudflare.md",
oneClickIntro: manualDeploymentCopy["en-US"].intro,
manualSteps: manualDeploymentCopy["en-US"].steps,
oneClickGuide: "Open the online deployment guide",
oneClickGuideHref:
"https://github.com/tianma-if/edgeever/blob/main/docs/deploy-cloudflare-button.md",
dockerTitle: "One-command Docker self-hosting",
dockerPrerequisite: "Install Docker with Docker Compose v2 before running the command.",
dockerGuide: "Open the complete Docker deployment guide",
dockerGuideHref: getLocalizedPath(locale, "/docker-deploy"),
dockerCommandLabel: "COMMAND",
copyCommand: "Copy command",
promptLabel: "PROMPT",
copyPrompt: "Copy prompt",
copying: "Copying...",
copied: "Copied",
copyFailed: "Copy failed",
promptText: deploymentPrompts["en-US"],
}
: {
oneClick: "方案二:手动在线部署",
agent: "方案一:交给 AI Agent 部署",
docker: "方案三:Docker 部署",
recommended: "推荐",
agentIntro:
"将下方提示词直接复制发送给 AI Agent(如 Codex、Claude、Cursor、WorkBuddy、Antigravity、OpenClaw、Hermes Agent 等)。执行过程中,如需访问 GitHub 或 Cloudflare,请确认权限范围并按提示完成授权。",
agentGuide: "详细约定与要求:AI Agent 在线部署约定",
agentGuideHref:
"https://github.com/tianma-if/edgeever/blob/main/docs/agent-deploy-cloudflare.zh-CN.md",
oneClickIntro: manualDeploymentCopy["zh-CN"].intro,
manualSteps: manualDeploymentCopy["zh-CN"].steps,
oneClickGuide: "查看在线部署文档",
oneClickGuideHref:
"https://github.com/tianma-if/edgeever/blob/main/docs/deploy-cloudflare-button.zh-CN.md",
dockerTitle: "一条命令完成 Docker 自托管",
dockerPrerequisite: "运行命令前,请先安装 Docker 环境(含 Docker Compose v2)。",
dockerGuide: "查看完整 Docker 部署指南",
dockerGuideHref: "/docker-deploy",
dockerCommandLabel: "COMMAND",
copyCommand: "复制命令",
promptLabel: "PROMPT",
copyPrompt: "复制提示词",
copying: "复制中...",
copied: "已复制",
copyFailed: "复制失败",
promptText: deploymentPrompts["zh-CN"],
};
---
<section class="not-prose relative left-1/2 my-10 w-[min(92vw,960px)] -translate-x-1/2" data-agent-install-tabs>
<!-- Segmented Control Tab Header (Radix / Shadcn Segmented Control Pill Style) -->
<div
class="mx-auto grid max-w-[900px] grid-cols-1 gap-1 rounded-2xl border border-slate-300/60 bg-slate-200/80 p-1 text-xs font-semibold shadow-2xs select-none md:grid-cols-3 lg:text-sm"
role="tablist"
aria-label={isEnglish ? "Deployment options" : "部署方式"}
>
<button
class="agent-install-tab active flex items-center justify-center gap-1.5 whitespace-nowrap px-2 sm:px-3 py-2 sm:py-2.5 rounded-xl transition-all cursor-pointer bg-white text-slate-950 font-bold shadow-xs"
type="button"
role="tab"
id="agent-install-tab-agent"
data-tab-target="agent"
aria-controls="agent-install-panel-agent"
aria-label={`${copy.agent} · Cloudflare`}
aria-selected="true">
<Icon class="h-4 w-4 shrink-0 text-[#F48120]" name="simple-icons:cloudflare" aria-hidden="true" />
<span>{copy.agent}</span>
<span class="shrink-0 rounded-md bg-emerald-100 text-emerald-800 px-1.5 py-0.5 text-[10px] sm:text-xs font-bold">{copy.recommended}</span>
</button>
<button
class="agent-install-tab flex items-center justify-center gap-1.5 whitespace-nowrap px-2 sm:px-3 py-2 sm:py-2.5 rounded-xl transition-all cursor-pointer text-slate-500 hover:text-slate-900"
type="button"
role="tab"
id="agent-install-tab-one-click"
data-tab-target="one-click"
aria-controls="agent-install-panel-one-click"
aria-label={`${copy.oneClick} · Cloudflare`}
aria-selected="false">
<Icon class="h-4 w-4 shrink-0 text-[#F48120]" name="simple-icons:cloudflare" aria-hidden="true" />
<span>{copy.oneClick}</span>
</button>
<button
class="agent-install-tab flex items-center justify-center gap-1.5 whitespace-nowrap px-2 sm:px-3 py-2 sm:py-2.5 rounded-xl transition-all cursor-pointer text-slate-500 hover:text-slate-900"
type="button"
role="tab"
id="agent-install-tab-docker"
data-tab-target="docker"
aria-controls="agent-install-panel-docker"
aria-selected="false">
<Icon class="h-4 w-4 shrink-0 text-[#2496ED]" name="bx:bxl-docker" aria-hidden="true" />
<span>{copy.docker}</span>
</button>
</div>
<div class="mt-6 overflow-hidden rounded-[28px] bg-slate-100/90 px-4 py-6 sm:px-10 md:px-14 sm:py-8 border border-slate-200/60 shadow-xs">
<div
class="agent-install-panel hidden"
id="agent-install-panel-one-click"
role="tabpanel"
aria-labelledby="agent-install-tab-one-click"
data-tab-panel="one-click"
>
<div class="mx-auto max-w-3xl text-xs leading-relaxed text-slate-600 sm:text-sm md:text-base">
<p class="text-center font-semibold text-slate-800">{copy.oneClickIntro}</p>
<ol class="mt-5 space-y-3 text-left">
{copy.manualSteps.map((step, index) => (
<li class="flex items-start gap-3">
<span class="grid h-6 w-6 shrink-0 place-items-center rounded-full bg-emerald-100 text-xs font-bold text-emerald-800">
{index + 1}
</span>
<p>
<strong class="text-slate-800">{step.title}</strong>{isEnglish ? ": " : ":"}{step.body}
</p>
</li>
))}
</ol>
</div>
<div class="mt-8 flex justify-center">
<a
class="inline-flex items-center gap-2 rounded-full bg-brand px-8 py-3 text-xs sm:text-base font-semibold text-white shadow-[0_14px_30px_-18px_rgb(var(--edgeever-brand-rgb)/0.85)] transition hover:-translate-y-0.5 hover:bg-brand-hover active:scale-95"
href={copy.oneClickGuideHref}
target="_blank"
rel="noopener">
<Icon class="h-5 w-5" name="bx:bx-book-open" />
{copy.oneClickGuide}
</a>
</div>
</div>
<div
class="agent-install-panel"
id="agent-install-panel-agent"
role="tabpanel"
aria-labelledby="agent-install-tab-agent"
data-tab-panel="agent"
>
<div class="mx-auto mb-6 max-w-3xl text-center sm:text-left text-xs sm:text-sm md:text-base leading-relaxed text-slate-600 font-sans">
<p class="text-center leading-relaxed">{copy.agentIntro}</p>
</div>
<!-- Pireel-style Premium Terminal Prompt Window -->
<div class="mx-auto max-w-3xl rounded-2xl border border-slate-800 bg-slate-950 shadow-2xl overflow-hidden font-mono text-xs sm:text-sm">
<!-- Top Window Bar (Explicit rounded-t-2xl to prevent WebKit backdrop-blur overflow) -->
<div class="flex items-center justify-between border-b border-slate-800/80 bg-slate-900/90 rounded-t-2xl px-3.5 sm:px-4 py-2.5 backdrop-blur-sm select-none">
<div class="flex items-center gap-2">
<div class="flex items-center gap-1.5 mr-1.5">
<span class="h-2.5 w-2.5 rounded-full bg-[#ff5f57] inline-block opacity-80"></span>
<span class="h-2.5 w-2.5 rounded-full bg-[#febc2e] inline-block opacity-80"></span>
<span class="h-2.5 w-2.5 rounded-full bg-[#28c840] inline-block opacity-80"></span>
</div>
<span class="flex items-center gap-1.5 text-xs font-bold font-mono text-emerald-400">
<svg xmlns="http://www.w3.org/2000/svg" width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 19h8"></path><path d="m4 17 6-6-6-6"></path></svg>
{copy.promptLabel}
</span>
</div>
<button
type="button"
class="agent-install-copy group inline-flex items-center gap-1.5 px-3 py-1 rounded-lg bg-slate-800 hover:bg-emerald-950/90 border border-slate-700/80 hover:border-emerald-500/50 text-slate-300 hover:text-emerald-300 text-xs font-mono transition-all cursor-pointer select-none"
data-copy-text={copy.promptText}
data-copy-default={copy.copyPrompt}
data-copy-copying={copy.copying}
data-copy-copied={copy.copied}
data-copy-failed={copy.copyFailed}>
<Icon class="h-3.5 w-3.5 text-slate-400 group-hover:text-emerald-400 transition-colors" name="bx:bx-copy" />
<span data-copy-label>{copy.copyPrompt}</span>
</button>
</div>
<div class="rounded-b-2xl bg-slate-950/95 p-4 text-slate-200 sm:p-6">
<pre class="m-0 whitespace-pre-wrap break-words font-mono text-xs leading-relaxed sm:text-sm">{copy.promptText}</pre>
</div>
</div>
<p class="mx-auto mt-4 max-w-3xl text-center text-xs text-slate-600 sm:text-sm">
<a class="font-semibold text-brand underline underline-offset-4 hover:text-brand-hover" href={copy.agentGuideHref} target="_blank" rel="noopener">
{copy.agentGuide}
</a>
</p>
<!-- Bottom R2 Billing Notice Card (Soft Muted Amber Warning) -->
<div class="mx-auto mt-5 flex max-w-3xl items-start gap-2.5 rounded-xl border border-amber-200/50 bg-amber-50/50 p-3 sm:p-3.5 text-xs leading-relaxed text-amber-900/80 font-sans">
<Icon class="mt-0.5 h-4 w-4 shrink-0 text-amber-600/70" name="bx:bx-credit-card" />
{isEnglish ? (
<p>
<span class="font-semibold text-amber-950">Note:</span> Although Cloudflare R2 offers a generous <a class="underline underline-offset-2 hover:text-amber-950" href="https://developers.cloudflare.com/r2/pricing/#free-tier" target="_blank" rel="noopener">free storage allowance</a> that note-taking workloads are unlikely to ever exceed, you must first activate an R2 subscription and add a payment method. Cloudflare <a class="underline underline-offset-2 hover:text-amber-950" href="https://developers.cloudflare.com/billing/get-started/update-billing-info/#supported-payment-methods" target="_blank" rel="noopener">officially supports</a> UnionPay, Visa, Mastercard, and other cards, as well as PayPal, Apple Pay, Google Pay, and other payment methods.
</p>
) : (
<p>
<span class="font-semibold text-amber-950">提示:</span>虽然 Cloudflare R2 存储提供了足够慷慨、在笔记场景中几乎永远不会超量的<a class="underline underline-offset-2 hover:text-amber-950" href="https://developers.cloudflare.com/r2/pricing/#free-tier" target="_blank" rel="noopener">免费存储额度</a>,但需先开通 R2 subscription 并绑定付款方式。Cloudflare <a class="underline underline-offset-2 hover:text-amber-950" href="https://developers.cloudflare.com/billing/get-started/update-billing-info/#supported-payment-methods" target="_blank" rel="noopener">官方支持</a> 银联(UnionPay)、Visa、Mastercard 等银行卡,以及 PayPal、Apple Pay、Google Pay 等付款方式。
</p>
)}
</div>
</div>
<div
class="agent-install-panel hidden"
id="agent-install-panel-docker"
role="tabpanel"
aria-labelledby="agent-install-tab-docker"
data-tab-panel="docker"
>
<div class="mx-auto max-w-3xl text-center font-sans">
<div class="mx-auto grid h-12 w-12 place-items-center rounded-2xl bg-emerald-100 text-emerald-800">
<Icon class="h-7 w-7" name="bx:bxl-docker" />
</div>
<h2 class="mt-4 text-lg font-bold text-slate-900 sm:text-xl">{copy.dockerTitle}</h2>
<p class="mt-2 text-xs leading-relaxed text-slate-600 sm:text-sm md:text-base">{copy.dockerPrerequisite}</p>
</div>
<div class="mx-auto mt-6 max-w-3xl overflow-hidden rounded-2xl border border-slate-800 bg-slate-950 font-mono text-xs shadow-2xl sm:text-sm">
<div class="flex items-center justify-between rounded-t-2xl border-b border-slate-800/80 bg-slate-900/90 px-3.5 py-2.5 select-none sm:px-4">
<span class="flex items-center gap-1.5 text-xs font-bold text-emerald-400">
<Icon class="h-3.5 w-3.5" name="bx:bx-terminal" />
{copy.dockerCommandLabel}
</span>
<button
type="button"
class="agent-install-copy group inline-flex cursor-pointer items-center gap-1.5 rounded-lg border border-slate-700/80 bg-slate-800 px-3 py-1 text-xs text-slate-300 transition-all hover:border-emerald-500/50 hover:bg-emerald-950/90 hover:text-emerald-300"
data-copy-text="curl -fsSL https://edgeever.org/install.sh | bash"
data-copy-default={copy.copyCommand}
data-copy-copying={copy.copying}
data-copy-copied={copy.copied}
data-copy-failed={copy.copyFailed}
>
<Icon class="h-3.5 w-3.5 text-slate-400 transition-colors group-hover:text-emerald-400" name="bx:bx-copy" />
<span data-copy-label>{copy.copyCommand}</span>
</button>
</div>
<div class="rounded-b-2xl bg-slate-950/95 p-4 text-slate-200 sm:p-6">
<pre class="m-0 whitespace-pre-wrap break-all font-mono text-xs leading-relaxed sm:text-sm">curl -fsSL https://edgeever.org/install.sh | bash</pre>
</div>
</div>
<div class="mt-7 flex justify-center">
<a
class="inline-flex items-center gap-2 rounded-full bg-brand px-8 py-3 text-xs font-semibold text-white shadow-[0_14px_30px_-18px_rgb(var(--edgeever-brand-rgb)/0.85)] transition hover:-translate-y-0.5 hover:bg-brand-hover active:scale-95 sm:text-base"
href={copy.dockerGuideHref}
>
<Icon class="h-5 w-5" name="bx:bx-book-open" />
{copy.dockerGuide}
</a>
</div>
</div>
</div>
</section>
<script is:inline>
const copyTextToClipboard = async (text) => {
if (navigator.clipboard && window.isSecureContext) {
await navigator.clipboard.writeText(text);
return;
}
const textarea = document.createElement("textarea");
textarea.value = text;
textarea.setAttribute("readonly", "");
textarea.style.position = "fixed";
textarea.style.left = "-9999px";
textarea.style.top = "0";
document.body.appendChild(textarea);
textarea.focus();
textarea.select();
const copied = document.execCommand("copy");
document.body.removeChild(textarea);
if (!copied) {
throw new Error("Copy command failed");
}
};
const initAgentInstallTabs = () => {
document.querySelectorAll("[data-agent-install-tabs]").forEach((root) => {
if (root.getAttribute("data-agent-install-ready") === "true") return;
root.setAttribute("data-agent-install-ready", "true");
const tabs = Array.from(root.querySelectorAll("[data-tab-target]"));
const panels = Array.from(root.querySelectorAll("[data-tab-panel]"));
const activateTab = (tab) => {
const target = tab.getAttribute("data-tab-target");
tabs.forEach((item) => {
const isActive = item === tab;
item.setAttribute("aria-selected", String(isActive));
item.setAttribute("tabindex", isActive ? "0" : "-1");
item.classList.toggle("active", isActive);
if (isActive) {
item.classList.add("bg-white", "text-slate-950", "font-bold", "shadow-xs");
item.classList.remove("text-slate-500");
} else {
item.classList.remove("bg-white", "text-slate-950", "font-bold", "shadow-xs");
item.classList.add("text-slate-500");
}
});
panels.forEach((panel) => {
panel.classList.toggle("hidden", panel.getAttribute("data-tab-panel") !== target);
});
};
tabs.forEach((tab) => {
tab.addEventListener("click", () => {
activateTab(tab);
});
tab.addEventListener("keydown", (event) => {
const currentIndex = tabs.indexOf(tab);
let nextIndex = currentIndex;
if (event.key === "ArrowRight" || event.key === "ArrowDown") nextIndex = (currentIndex + 1) % tabs.length;
if (event.key === "ArrowLeft" || event.key === "ArrowUp") nextIndex = (currentIndex - 1 + tabs.length) % tabs.length;
if (event.key === "Home") nextIndex = 0;
if (event.key === "End") nextIndex = tabs.length - 1;
if (nextIndex === currentIndex) return;
event.preventDefault();
activateTab(tabs[nextIndex]);
tabs[nextIndex].focus();
});
});
activateTab(tabs.find((tab) => tab.getAttribute("aria-selected") === "true") || tabs[0]);
root.querySelectorAll(".agent-install-copy").forEach((button) => {
button.addEventListener("click", async () => {
const text = button.getAttribute("data-copy-text") || "";
const label = button.querySelector("[data-copy-label]");
const defaultLabel = button.getAttribute("data-copy-default") || "Copy";
const copyingLabel = button.getAttribute("data-copy-copying") || "Copying...";
const copiedLabel = button.getAttribute("data-copy-copied") || "Copied";
const failedLabel = button.getAttribute("data-copy-failed") || "Copy failed";
if (label) label.textContent = copyingLabel;
try {
await copyTextToClipboard(text);
if (label) label.textContent = copiedLabel;
window.setTimeout(() => {
if (label) label.textContent = defaultLabel;
}, 1600);
} catch {
if (label) label.textContent = failedLabel;
}
});
});
});
};
if (document.readyState === "loading") {
document.addEventListener("DOMContentLoaded", initAgentInstallTabs);
} else {
initAgentInstallTabs();
}
</script>