今日已更新 113 条资讯 | 累计 37664 条内容
关于我们

标签:#RAM

找到 2551 篇相关文章

AI 资讯

What a Claude Code subagent actually costs: measuring the ~436k-token fixed overhead

Spawning a subagent in Claude Code feels free. It isn't. We measured it across a real review pipeline, and the number that matters is one almost nobody talks about: each subagent costs roughly 436,000 tokens in fixed overhead before it does any useful work. This post explains where that number comes from, how to reproduce the measurement on your own setup, and what it changes about how you should split work between agents. The experiment We run a weekly review pipeline over a catalog of digital products (Markdown-heavy repos: rules files, skills, templates). The pipeline embeds each product's full content into a reviewer prompt and asks for structured findings. We ran the same product, same full content, two ways: Arm A: three subagents , one per review perspective (buyer value, niche accuracy, compliance). Total prompt size: ~314k characters. Arm B: one subagent covering all three perspectives in sequence. Total prompt size: ~105k characters. Billed token totals, from the session transcript: Arm A (3 agents) Arm B (1 agent) Total tokens 2,150,310 809,070 Distinct defect classes found 20 11 Primary-source fetches performed 0 2 Arm B cost 37.6% of Arm A. The naive expectation — "three agents read the same content, so about 3x" — roughly holds, but the reason is not the content. Where the tokens actually go Breaking the transcript down per turn, each agent carried about 436k tokens of overhead that had nothing to do with the review itself : the initial context load at spin-up plus the cache write on its final turn. The embedded product content — the thing we assumed dominated cost — was only about 46k tokens per agent. That's a 9.5:1 ratio of fixed cost to payload. Two consequences fall out immediately: Embedding full content is cheap. We had been truncating embedded files to save tokens, which quietly excluded the files that carried the product's actual value from review. Full-content embedding turned out to cost almost nothing relative to what we were already paying

2026-08-10 原文 →
AI 资讯

Stateless MCP With Compatible AI Gateways

With the stateless MCP spec now officially out as of July 28th, 2026, there are now two methods of connecting to and configuring an MCP Server. In this blog post, you'll learn what the stateless MCP spec means for the future, the breakdown of the spec, and how to implement it. 💡I wrote a "engineering details quickstart" for some of the other changes that came with the new spec as well, which you can find here. Stateless MCP Breakdown Two of the key changes in the 2026-07-28 change: removal of initialization handshakes and session IDs. An initialization handshake was the startup exchange used by MCP versions through 2025-11-25. Client sends an initialize request containing its protocol version, capabilities, and client information. Server returns an InitializeResult with the negotiated version, server capabilities, and server information. It could also return MCP-Session-Id Client sends notifications/initialized. Normal MCP requests begin. It established what features both sides supported before tools or resources were used. In MCP 2026-07-28 , this handshake was removed. Each request instead carries its protocol version and client metadata, making requests independently processable and stateless. Session IDs were also removed, as anything with a session ID is stateful, since that ID serves as a lookup key for data stored on a server or in a database. Example: If you log into Gmail and look at the devices that are logged into Gmail (your phone, laptop, etc.), the reason you don't need to continuously log into them/daily login is that a session exists for that device. Headers and Body Some headers must be in the body, and some headers that aren't. Standard HTTP headers (Content-Type, accept, Content-Length, etc.) don't need to be in the body. MCP headers that mirror requests, however, need to be in both the header and the body. MCP-Protocol-Version Mcp-Method Mcp-Name Mcp-Param-* Notice how in the example below you'll see the name, method, and protocol version are in

2026-08-10 原文 →
开发者

NETO: Chat P2P local para equipos dev sin depender de la nube

¿Tu equipo comparte tokens, contraseñas de staging o discute arquitectura sensible por Slack? Cada mensaje viaja a servidores de terceros. NETO es una alternativa radical: un chat peer-to-peer que funciona exclusivamente en tu red local, sin cuentas, sin nube, con cifrado de extremo a extremo. ¿Qué es NETO? NETO es una herramienta de mensajería diseñada para equipos de desarrollo que comparten la misma red. No hay servidor central, no hay registro, no hay datos que salgan de tu oficina o VPN. Abres la app y empiezas a hablar. ¿Cómo funciona por debajo? Descubrimiento con mDNS : NETO utiliza multicast DNS para encontrar automáticamente a otros peers en la red local. Sin configurar IPs ni puertos manualmente: si estás en la misma red, apareces. Cifrado con X25519 : Cada par de usuarios negocia claves efímeras mediante el

2026-08-10 原文 →
AI 资讯

Article: Comprehension as an Architectural Characteristic: A System That Is Not Understood Cannot Evolve Safely

As AI commoditizes code output, system comprehension silently decays, creating cognitive debt that threatens safe architectural evolution. This article explores why human understanding must be treated as an essential architectural characteristic, offering actionable strategies, socio-technical metrics, and design checkpoints to preserve intent across modern engineering teams. By Jacobus Meintjes, Narayana Rengaswamy, Paul Katsande, Sureshbabu Bikki

2026-08-10 原文 →
AI 资讯

Stratagems #24: Leo Built a Corridor. The AI Thought It Was a Road.

Between two great powers, when a neighbor presses you to follow, borrow its momentum. A cornered state will not believe your words. — The 36 Stratagems, Obtain safe passage to conquer the State of Guo Previously on this series: #10: Lena Watched a Team Adopt Her AI Template. Leo Didn't Know the Knife Was in the Contract. — Lena came to CoreStack as a consultant and built Leo's reporting template. Five weeks later the template went live and locked in six months of baseline data. Leo learned he'd been taken by a smile. #14: Leo Found an AI Leak. He Wasn't the First to Find It. — FinOptima was writing stolen training data back through its cache. Leo injected fifteen lines of weight drift. In the same logs he saw the name acl-train for the first time and filed it in his own _misc/ . #18: Leo Tracked an AI Signal to Derek. Both Were Looking for the Same Enemy. — Third Cup. An Americano sat on Derek's side. The private channel had been open since that night. #23: Alex Counted the AI's Hands. Lena Set the Bait. — The honeypot in the MediSys sandbox was touched twice by the same source, egress pointing at ACL's Singapore node. On the other side, Lena fed forged node-characteristic data into ACL's monitoring pipeline. Leo had run one interval comparison over the old channel. The conclusion was a single line, and it ended up in hands he didn't know. The Data The message arrived before dawn. The phone vibrated on the desk. Leo had just finished editing a block of code; the window was still on the editor. He didn't look right away; he waited for the build to finish, then picked up the phone. Last time, Derek had sent a few numbers and a comparison request: "Check this interval. Is it the pattern you know?" Leo replied with two words: send it. When the comparison was done, the conclusion stayed one line. Later that line went through other hands, source stripped, signature stripped. He never learned where it landed. Derek didn't say, and Leo didn't ask. This time was different. T

2026-08-10 原文 →
AI 资讯

Error Monitoring in Next.js 15 with Sentry What I Actually Track

error.tsx` catches a failure and shows the user something reasonable. It does not tell you the failure happened at all unless you are actively watching. For a while my "monitoring" was a client messaging me that something was broken, which is not monitoring, it is finding out from the worst possible source. Here is the Sentry setup I actually use now, tuned to catch what matters without burying it in noise. 1. The Setup bash npx @sentry/wizard@latest -i nextjs The wizard generates the config files and wraps next.config.ts automatically. Worth reviewing what it creates rather than trusting it blindly, since the defaults capture more than most projects actually need. `ts // sentry.client.config.ts import * as Sentry from '@sentry/nextjs'; Sentry.init({ dsn: process.env.NEXT_PUBLIC_SENTRY_DSN, tracesSampleRate: 0.1, environment: process.env.NODE_ENV, }); ` `ts // sentry.server.config.ts import * as Sentry from '@sentry/nextjs'; Sentry.init({ dsn: process.env.NEXT_PUBLIC_SENTRY_DSN, tracesSampleRate: 0.1, }); ` tracesSampleRate: 0.1 matters more than it looks like it should. Setting this to 1.0 captures full performance tracing on every single request, which sounds thorough and quickly becomes expensive and noisy once real traffic shows up. Ten percent is a reasonable starting point for most projects, adjustable once you see actual volume. 2. Connecting It to error.tsx This is the piece that is easy to miss. error.tsx handles the user-facing fallback, but nothing about it reports the error anywhere by default. `tsx // app/dashboard/error.tsx 'use client'; import * as Sentry from '@sentry/nextjs'; import { useEffect } from 'react'; export default function DashboardError({ error, reset, }: { error: Error & { digest?: string }; reset: () => void; }) { useEffect(() => { Sentry.captureException(error); }, [error]); return ( Something went wrong. Try again ); } ` Without this useEffect , the error boundary works perfectly from the user's perspective, and you never find out it

2026-08-10 原文 →
AI 资讯

PGConf.EU 2026 schedule is live 🐘

PGConf.EU is coming to Valencia on 20–22 October, with five tracks covering PostgreSQL administration, internals, development, the community, and real-world use cases. Topics include autovacuum, backups, high availability, performance tuning, WAL and recovery, query execution, memory management, corruption detection, and PostgreSQL 19. PostgreSQL also turns 30 this year, so the Community track will look back at the project’s history and how it is maintained today. Community Events Day takes place on 23 October. Schedule: https://www.postgresql.eu/events/pgconfeu2026/schedule/ Registration: https://2026.pgconf.eu/registration/ submitted by /u/pseudounion [link] [留言]

2026-08-10 原文 →
开发者

Beyond Senior - Creating Hope

Every time I leave a role I try and write up where my philosophy landed and what I want to take into my next role. Having seen this play out at enough companies over the years to where people progressively lose motivation and stop believing change is possible I've come to the opinion that one of the most valuable things we can do as engineering leaders is to provide hope. The post goes more into it, but I do not mean any vapid rah-rah motivational speeches, I mean earning back that hope every day by snowballing small wins into larger ones and making people believe that their effort matters. submitted by /u/keyslemur [link] [留言]

2026-08-10 原文 →
AI 资讯

HACKATHON ON CLIMATE & WELLBEING

Are you interested in leveraging AI, remote sensing, and data-driven solutions to tackle climate change and public health challenges? The Climate & Wellbeing Hackathon—hosted by Nims University Rajasthan and the World Health Summit Academic Alliance in collaboration with Khushi Baby—is officially open for registrations! 🎯 About the Hackathon Climate change directly impacts human, animal, and environmental health. Rising temperatures, extreme weather events, air pollution, and changing disease patterns pose severe threats to global wellbeing. This virtual hackathon bridges the gap between scientific research and field execution to create actionable policy guidance and real-world technology interventions. 🏆 Prizes & Recognition The Top 2 Innovative Ideas will receive The Dr. B.S. Tomar Innovation Award at the prestigious World Health Summit Academic Alliance - Expert Meeting on Climate & Wellbeing. 🛠️ Problem Statements & Tracks ☀️ Hazard: Heat Near-real-time heat-health burden nowcast (Public-health surveillance / Data fusion) Build an excess-illness/mortality index by fusing open environmental & proxy-demand signals to nowcast heat stress days ahead. Satellite rooftop heat-vulnerability classifier & cool-roof prioritisation engine (Climate adaptation / Remote sensing) Automatically identify and rank urban rooftops that urgently need cooling to produce an operational work-order. From action plans to living, tracked decisions (Climate-health governance / Decision-support) Develop a copilot to benchmark plans, operationalise daily actions, and monitor public feeds to map heat-health intervention gaps. Early heat-strain warning for outdoor & informal workers (Occupational health / Edge AI & sensing) Build a smartphone-based system estimating personal heat strain with local-language guidance and zero extra hardware. Heat-surge readiness for the health system (Operations research) Build decision-support tools to help health systems prepare ahead of forecast heat spikes. 🌬

2026-08-10 原文 →
AI 资讯

Looking for recommendations for similar sorts of content! (live-coding)

Hi guys! Don't post on Reddit very often, but nice to meet y'all. I'll get to the point. It's been a little more than a year since I graduated from college with a major in Computer Science, and even allowing for how little I learned during those four years (which is another conversation), I've recently become painfully aware of how little I know about writing decent code, managing a codebase, using technology effectively, and understanding tech (on any of its levels of abstractions). I've been trying to get back into coding, long-term I'm interested in becoming a Forward Deployed Engineer, but for now I'm focused on re-building a solid base, learning in-time and building interesting things, but I feel like I have a lot of habits to unlearn. Finding teachers and real-life mentors, while ideal, is expensive, and I am interested in finding online examples to guide me through this phase of my life. I experimented with vibe-coding / agentic coding, but I found my fundamentals too shaky to be able to extract a lot of value there, and personally I just value having all that information within my own neural networks, so to speak. A cool role model for me recently has been ThePrimeagen, who recently released a (live-coded speed-run of his Networking Course) [ https://www.youtube.com/watch?v=FknTw9bJsXM&t=1653s\ ], and it made me realize that watching people far better than me helps me set a mental expectation for what I'm trying to do, removes a number of self-limiting beliefs, and shows me how people think through their process as they build. Do people have any recommendations for similar styles of content — not 'tutorials' per se, but people who are just good at what they do, working on their personal setup and building things. Don't really know if there's a culture of live-coding, or where this genre of content might exist on the internet (programming competitions?). I am aware of how humongous the field is, but I'm open to anything that feels challenging, brain-stretchin

2026-08-10 原文 →
AI 资讯

Pattern Recognition: The Matrix Mindset for Top Coders

The Quest Begins (The "Why") I was staring at a pull request that felt like a boss level in a retro arcade game—except there were no extra lives. The code was a massive if/else if/else chain that decided how to handle different JSON payloads coming from a third‑party API. Each branch did almost the same thing: validate a few fields, map them to our internal model, then call a service. The only thing that changed was the shape of the incoming object. Every time a new endpoint was added, a developer had to copy‑paste the whole block, tweak a few field names, and pray they didn’t miss a comma. Reviewing it felt like watching someone try to solve a Rubik’s cube by rotating random faces—you could get lucky, but most of the time you just made a bigger mess. I kept asking myself: Why are we writing the same logic over and over? The answer was hiding in plain sight: we weren’t seeing the pattern. The Revelation (The Insight) The breakthrough hit me while I was refactoring a tiny utility that turned a list of user IDs into a set. I realized I wasn’t writing a new algorithm each time—I was applying the same shape of solution: take an input, transform it, then feed it to a consistent consumer . In other words, the problem wasn’t “how do I handle payload X?” It was “how do I dispatch the right transformation based on a key?” That’s a classic dispatch table (or strategy pattern) problem. The “aha!” moment was when I looked at the chain and saw that each branch could be expressed as a function: function handleOrder ( payload ) { /* … */ } function handleRefund ( payload ) { /* … */ } function handleShipment ( payload ) { /* … */ } All of them shared the same signature: (payload) => Result . If I could map a discriminator (like payload.type ) to the correct function, the whole if/else monster would collapse into a single lookup. That’s the pattern top coders spot instantly: repetitive conditional logic → a table of behaviors . Once you see it, the code writes itself. Wielding the

2026-08-10 原文 →
AI 资讯

Async-First Doesn’t Mean Async-Only

Key Takeaways Asynchronous discussions can lose momentum because participants are focused on different tasks. For complex or important topics, it’s often better to switch to synchronous communication. At least in my experience working in a Japanese-speaking organization, AI-generated messages are often still too verbose to send as-is. As writing becomes cheaper, it’s even more important to reduce the cognitive load on readers. Async-first does not mean async-only. Keeping written records while introducing short meetings when necessary can reduce the overall cost of communication. Context I currently work from Vancouver, Canada, for a fully remote and fully flexible organization based in Japan. Since everyone works on their own schedule, much of our day-to-day communication, decision-making, and discussion happens asynchronously. There are many benefits to this way of working. People can think at their own pace, and discussions naturally leave a written record. As someone who is fairly introverted, I also appreciate having time to think through my ideas before sharing them. Recently, however, I’ve started to realize that keeping every discussion asynchronous is not always the most efficient approach. Complex discussions are expensive to read When discussing multiple options, I usually start by sharing my recommendation, then document the reasoning behind it and the pros and cons of alternative approaches. The more complicated the topic becomes, the longer the document becomes. Writing requires effort, but so does reading. Someone has to understand the background, process the trade-offs, form an opinion, and respond. Lately, I’ve become more aware of the reader’s cost than the writer’s. In our company, Japanese is the shared language, and much of our written communication is now assisted by AI. While AI makes it easier to produce long documents, the resulting text can still be unnecessarily verbose or difficult to follow. AI makes writing cheaper. It does not necessar

2026-08-10 原文 →
AI 资讯

Topic selected: Option A – Purely Technical: "Building a Secure AI Proxy for Browser Tools

This is the strongest choice. It teaches a tangible, highly demanded skill (API key security) with actual code, making the backlink to AfriWidget feel like a natural, neutral citation rather than a sales pitch. Here is the article, rewritten to be strictly technical, objective, and genuinely useful for dev.to readers. Stop Exposing Your AI API Keys: Build a Secure Proxy with Cloudflare Workers We have all seen it. You open the browser's DevTools on a "cutting-edge" AI startup's landing page, check the Network tab, and find a direct POST request to api.openai.com containing a plaintext API key in the headers. It is one of the most common—and dangerous—mistakes in modern web development. Exposing your LLM API key client-side is an open invitation for abuse, leading to stolen credits, hefty bills, and potential account suspension. The standard solution is the Backend-for-Frontend (BFF) proxy pattern. But how do you implement it practically, cheaply, and securely without spinning up a heavy Express server? In this guide, I will walk you through building a lightweight, serverless AI proxy using Cloudflare Workers to securely call Groq (or OpenAI) APIs from your browser-based calculators and tools. The Architecture: How It Works Instead of your frontend talking directly to the AI provider, we introduce a stateless middleware layer: Browser App → Cloudflare Worker (Proxy) → Groq/OpenAI API ↑ ↑ (No API Key) (API Key stored securely in Worker env vars) The Worker's responsibilities: Receive the sanitized calculation context from the frontend (numbers, not PII). Attach the secret API key via environment variables. Forward the request to the LLM provider. Stream or return the generated insight back to the client. Step 1: Scaffolding the Cloudflare Worker We will use the new create-cloudflare CLI. Make sure you have Node.js installed. npm create cloudflare@latest ai-proxy Choose "Hello World" worker and TypeScript. Once inside the directory, install the Groq SDK: npm install gr

2026-08-10 原文 →
AI 资讯

The Day Our Web App Took 8 Seconds to Load (and How We Cut It in Half)

There is a quiet moment of panic every developer knows. You hit deploy, open the live site on your phone, and wait. One second. Two seconds. Four seconds. Still a blank white screen. A while back, I was working on a Next JS application that looked fast on high speed office Wi Fi. But when tested on a spotty mobile connection, it felt painfully slow. The initial page load was clocking in at nearly 8 seconds, and our main JavaScript bundle was a bloated 1.8 megabytes. Here is how we diagnosed the bloat, cut our load times by 47 percent, and the simple performance rules every developer should know. The Investigation: Where Was the Weight Coming From? When a website is slow, our first instinct is often to blame slow backend APIs or heavy database queries. But when I ran a performance audit, the backend was not the problem at all. The front door was just jammed with too much stuff. We were making three classic mistakes: First, we were packing for a long trip on a short walk. We were loading heavy charting libraries, complex admin tables, and pop up modals the second a user landed on the home page, even if that user only came to read a single line of text. Second, giant images were being served to tiny mobile screens, hogging precious bandwidth before any interactive buttons could even load. Third, a single state update at the top of our app was causing dozens of unseen child components to recalculate and re render unnecessarily behind the scenes. The Strategy: Trimming the Fat Instead of rewriting the entire codebase from scratch, we focused on three targeted fixes. 1. Don't Load It Until They Ask For It Why force a user to download a complex analytics chart if they have not even clicked on the dashboard tab yet? We split the app into smaller, independent code chunks. Now, the user downloads only the absolute bare minimum needed to view the immediate screen. The heavy features stay on the server until the exact moment the user interacts with them. 2. Smart Asset Delivery

2026-08-09 原文 →
AI 资讯

Writing terabytes to disk in Go: Stopping the OS Page Cache from eating all your RAM (FADV_DONTNEED)

Hello everyone! This is the second article about the development of RUSEON-core, a Zero-Copy video streaming server for AI platforms and Edge video infrastructure. In the first article , I talked about the fundamental reason why we decided to create our own server in the first place. I also covered the main problem with most similar solutions — the "thundering herd" — and how we managed to squeeze out 8 Gbps on a single CPU core. By the way, I forgot to mention in that article that besides simple streaming, we also record the streams in fMP4 format. It’s stored locally for N amount of time, and it can fly off to an S3 bucket (depending on how long the clients want to keep the recordings). This article is precisely about a non-obvious (well, at least to me, maybe for someone else it's an everyday thing) problem related to data storage and its specifics across all Operating Systems. So, let's dive in. We rolled out our first release to production (100 cameras), made the clients happy, and started working. About an hour passed, and the alerts started flying. I SSH into the server, open htop, and see there's only 100 MB of free RAM. Uh-oh. I should clarify that the production server had 32 gigs of RAM. The expected behavior was that the CPU is chilling, the network card is chewing through the traffic, RAM usage is around 250-300 MB, and the disks are not heavily loaded. So, when you see numbers like that in htop, you start blaming yourself and your crooked hands that wrote this piece of "garbage". But still, we decided to go to Google, ChatGPT, and the like. Fortunately, the answer was found quickly, and we stopped beating ourselves up. The code was absolutely not the culprit; Linux itself ate the memory. If you've ever written tons of data to a disk, I think you already know what’s going on. There is an "invisible enemy" known as the Page Cache. That was exactly the root of this problem. How does the Page Cache work and what to do with it? When your function that is su

2026-08-09 原文 →