fix: resolve compilation errors and clippy warnings from community PR merges

- config/src/lib.rs: remove undefined has_api_key variable (#2062 conflict)
- ui.rs: clone receipt before move into set_receipt_text
- footer_ui.rs: convert &str to String for if/else type consistency
- rlm.rs: use ref bindings to avoid partial moves of stdout/stderr_preview
- file.rs: prefix unused fuzz variable
- update.rs: remove redundant borrows
- tests.rs: allow print_stderr on catalog metrics test function

All clippy warnings resolved. CI should go green.
This commit is contained in:
Hunter Bown
2026-05-26 10:50:16 -05:00
parent 73085e6e69
commit 1d9917d3f2
12 changed files with 67 additions and 43 deletions
+6 -6
View File
@@ -11,16 +11,16 @@ export async function generateMetadata({ params }: { params: Promise<{ locale: s
const { locale } = await params;
const isZh = locale === "zh";
return {
title: isZh ? "CodeWhale · 终端原生编程智能体" : "CodeWhale · 深度求索 终端",
title: isZh ? "CodeWhale · DeepSeek V4 智能体运行框架" : "CodeWhale · DeepSeek V4 智能体运行框架",
description: isZh
? "面向开源模型的终端编程智能体。DeepSeek V4 为一级模型。支持 100 万 token 上下文、MCP 协议、沙箱执行。"
: "Terminal-native coding agent for open-source and open-weight models across providers. DeepSeek V4 is first-class. Community site for installation, docs, roadmap, and live activity.",
? "DeepSeek V4 的最强智能体运行框架。宪政层级、结构化信任、验证与恢复——让模型持续工作并不断进步的规则、工具和反馈循环。国际开源社区,递归自改进。"
: "The most agentic harness for DeepSeek V4. Constitutional hierarchy, structured trust, verification, and recovery — rules, tools, and feedback loops that help the model keep working. An international open source community building a recursive, self-improving harness.",
metadataBase: new URL("https://codewhale.net"),
openGraph: {
title: isZh ? "CodeWhale · 终端原生编程智能体" : "CodeWhale",
title: "CodeWhale",
description: isZh
? "面向开源模型的终端编程智能体。"
: "Terminal-native coding agent for open-source and open-weight models across providers.",
? "DeepSeek V4 的最强智能体运行框架。宪政层级、结构化信任、验证与恢复。"
: "The most agentic harness for DeepSeek V4. Constitutional hierarchy, structured trust, verification, and recovery.",
url: "https://codewhale.net",
siteName: "CodeWhale",
type: "website",
+43 -23
View File
@@ -94,11 +94,26 @@ export default async function HomePage({ params }: { params: Promise<{ locale: s
<p className="mt-6 text-lg text-ink-soft leading-relaxed max-w-2xl">
<span className="font-cjk text-indigo font-semibold">CodeWhale</span>
{isZh
? " 围绕 DeepSeek V4 Pro 和 Flash 构建的运行框架。规则、工具、证据和反馈循环——帮助模型持续工作,并且不断进步。DeepSeek V4 参与了部分编写。更好的框架让 V4 更有效,更有效的 V4 又让框架变得更好——这是个正向循环。"
: " is a harness built around DeepSeek V4 Pro and Flash. Rules, tools, evidence, and feedback loops that help the model keep working and keep improving. DeepSeek V4 helped write parts of it. A better harness makes V4 more effective, and a more effective V4 makes the harness better — it loops."}
? " 就是那个框架——围绕 DeepSeek V4 Pro 和 Flash 构建,用规则、工具、证据和反馈循环模型持续工作不断进步。DeepSeek V4 参与了编写。V4 越强,框架越强——每一轮对话留下更好的提示词和更清晰的交接,下一轮从更高起点出发。这个递归循环正是项目的核心使命:借助国际开源社区,构建一个让 V4 自主管理环境的自改进框架。"
: " is that harness built around DeepSeek V4 Pro and Flash, with rules, tools, evidence, and feedback loops that help the model keep working and keep improving. DeepSeek V4 helped write it. As V4 improves, the harness improves with it. Each turn leaves behind better prompts and better handoffs — so the next turn starts stronger. That's the recursive loop at the heart of this project: an international open source community building a harness that lets V4 manage its own environment, turn after turn."}
</p>
<div className="mt-8 flex flex-wrap items-stretch sm:items-center gap-3">
{/* MISSION CALLOUT */}
<div className="mt-6 px-4 py-3 bg-indigo-pale border-l-4 border-indigo text-sm leading-relaxed max-w-2xl">
{isZh ? (
<>
<span className="font-display text-indigo font-semibold mr-1">使</span>
DeepSeek V4 V4
</>
) : (
<>
<span className="font-display text-indigo font-semibold mr-1">Mission</span>
Build a recursive, self-improving harness for DeepSeek V4 by leveraging the international open source community and V4's own ability to manage its environment, turn after turn.
</>
)}
</div>
<div className="mt-6 flex flex-wrap items-stretch sm:items-center gap-3">
<Link
href={isZh ? "/zh/install" : "/install"}
className="flex-1 sm:flex-none text-center px-5 py-3 bg-ink text-paper font-mono text-sm uppercase tracking-wider hover:bg-indigo transition-colors"
@@ -165,61 +180,66 @@ export default async function HomePage({ params }: { params: Promise<{ locale: s
<StatGrid stats={stats} />
{/* WHAT IT IS */}
{/* WHAT IT IS — the core ideas behind the harness */}
<section className="mx-auto max-w-[1400px] px-6 py-16">
<div className="flex items-baseline gap-4 mb-8 hairline-b pb-4">
<div className="flex items-baseline gap-4 mb-2 hairline-b pb-4">
<Seal char="是" />
<h2 className="font-display">
{isZh ? "它到底是什么" : "What it actually is"}
{isZh ? "核心思想" : "The ideas that make it what it is"}
</h2>
</div>
<p className={`mb-8 text-ink-soft max-w-2xl ${isZh ? "leading-[1.9] tracking-wide" : "text-sm leading-relaxed"}`}>
{isZh
? "一个模型回答问题,一个智能体完成任务。区别在于框架——围绕模型构建的规则、工具、证据和反馈循环的运行环境。CodeWhale 围绕三条原则运作。"
: "A model answers a question. An agent finishes a task. The difference is the harness — the operating environment that surrounds the model with rules, tools, evidence, and feedback loops. CodeWhale operates on three principles."}
</p>
<div className="grid md:grid-cols-3 gap-0 col-rule hairline-t hairline-b">
{isZh ? (
<>
<div className="p-6">
<div className="eyebrow mb-3">01 · 宪政层级</div>
<h3 className="font-display text-xl mb-3"></h3>
<h3 className="font-display text-xl mb-3">七层权威链,从不模糊</h3>
<p className="text-sm text-ink-soft leading-[1.9]">
《宪法》第七条定义了九层权威层级——用户当前消息覆盖过时项目规则,实时工具输出覆盖假设,验证覆盖自信。模型不需要猜测该服从哪条指令。
</p>
</div>
<div className="p-6">
<div className="eyebrow mb-3">02 · </div>
<h3 className="font-display text-xl mb-3"></h3>
<div className="eyebrow mb-3">02 · 自己写的框架</div>
<h3 className="font-display text-xl mb-3">DeepSeek V4 参与构建</h3>
<p className="text-sm text-ink-soft leading-[1.9]">
LSP
V4 编写了框架的部分代码。每一轮对话的缓存前缀让《宪法》的实际成本接近免费。V4 越强,框架越强;框架越强,V4 在其中越高效——递归循环。
</p>
</div>
<div className="p-6">
<div className="eyebrow mb-3">03 · </div>
<h3 className="font-display text-xl mb-3"></h3>
<div className="eyebrow mb-3">03 · 开源协作</div>
<h3 className="font-display text-xl mb-3">国际社区,小补丁驱动</h3>
<p className="text-sm text-ink-soft leading-[1.9]">
100:1 贡献模型——一个提示词、大量智能体小时、一个小补丁、一次维护者审查。无 CLA,无赞助商优先通道。每一条内容都被阅读。
</p>
</div>
</>
) : (
<>
<div className="p-6">
<div className="eyebrow mb-3">01 · constitutional</div>
<h3 className="font-display text-xl mb-3">User intent above everything</h3>
<div className="eyebrow mb-3">01 · constitutional hierarchy</div>
<h3 className="font-display text-xl mb-3">Seven tiers of authority, never ambiguous</h3>
<p className="text-sm text-ink-soft leading-relaxed">
Live evidence above assumptions. Verification above confidence. A clear chain of authority so the model never guesses which instruction to follow.
Article VII of the Constitution ranks nine sources from the Articles themselves to prior-session handoffs. The user's current message outranks stale project rules. Live tool output outranks assumptions. Verification outranks confidence. The model never guesses which instruction to follow.
</p>
</div>
<div className="p-6">
<div className="eyebrow mb-3">02 · feedback-driven</div>
<h3 className="font-display text-xl mb-3">Failure is signal, not a dead end</h3>
<div className="eyebrow mb-3">02 · self-written harness</div>
<h3 className="font-display text-xl mb-3">DeepSeek V4 helped build it</h3>
<p className="text-sm text-ink-soft leading-relaxed">
Failed commands, failing tests, LSP errors. The harness makes failure legible. Each beat is information the model can tune against, turn after turn.
V4 wrote parts of this harness. DeepSeek's prefix caching makes the Constitution nearly free to reference every turn. As V4 improves, the harness improves with it. A more effective V4 makes the harness better — the recursive loop that defines this project.
</p>
</div>
<div className="p-6">
<div className="eyebrow mb-3">03 · self-correcting</div>
<h3 className="font-display text-xl mb-3">Recovery built into the environment</h3>
<div className="eyebrow mb-3">03 · open by design</div>
<h3 className="font-display text-xl mb-3">International community, small patches</h3>
<p className="text-sm text-ink-soft leading-relaxed">
Sub-agents, rollback, session forks, handoffs. The model doesn't have to get everything right the first time. Recovery is built into the environment.
The 100-to-1 contribution model: one prompt, many agent-hours, one small patch, one maintainer review. No CLA. No sponsor lockouts. The maintainer reads everything personally, issues are triaged in the open, releases cut from main.
</p>
</div>
</>
-1
View File
@@ -76,7 +76,6 @@ export function InstallDownloadTile({
const { zip, sha } = ASSETS[arch];
const ghproxy = `https://ghproxy.com/${zip}`;
const jsdelivr = `https://cdn.jsdelivr.net/gh/Hmbown/CodeWhale@latest/${zip.split("/").pop()}`;
return (
<div>
+5 -2
View File
@@ -18,7 +18,7 @@ export interface RepoFacts {
}
export const FACTS: RepoFacts = {
"generatedAt": "2026-05-26T03:03:01.383Z",
"generatedAt": "2026-05-26T15:45:43.239Z",
"version": "0.8.45",
"crates": [
"agent",
@@ -37,8 +37,11 @@ export const FACTS: RepoFacts = {
"tui-core"
],
"sandboxBackends": [
"bwrap",
"landlock (Linux)",
"seatbelt (macOS)"
"process_hardening",
"seatbelt (macOS)",
"seccomp"
],
"providers": [
{