graff — a fast agentic coding harness in Zig: multi-provider, MCP, workflows, DGM evolution loop, TS/Python SDKs
Python
docs: frame browser, occupancy, and update README captures
justrach9b5be733dc3b
diff --git a/README.md b/README.mdindex 90898c6f..f416b270 100644--- a/README.md+++ b/README.md@@ -48,7 +48,7 @@ be steered. The optional profiler records anonymous per-agent resourcemeasurements (no identities or message contents). See the[Agents guide](docs/agents-panel.md).-[](docs/images/desktop-occupancy.png)+[](docs/images/desktop-occupancy.png)[](docs/images/desktop-review-dark.png)@@ -90,9 +90,9 @@ sessions are snapshots. Background browser work does not steal the focusedchat. MCP tools that declare an App UI render in an isolated result frame;`graff mcp install` registers a local HTTP task service for other clients.-[](docs/images/native-browser-annotate.jpg)+[](docs/images/native-browser-annotate.jpg)-[](docs/images/desktop-update-ready.png)+[](docs/images/desktop-update-ready.png)**Profile and test without a model.** The Performance menu and desktop profilertool record bounded, local measurement reports. Startup paint timing, streamingdiff --git a/docs/images/desktop-browser-studio.png b/docs/images/desktop-browser-studio.pngnew file mode 100644index 00000000..8a012b32Binary files /dev/null and b/docs/images/desktop-browser-studio.png differdiff --git a/docs/images/desktop-occupancy-studio.png b/docs/images/desktop-occupancy-studio.pngnew file mode 100644index 00000000..1d75eb06Binary files /dev/null and b/docs/images/desktop-occupancy-studio.png differdiff --git a/docs/images/desktop-update-studio.png b/docs/images/desktop-update-studio.pngnew file mode 100644index 00000000..8c57dab9Binary files /dev/null and b/docs/images/desktop-update-studio.png differdiff --git a/docs/media/README.md b/docs/media/README.mdindex 9d85e2f8..62085744 100644--- a/docs/media/README.md+++ b/docs/media/README.md@@ -34,3 +34,16 @@ For the official typography, set `GRAFF_DESIGN_FONTS` to a local directorycontaining licensed `SinarGrotesk-SemiBold.woff2` and `Gramatika-Regular.woff2`.Font files are not redistributed here. Without that variable, the layouts usesystem fonts. Review the rendered images after changing typography or copy.++Browser, Agents occupancy, and Update-ready use the same rice-paper frame and+workshop stamps. Their heights follow the source aspect ratios so the complete+captures fit above the footer. Each README thumbnail still links to its original.+To regenerate just these plates:++```sh+apps/native/node_modules/.bin/electron docs/media/render-readme.cjs desktop-browser-studio desktop-occupancy-studio desktop-update-studio+```++The renderer also checks that screenshot frames clear the footer and headings+clear the artwork stamps. `art/workshop-update.png` is the companion update+illustration; UI content always comes from the unchanged source captures.diff --git a/docs/media/art/workshop-update.png b/docs/media/art/workshop-update.pngnew file mode 100644index 00000000..23da08a2Binary files /dev/null and b/docs/media/art/workshop-update.png differdiff --git a/docs/media/readme-plates.cjs b/docs/media/readme-plates.cjsindex 87172fa8..cd99bf2b 100644--- a/docs/media/readme-plates.cjs+++ b/docs/media/readme-plates.cjs@@ -2,7 +2,7 @@ const fs = require('node:fs');const path = require('node:path');const root = path.resolve(__dirname, '../..');const uri = file => `data:${file.endsWith('.woff2') ? 'font/woff2' : file.endsWith('.png') ? 'image/png' : 'image/jpeg'};base64,${fs.readFileSync(file).toString('base64')}`;-const art = name => uri(path.join(__dirname, 'art', `workshop-${name}.jpg`));+const art = name => uri(path.join(__dirname, 'art', `workshop-${name}${name === 'update' ? '.png' : '.jpg'}`));const shot = name => uri(path.join(root, 'docs/images', `desktop-${name}.png`));const grain = `<svg xmlns="http://www.w3.org/2000/svg" width="180" height="180"><filter id="n"><feTurbulence type="fractalNoise" baseFrequency=".75" numOctaves="3" stitchTiles="stitch"/></filter><rect width="100%" height="100%" opacity=".3" filter="url(#n)"/></svg>`;const mark = `<svg viewBox="0 0 32 32" fill="none"><path d="M26 8a13 13 0 1 0 1 15" stroke="currentColor" stroke-width="3" stroke-linecap="round"/><path d="m12 12-4 4 4 4m9-8 4 4-4 4m-3-10-3 12" stroke="currentColor" stroke-width="1.8" stroke-linecap="round"/></svg>`;@@ -16,9 +16,9 @@ function page(body, theme = '') {}const brand = (label = 'DESKTOP / MACOS') => `<div class="brand">${mark}<span>codegraff</span><small>${label}</small></div>`;const windowFrame = (image, tone) => `<div class="window ${tone}"><div class="chrome"><div class="lights"><i></i><i></i><i></i></div><span>CodeGraff</span><b>●</b></div><img class="screenshot" src="${image}" /></div>`;-function screen({ id, title, note, label, file, artName, theme }) {+function screen({ id, title, note, label, file, source, artName, theme }) {return page(`${brand()}<header><div class="eyebrow">${id} / ${label}</div><h1>${title}</h1><p>${note}</p></header>- <div class="art-stamp"><img src="${art(artName)}" /></div><div class="stage">${windowFrame(shot(file), theme === 'night' ? 'dark' : 'paper')}</div>+ <div class="art-stamp"><img src="${art(artName)}" /></div><div class="stage">${windowFrame(source ? uri(path.join(root, 'docs/images', source)) : shot(file), theme === 'night' ? 'dark' : 'paper')}</div><footer><span class="footer-label">${label}</span><span>Actual desktop UI · demonstration workspace</span><span class="edition">GRAFF / DESKTOP</span></footer>`, theme);}module.exports = [@@ -26,6 +26,9 @@ module.exports = [{ name: 'desktop-chat-studio', width: 1920, height: 1530, html: () => screen({ id:'01', title:'A place to do the work.', note:'A clear conversation. Your tools close at hand.', label:'THE WORKSPACE', file:'chat-light', artName:'run', theme:'bright' }) },{ name: 'desktop-agents-studio', width: 1920, height: 1530, html: () => screen({ id:'02', title:'Many hands. One workspace.', note:'See the crew. Share context. Pass the work along.', label:'AGENT COORDINATION', file:'agents-codegraff', artName:'agents', theme:'coral' }) },{ name: 'desktop-review-studio', width: 1920, height: 1530, html: () => screen({ id:'03', title:'Room for a closer look.', note:'Keep the conversation beside the changes.', label:'CHANGES & REVIEW', file:'review-dark', artName:'review', theme:'night' }) },+ { name: 'desktop-occupancy-studio', width: 1920, height: 1660, html: () => screen({ id:'04', title:'Keep an eye on the crew.', note:'Occupancy, resource use, and peer talk in one pane.', label:'AGENT OCCUPANCY', file:'occupancy', artName:'agents', theme:'occupancy' }) },+ { name: 'desktop-browser-studio', width: 1920, height: 1460, html: () => screen({ id:'05', title:'Bring the page into the work.', note:'Pin a detail. Continue the conversation.', label:'BROWSER & ANNOTATIONS', source:'native-browser-annotate.jpg', artName:'review', theme:'browser' }) },+ { name: 'desktop-update-studio', width: 1920, height: 1760, html: () => screen({ id:'06', title:'Ready when you are.', note:'An update is ready. You choose when to restart.', label:'DESKTOP UPDATES', file:'update-ready', artName:'update', theme:'update' }) },{ name: 'readme-context-workshop', width:1920, height:920, html: () => page(`${brand('INSIDE THE HARNESS')}<div class="loop-art"><img src="${art('review')}" /></div><div class="loop-copy"><div class="eyebrow">HOW CONTEXT MOVES THROUGH GRAFF</div><h1>Context that stays useful.</h1><ol><li><b>01</b><div><strong>Reuse the setup</strong><p>Keep stable instructions ready for the next step.</p></div></li><li><b>02</b><div><strong>Work with the context</strong><p>Run small programs and coordinate tool calls.</p></div></li><li><b>03</b><div><strong>Carry the result forward</strong><p>Return the information the next step needs.</p></div></li></ol></div><div class="hero-bottom">THE GRAFF WORKSHOP <span>CONTEXT → TOOLS → RESULTS</span></div>`, 'loop') },diff --git a/docs/media/readme-plates.css b/docs/media/readme-plates.cssindex c02ea4e0..38168563 100644--- a/docs/media/readme-plates.css+++ b/docs/media/readme-plates.css@@ -38,3 +38,7 @@ footer { position: absolute; left: 84px; right: 84px; bottom: 43px; display: fle.loop-copy li:not(:last-child)::after { content:''; position:absolute; left:23px; top:76px; bottom:-12px; width:1px; background:#d9caba; }.loop-copy li b { color:#ad4937; background:#ecdfce; border-radius:50%; width:48px; height:48px; display:grid; place-items:center; flex-shrink:0; font:16px ui-monospace,monospace; }.loop-copy strong { font:32px Display,sans-serif; }.loop-copy p { font-size:24px; color:#736557; margin:12px 0 0; line-height:1.4; }++.occupancy { height:1660px; }+.browser { height:1460px; }+.update { height:1760px; }diff --git a/docs/media/render-readme.cjs b/docs/media/render-readme.cjsindex 9470dfbc..267a7869 100644--- a/docs/media/render-readme.cjs+++ b/docs/media/render-readme.cjs@@ -13,13 +13,24 @@ const output = path.resolve(__dirname, '../images');app.whenReady().then(async () => {win = new BrowserWindow({ show:false, frame:false, transparent:true, backgroundColor:'#00000000', width:1920, height:1530, useContentSize:true, webPreferences:{ sandbox:true, contextIsolation:true, nodeIntegration:false, backgroundThrottling:false } });win.webContents.session.webRequest.onBeforeRequest((details, callback) => callback({cancel: /^https?:/.test(details.url)}));- for (const plate of plates) {+ const requested = process.argv.slice(2);+ for (const name of requested) assert.ok(plates.some(p => p.name === name), `Unknown plate: ${name}`);+ for (const plate of plates.filter(p => !requested.length || requested.includes(p.name))) {win.setContentSize(plate.width, plate.height);const html = path.join(temporary, `${plate.name}.html`);fs.writeFileSync(html, plate.html());await win.loadFile(html);const state = await win.webContents.executeJavaScript(`(async()=>{await document.fonts.ready;await Promise.all([...document.images].map(i=>i.decode()));await new Promise(r=>requestAnimationFrame(()=>requestAnimationFrame(r)));return {width:innerWidth,height:innerHeight,overflow:document.documentElement.scrollWidth>innerWidth,images:[...document.images].every(i=>i.naturalWidth>0)}})()`);assert.deepEqual(state, {width:plate.width,height:plate.height,overflow:false,images:true});+ const layout = await win.webContents.executeJavaScript(`(() => {+ const stage = document.querySelector('.stage');+ const footer = document.querySelector('footer');+ const header = document.querySelector('header');+ const stamp = document.querySelector('.art-stamp');+ return !stage || (stage.getBoundingClientRect().bottom < footer.getBoundingClientRect().top+ && header.getBoundingClientRect().right < stamp.getBoundingClientRect().left);+ })()`);+ assert.ok(layout, `${plate.name}: screenshot or heading overlaps its frame`);const capture = await win.webContents.capturePage();// Normalize Retina captures so export size is independent of the display.const frame = capture.resize({width:plate.width,height:plate.height,quality:'best'});