graff — a fast agentic coding harness in Zig: multi-provider, MCP, workflows, DGM evolution loop, TS/Python SDKs
Python
fix: keep provider/vision under 600 after Gemini merge; provider cube is 23
justrach3d35e6f6c375
diff --git a/lean-proofs/Graff/Provider.lean b/lean-proofs/Graff/Provider.leanindex be5cb9b3..2d28eae8 100644--- a/lean-proofs/Graff/Provider.lean+++ b/lean-proofs/Graff/Provider.lean@@ -85,7 +85,7 @@ def xApiKeyCount : Nat := countWhere (fun r => r.auth == .xApiKey) specsdef providerRows : Nat := specs.length-theorem provider_cube : providerRows = 22 := by native_decide+theorem provider_cube : providerRows = 23 := by native_decidetheorem responses_vendors : responsesCount = 2 := by native_decidetheorem one_x_api_key : xApiKeyCount = 1 := by native_decidediff --git a/spec/conformance.py b/spec/conformance.pyindex 9f2cfb0f..235a1f2b 100644--- a/spec/conformance.py+++ b/spec/conformance.py@@ -317,8 +317,8 @@ def check_provider() -> int:ids = [r["id"] for r in PROVIDER_SPECS]if len(ids) != len(set(ids)):raise Counterexample("provider-unique", None, f"ids={ids}")- if len(PROVIDER_SPECS) != 22:- raise Counterexample("provider-count", None, f"n={len(PROVIDER_SPECS)} want=22")+ if len(PROVIDER_SPECS) != 23:+ raise Counterexample("provider-count", None, f"n={len(PROVIDER_SPECS)} want=23")responses = [r for r in PROVIDER_SPECS if r["kind"] == "responses"]if [r["id"] for r in responses] != ["openai", "codex"]:raise Counterexample("responses-vendors", None, f"{responses}")diff --git a/src/provider.zig b/src/provider.zigindex 362dfb1c..545d3c04 100644--- a/src/provider.zig+++ b/src/provider.zig@@ -24,17 +24,11 @@ pub var g_context_override: ?u64 = null;/// (default 80). null → 80. Unlike codex we allow lowering AND raising (1..100).pub var g_compact_pct_override: ?u8 = null;-/// #502: xAI rides the OpenAI Responses wire at api.x.ai/v1/responses BY-/// DEFAULT — WebSocket turns with the SSE/full-resend fallback ladder.-/// Compaction stays on the client summarizer (it beat xAI's blob endpoint).-/// GRAFF_XAI_WIRE=chat (or anything other than "responses") opts back into-/// chat completions.+/// #502: xAI defaults to api.x.ai/v1/responses (WS, SSE fallback). Compaction+/// is the client summarizer. GRAFF_XAI_WIRE=chat opts back to chat completions.pub var g_xai_responses: bool = true;pub const xai_responses_url = "https://api.x.ai/v1/responses";-/// xAI's explicit compaction endpoint (POST {model, input} → one opaque-/// compaction item). Unlike codex there is no in-stream compaction — api.x.ai-/// silently ignores the context_management directive (probed 2026-08-15).pub const xai_compact_url = "https://api.x.ai/v1/responses/compact";/// The context window for a provider+model, honoring g_context_override for andiff --git a/src/vision.zig b/src/vision.zigindex 8a88a93e..d39c24cd 100644--- a/src/vision.zig+++ b/src/vision.zig@@ -1,11 +1,7 @@-//! Image/vision support: the staged-image type + per-provider vision-capability-//! check, media-type-from-extension, the anthropic/openai/responses image-//! message builder, and the /image·/paste·Ctrl-V·GUI-attachment stagers.-//! Split out of main.zig (600-line goal). Back-imports main (as main_mod,-//! since the stagers' param is named `root`) for Agent, Provider, and-//! isImagePath. main aliases the public surface back. The macOS pasteboard-//! cascade itself (and the byte budget staged images live under) is one level-//! down in vision_clipboard.zig and re-exported here.+//! Image/vision support: staged-image type, capability check, media type,+//! anthropic/openai/responses/interactions builders, and /image·paste stagers.+//! Split out of main.zig. Back-imports main as main_mod. Pasteboard cascade+//! lives in vision_clipboard.zig and is re-exported here.const std = @import("std");const builtin = @import("builtin");