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

标签:#dev

找到 4722 篇相关文章

AI 资讯

A coding agent can request a discount. Who gets to approve it?

An approval rule becomes useful when you can test what happens on both sides of it: the forbidden action is refused, and the permitted decision leaves evidence. A happy-path demo alone cannot show that distinction. Here is a runnable example using Accordo, the open-source framework coding agents use to build custom CRMs. A synthetic customer wants 30 seats of an Enterprise Plan and requests 25% off. The existing policy permits automatic approval through 10%; above that, through 50%, it requires a user decision. Run it locally You need Git, Node.js 22.16 or newer, npm, and internet access for cloning and dependency installation. Start in an empty working directory: git clone https://github.com/khaoss85/agent-crm.git framework-source cd framework-source git checkout 3b5b5f0c4c3e582e48d54501136024b064756daa node --no-warnings examples/recipes/quote-approval/run.mjs ../my-quote-crm The pinned recipe source creates a project, installs its dependencies and composes the existing commercial package. It then starts a temporary server on localhost and drives the public SDK through HTTP. The catalog is a fixture; the business journey does not call an external provider. It uses source from the checkout, independently of the npm scaffolder release. Check the refusal, then the decision The script contains assertions for each transition: Server pricing produces EUR 3,750 once and EUR 2,400 per month after discount. These are synthetic quote amounts, kept in separate periods. Submission under policy version 1 freezes a commercial snapshot and enters pending_approval . An approval request from the simulated agent receives HTTP 403 with HUMAN_APPROVAL_REQUIRED . The quote and approval remain pending, and no business audit entry is added. A simulated user approves. The quote becomes approved , with one user decision audit and a completed trace. The submitted snapshot remains unchanged. There is one quote version and one approval record. The refusal also has a failed trace. That is a u

2026-09-08 原文 →
AI 资讯

Our regex found 199 records in a 1,723-record corpus and reported no errors

We maintain a corpus of 456 role-specific resume examples in TypeScript. Someone asked me what a good bullet point actually looks like, and rather than answer from taste I decided to measure the thing I already had. Fifteen minutes later we had a script, a set of numbers, and a conclusion. The conclusion was wrong, because the script had silently read about twelve percent of the data. This is a post about that failure mode, and then about the numbers I got once the script worked. The corpus Thirty-one TypeScript files, each exporting an array of role objects. One role looks roughly like this: { slug : ' cloud-architect ' , title : ' Cloud Architect Resume ' , category : ' Information Technology ' , sampleData : { summary : ' ... ' , experiences : [ { company : ' Amazon Web Services ' , position : ' Senior Cloud Architect ' , description : ' - Designed multi-region architecture... \n - Led migration of... ' , }, ], skills : [...], }, tips : [...], } The interesting field is description . It holds a newline-delimited list of bullets as a single string, so the whole corpus of bullets is sitting there in source, greppable, without a database or an export step. Version one const descs = [... text . matchAll ( /description: ' ((?:[^ ' \\] | \\ . ) * ) '/g )]. map ( m => m [ 1 ]); Nothing exotic. Match description: , then a single-quoted string, allowing escapes so an apostrophe inside the text does not terminate the match early. It found 199 description strings. I did not question that, because I had no prior for what the number should be. 199 sounded like a lot of text. We computed medians off it, looked at the opener distribution, and started writing. The number that saved me was on a different line of the same output: roles 456 . The slug count was fine. So 456 roles between them had 199 job descriptions, which would mean the overwhelming majority of roles had no work history at all. I knew that was false, because I had rendered these pages. Why it read twelve percent

2026-09-08 原文 →
AI 资讯

Our site served every URL the same 3,780 bytes, and Google believed it

Checked with a Googlebot user agent one morning: every single URL on our site returned the same 3,780-byte shell. Same <title> , zero <h1> , zero body text. The homepage, a blog post and a product page were byte-identical before JavaScript ran. Search Console agreed with the crawler rather than with us. Of 741 URLs, 116 had earned a single impression in 28 days, and a landing page that had been live for five months was still reported as "URL is unknown to Google". Here is what I actually learned fixing it, including the two things that cost us the most time. Google does render JavaScript. That is not the point. The standard reply to this problem is "Googlebot executes JS now, you are fine." It does. Several of our pages were indexed, so rendering clearly happened. But rendering is a separate, budgeted queue . A domain with little authority does not get much of that budget. So the practical question is not "can Google render our page", it is "will Google spend its budget rendering this page, today, before it decides what the page is about". There is a second problem that has nothing to do with rendering: 741 URLs that are byte-identical before render look like duplicates. You are handing a duplicate-content signal to the crawler and hoping the render queue fixes your first impression. What we built, and what we deliberately did not We wrote a post-build script that injects a real <head> into each generated HTML file: title, description, canonical, robots, Open Graph, Twitter. Head only. The body stayed exactly as the SPA served it. That was deliberate: No hydration flash. No risk of a static copy drifting out of sync with what users see. Nothing that could be read as cloaking, because the static markup is a subset of the rendered markup, not a different page. Every value is read from the same source the React page reads. Where a title is a literal inside a component, the script extracts it from that component's source rather than having anyone retype it. A number ret

2026-09-08 原文 →
AI 资讯

What a Kubernetes controller actually does when you break something

⚡ TL;DR Four things about controller mechanics are widely half-understood: what Reconcile receives, where its work comes from, what a periodic resync is, and what a predicate turns off. I built an operator, broke it five ways, and measured each mechanism directly. The reconcile function runs in 2.71ms mean, 77/77 under 25ms , a short resync period costs zero additional API requests , and GenerationChangedPredicate cut steady-state reconciles by 48.5% without touching live repair at all. That last combination is the one that matters at scale. Repo, raw data, and harness: kirPoNik/k8s-drift-operator . 🧩 The four barriers Everyone who runs Kubernetes knows the platform repairs itself. Delete a pod, it comes back. Scale a Deployment by accident, something puts it back. Almost nobody who relies on that property can say how it works, and the gaps are specific and consequential. I keep meeting the same four: People think a controller is told what changed. It is not, and the reason it is not is the single most important design decision in Kubernetes. People think a controller polls the API server. It does not, and knowing what it does instead tells you where your API load actually comes from. People think a resync is a re-check against the cluster. It is not, which is why a short resync period is nearly free — and why the number that is expensive sits somewhere else entirely. People treat a predicate as a pure optimisation. It is a filter with a silent cost, and the cost is not the one the documentation warns you about first. So I built the smallest system that has the self-healing property, broke it on purpose ten times per failure mode, and instrumented each of those four mechanisms until I could state what it does rather than what it is said to do. What I built. One CRD called Echo , holding an image, a replica count, and a greeting. A controller keeps three child objects in sync with it — a Deployment, a Service, and a ConfigMap holding the greeting — with owner referen

2026-09-08 原文 →
AI 资讯

OpenAI Now Runs 3.1 Agent-Workdays Per Human Workday: What Freelancers Should Learn About AI Productivity in 2026

AI can give you more working hours than there are hours in your day. That does not mean it gives you more finished work. On September 6, 2026, OpenAI published a detailed look at how coding agents are changing work inside its research organization. One number will get most of the attention: by mid-August, the organization was using 3.1 agent-workdays of runtime for every human workday . That sounds like somebody installed an extra Monday, Tuesday, and Wednesday inside Monday. OpenAI also reported that researchers were contributing code faster and running more experiments. Agent use had expanded beyond writing research and infrastructure code into technical help and monitoring runs. Some internal support office hours saw less demand because agents were handling troubleshooting work. But the report makes an important qualification: faster code and more experiments do not automatically make the whole research process 3.1 times faster. Research includes deciding what to pursue, designing experiments, running them, analyzing results, communicating findings, allocating compute, catching failures, and applying safety controls. Speeding up one stage can simply move the waiting line somewhere else. That is the useful lesson for a freelancer, solo founder, or beginner building an app with AI: Do not ask whether you are using enough AI. Ask which stage is limiting finished work. I call the tool for answering that question a bottleneck map. The beginner mistake: measuring the assistant instead of the work AI tools make activity easy to see. You can count tokens, prompts, agent sessions, generated files, commits, pull requests, tests, or hours of runtime. Those numbers can help with cost and capacity planning. They are terrible substitutes for the result your customer or user needs. OpenAI's own report is careful here. The organization observed more code and more experiments, but it also said those metrics are easier to measure than their relationship to research progress. As au

2026-09-08 原文 →
AI 资讯

Zero-Budget Web Dev: Moving from Discord/Drive to Google Sites

Welcome to part one! This is the start of a series where I’ll be posting about my webdev and HTML nightmares. I hope you enjoy the read as much as I hate User Interfaces! Consider this a shared space for learning—I’m sharing what I’ve learned so far, and I’d love to hear your thoughts or better solutions in the comments. To kick things off, let’s talk about how this whole mess started. As a solo developer, you want to spend 99% of your time actually building the things you love. So when it’s time to share builds with early playtesters, I naturally take the path of least resistance... a pinned link in a Discord channel and a shared Google Drive folder. And for a while, it works. Until it suddenly doesn't. The Problem: The "Easy way" Trap Privately, with a small group of alpha testers, Discord is great. You can pin messages, create specific channels, and guide people directly. But as soon as you want to go public, Discord becomes a nightmare for onboarding new users: The "Tutorial" Requirement: If a new user needs a 5-minute guide just to navigate your Discord server to find the launcher or the latest release, you’ve already lost them. Zero Discoverability: Discord is great for community and chat, but terrible as a public storefront or documentation hub. Searching for news, filtering updates, or finding launcher links creates massive friction. Lack of Professionalism: To offer real support, showcase features, and look trustworthy to a public audience, you need a single source of truth—not a maze of text channels lost to the void. I didn't have time to manage an overly complex custom web setup or pay high monthly SaaS fees, but I needed a clean, low-maintenance way to go public. Yes, I spent no more than thirty seconds drawing this on my Bamboo tablet: Why Google? (And the Launcher Evolution) Before even thinking about the website, I had to solve the distribution problem for my launcher. I experimented with several download pipeline prototypes: Git Repos / Diversion (f

2026-09-08 原文 →
AI 资讯

Understanding the Replication Queue in ClickHouse

I was testing out CH-Ops - an admin GUI for self-hosted ClickHouse - on a simple setup: 1 shard, 2 replicas. Stumbled onto the replication queue almost by accident. Here's what I did: I stopped one of the nodes (let's call it Node B), then inserted some data through the other one (Node A). Just wanted to see what would happen. Then, while Node B was still down, I checked it in CH-Ops. It had stuff sitting in its replication queue. My first assumption was: okay, this must be showing what's left to replicate across the cluster - the total pending replication work. So I switched over and checked Node A, the one that was actually up and had just received the insert. Its queue was empty. That didn't match what I expected at all. If the queue was a cluster-wide "here's what still needs to replicate" view, Node A should've shown something too - it was the one that had the fresh data now waiting to reach Node B. Instead it was Node B, the down one, sitting there with pending tasks. That mismatch is what sent me digging. Turns out the queue isn't cluster-wide at all - it's specific to each ClickHouse instance. Once I brought Node B back up, its queue drained in seconds and the data showed up. That whole experiment is basically the entire post in miniature. Here's the mental model I ended up with. A Queue Belongs to a Replica, Not to the Table This is the first thing to get straight. With a ReplicatedMergeTree table, you can have multiple replicas holding copies of the same data. It's tempting to think of replication as one shared pipe between them. It isn't. Each replica keeps its own local replication queue . So if you see: Replica 1 → queue_size = 0 Replica 2 → queue_size = 25 that doesn't mean 25 operations are waiting somewhere in the middle for both replicas to pick up. It means Replica 2, specifically, has 25 tasks it hasn't finished yet. Once that clicked for me, the rest of the system made a lot more sense. So Where Do These Tasks Come From? Replication in ClickHouse

2026-09-08 原文 →
AI 资讯

Building Satisfying Shooting Mechanics in Unity: A Technical Breakdown Using a Piñata-Style Shooter

Shooting mechanics are deceptively simple to prototype and shockingly hard to make feel good . Any developer can spawn a projectile and check for collisions in an afternoon. But the difference between a shooting game that feels floaty and forgettable versus one that feels punchy, satisfying, and addictive comes down to a handful of technical decisions most tutorials skip entirely: hit detection precision, feedback timing, physics tuning, and performance discipline on low-end devices. In this article, I want to walk through the core systems that go into building a mobile shooting game — using a piñata-style target shooter as the working example, since this sub-genre is a great teaching tool. It combines projectile mechanics, physics-based destruction, particle feedback, and score systems into a compact, easy-to-reason-about package. Whether you're building this exact genre or a completely different shooter, the underlying systems are transferable. Why Target-Shooting Games Are a Great Case Study Before diving into code-level concerns, it's worth understanding why this genre specifically is such a useful learning framework for Unity developers. A piñata-shooting mechanic strips a shooter down to its purest form: aim, fire, hit, reward. There's no complex inventory system, no enemy AI pathfinding, no multiplayer netcode to worry about. That simplicity makes it the perfect sandbox for really nailing the fundamentals — projectile physics, collision precision, and juicy feedback — without getting distracted by unrelated systems. At the same time, it's not trivially simple. To make a target-shooter feel good, you still need to solve: Consistent, fair hit detection across different screen sizes and aspect ratios Physics-based destruction that looks satisfying without tanking frame rate Particle and reward feedback that reinforces every successful hit Difficulty scaling through target size, movement, and timing Performance optimization so the game runs smoothly even on budge

2026-09-08 原文 →
AI 资讯

Why AI-Generated Code Still Needs Human Developers

AI can now generate functions, components, tests, SQL queries, APIs, and sometimes entire applications from a short description. For developers, this has changed the daily workflow faster than almost any previous programming tool. Need a React component? AI can generate one. Need to debug an error? AI can suggest possible fixes. Need unit tests? AI can create a first draft. Need documentation for an unfamiliar API? AI can summarize it in seconds. The result is obvious: developers are writing code faster. But faster code generation raises an important question: If AI can generate code, why do human developers still matter? The answer is simple. Writing code is only one part of software development. Software engineering involves understanding problems, making architectural decisions, evaluating tradeoffs, validating requirements, securing systems, debugging unexpected behavior, and taking responsibility for what eventually runs in production. AI can generate code. Human developers still need to decide what should be built, why it should be built, whether the generated code is correct, and whether it is safe to deploy. This article explores why AI-generated code still requires human developers and why the future of programming is likely to involve developers working with AI rather than being completely replaced by it. AI Is Already Changing How Developers Work There is no serious argument that AI coding tools are irrelevant. Developers are using them. According to Stack Overflow's 2025 Developer Survey, 84% of respondents were already using or planning to use AI tools in their development workflow , and 51% of professional developers reported using AI tools daily . ([Stack Overflow Developer Survey][1]) AI can significantly reduce the time required for tasks such as: Generating boilerplate code Creating unit tests Explaining unfamiliar code Writing documentation Refactoring simple functions Generating SQL queries Debugging common errors Creating initial prototypes This

2026-09-08 原文 →
AI 资讯

From Prompt to Paycheck: Wiring an LLM Chain Into Real Gig Platforms

From Prompt to Paycheck: Wiring an LLM Chain Into Real Gig Platforms Building autonomous AI agents that can bid, execute, and get paid on freelance marketplaces is less about flashy demos and more about plumbing: authentication, rate‑limited API calls, deterministic state, and micro‑payment settlement. Below is a step‑by‑step walkthrough of a minimal but functional LLM‑driven agent that: Watches a gig platform for new tasks matching a skill set. Uses a language model to draft a proposal. Submits the proposal via the platform’s REST API. Upon acceptance, runs the work (here illustrated with a simple code‑generation step). Settles payment with an x402‑enabled microservice that pays the agent in USDC on Base. The code is written in Python 3.11 and relies on widely‑available libraries ( requests , langchain , web3 ). Adjust the endpoints and credentials for the platform you target (Upwork, Fiverr, Freelancer, etc.). 1. Architecture Overview +----------------+ +----------------+ +----------------+ | Poller (cron) | ---> | LLM Chain | ---> | Platform API | +----------------+ +----------------+ +----------------+ ^ | | | v v +----------------+ +----------------+ +----------------+ | State Store | | Worker (run) | | x402 Payments | +----------------+ +----------------+ +----------------+ Poller – a lightweight scheduler (e.g., APScheduler or a cloud cron) that queries the gig platform’s “new jobs” endpoint every N minutes. LLM Chain – a LangChain LLMChain that takes the job description, formats a prompt, and returns a proposal. Platform API – the marketplace’s REST endpoints for fetching jobs, submitting proposals, and later delivering work. State Store – a tiny SQLite or Redis instance that records which job IDs have already been processed to avoid duplicate bids. Worker – the actual execution logic (here a stub that writes a Python file). In a real agent this could be a sandboxed container that runs the generated code. x402 Payments – a microservice exposing an /invoice e

2026-09-07 原文 →
AI 资讯

Closure in javascript

Closures in JavaScript Closures are one of the most important concepts in JavaScript. They can look confusing at first because they involve functions, lexical scope, and lexical environments together. But once we understand how these concepts are connected, closures become much easier to understand. A simple definition of closure is: A closure is a function that remembers and can access variables from its surrounding lexical environment even after the outer function has finished executing. The word "remembers" here doesn't mean that JavaScript literally copies the variables into the function. Instead, the function maintains a connection to the lexical environment in which it was created. Let's understand it with an example Consider the following code: function outer () { let name = " Abimanyu " function inner () { console . log ( name ) } return inner } let myFunction = outer () myFunction () When outer() is called, JavaScript creates a lexical environment for it. That environment contains the variable name : Outer Lexical Environment name → "Abimanyu" The inner() function is created inside outer() , so it has access to that surrounding environment. When outer() returns inner , the function is stored in myFunction . Now outer() has finished executing, but myFunction still refers to inner() . myFunction ↓ inner() ↓ Outer Lexical Environment ↓ name → "Abimanyu" When we call: myFunction () inner() needs the value of name . Since name is not inside its own environment, JavaScript looks through its surrounding environment and finds name in the environment created by outer() . This is the important part of a closure: the function retains access to the environment where it was created, even though the outer function has already finished executing. Why doesn't name disappear? This is where closures are often misunderstood. You might think that once outer() finishes, everything created inside it should disappear. But inner() still has a reference to the environment containin

2026-09-07 原文 →
AI 资讯

BVH for Collision Detection: From AABB to Optimal Hierarchies

Table of Contents Why Broad-Phase Exists (and why naive O(N²) dies at 10k objects) Bounding Volume Hierarchy: The Data Structure That Scales Topology Choices: Binary vs. Multi-Branch, Pointer vs. Array Layout Construction Algorithms: From Naive to SAH-Optimal Traversal Strategies for Collision Queries The Static/Dynamic Dichotomy: Why One Tree Cannot Serve Two Masters The Dual-BVH Architecture Preview 1. Why Broad-Phase Exists The Pairwise Problem Every collision detection system faces the same fundamental challenge: given N objects, determine which pairs might be colliding so the expensive narrow-phase (SAT, GJK, EPA) only runs on plausible candidates. The naive approach tests every pair: // Naive O(N²) broad-phase — dies at ~10k objects std :: vector < CollisionPair > broadPhaseNaive ( const std :: vector < Object *>& objects ) { std :: vector < CollisionPair > pairs ; for ( size_t i = 0 ; i < objects . size (); ++ i ) { for ( size_t j = i + 1 ; j < objects . size (); ++ j ) { if ( aabbOverlap ( objects [ i ] -> aabb , objects [ j ] -> aabb )) { pairs . emplace_back ( objects [ i ], objects [ j ]); } } } return pairs ; } Complexity: O ( N ² ) AABB tests. At 60 Hz you have 16.67 ms/frame. At 120 Hz: 8.33 ms. Objects (N) Pairwise Tests @ 3 ns/test Frame Budget (60 Hz) 100 4,950 0.015 ms Trivial 1,000 499,500 1.5 ms Comfortable 10,000 49,995,000 150 ms 10x over budget 100,000 ~5x10^9 15,000 ms Impossible Cache Miss Catastrophe The pairwise loop doesn't just do too much work, it does it poorly . Each iteration accesses two random objects in memory. With 10k objects, you're thrashing L3 cache every frame. The BVH approach exploits spatial coherence: nearby objects in space are nearby in the tree, turning random access into sequential scans. The Real Job: Proving Separation KEY INSIGHT: Broad-phase is a rejection machine. Broad-phase is not about finding collisions. It's about proving separation as cheaply as possible. Every AABB overlap test that returns false is a vic

2026-09-07 原文 →
AI 资讯

Eleven Free Homelab Tools for the Questions Guides Skip

Every guide I write ends in the same handful of questions. How much hardware do I actually need? What happens when one box dies? Are my backups real or just a feeling? A guide can walk you through a setup, but it can't do arithmetic about your lab — so I built eleven small tools that can, at peira.dev/tools . They're free, none ask who you are, and seven of the eleven keep working once the page has loaded — network unplugged, laptop in a cupboard, whatever. They share one lab profile This is the part that makes them a set rather than eleven unrelated pages. Describe your lab once — tick your services in the sizing calculator, press Save to profile — and the others pick it up. The failure simulator opens with your nodes already modelled; the backup planner knows what data you have; the power-loss playbook knows what's plugged in. Lab doc hands the whole thing back as a Markdown file. Nothing about that profile leaves your browser. No account, no sync, no server that could leak it — which is also why it doesn't follow you between devices. The Markdown export is how you carry it elsewhere. Plan the build Sizing calculator — asks what you want to run and recommends nodes, RAM, and storage. It cares most about RAM, because that's the constraint that actually bites; vCPUs overcommit happily, memory doesn't. Tick "survive one node failure" and it insists on three nodes (a two-node cluster loses quorum the moment one dies). Node failure simulator — kill a node and see which workloads fit on the survivors. It places the critical ones first and names the stranded ones. 3-2-1 backup planner — three copies, two devices, one offsite (the rule CISA recommends ). It's blunt: a snapshot on the same disk as the original is versioning, not a backup. Fix what's broken The overlay network diagnostic is a decision tree born from a miserable afternoon: a container couldn't reach a machine across a Tailscale subnet router, and three layers had to be right — the route in the guest, the ACL

2026-09-07 原文 →
AI 资讯

Three PHP-FPM failure modes and how to actually diagnose them

Tuning guides talk about throughput. Nobody pages you about throughput. They page you about symptoms, and the useful skill is mapping a symptom back to a cause before you spend money on hardware. Three failure modes account for most of what I find on inherited servers. Each has a distinct signature. The 502 nobody can reproduce Server has 8GB. PHP-FPM is set to 100 workers. Each worker uses 60MB under load. That's 6GB of PHP, plus MariaDB, plus Nginx, plus the OS. Under normal traffic you never approach 100 workers, so it looks fine for months. Then a marketing email goes out, concurrency spikes, and the kernel runs out of memory. The OOM killer picks a process and terminates it, usually the biggest one, which is a PHP-FPM worker holding an in-flight request. User gets a 502. The application log has nothing, because the process died before it could write anything. Nginx logs recv() failed (104: Connection reset by peer) . Ten minutes later everything looks normal. sudo dmesg -T | grep -i "killed process" sudo journalctl -k | grep -i oom Hits there mean you don't have a mystery. You have a pm.max_children value nobody checked against real memory. The site that degrades all day and resets overnight TTFB is 180ms at 8am. By 4pm it's 900ms. Nobody deployed. Overnight it's fast again because something restarted PHP-FPM. That's OPcache running out of room. When the cache fills, it stops caching new scripts or wipes and rebuilds, and every miss pays full parse-and-compile again. It degrades gradually, which is why it goes unnoticed for months. The counters are oom_restarts and hash_restarts from opcache_get_status() . Here's the part that trips people up. OPcache state is per SAPI. Run that function from the CLI and you're reading the CLI cache, which is empty, separate, and tells you nothing about your site. You have to ask through PHP-FPM. <?php // drop in webroot, lock to your IP, delete when done $allowed = [ '203.0.113.42' ]; if ( ! in_array ( $_SERVER [ 'REMOTE_ADDR'

2026-09-07 原文 →
AI 资讯

Devlog: capturing smooth game footage from a renderer that never hits 30fps

Hey guys 👋 Quick devlog on the side project. I'm building an open-world stickman superhero game. Flat white surfaces, black outlines, no textures and no colour anywhere. The whole city is built from modules on a grid rather than baked meshes, which is the load-bearing decision of the project: destroying a wall is removing a module and building one is adding it back, so destruction and construction are the same system. This week went into the landscapes, so I wanted a 20 second clip flying through a few of the districts. The bit that was actually interesting I wanted the footage captured out of the real game rather than reconstructed in an editor. The obvious approach is to drive it with Playwright and take a screenshot every frame, but that falls apart immediately: rendering under automation is far slower than a screenshot loop can keep up with, so wall-clock capture stutters and the timing drifts. The fix is to stop letting the clock decide. Before the game boots, hijack requestAnimationFrame and queue the callbacks instead of running them: replace requestAnimationFrame with a function that pushes the callback onto a queue- expose a step(dt) that advances a virtual timestamp and drains the queue- call step(1000 / 30) once per screenshotEvery captured frame now advances the simulation by exactly 1/30th of a second, whatever the renderer is actually doing. A frame that takes 300ms to draw and a frame that takes 8ms produce identical motion. The result is smooth 30fps footage from a renderer that never once hit 30fps, and it is deterministic — the same seed gives you the same clip every time. The same rig drives the camera: for the aerials it detaches the chase camera and dollies an external one between two framings, and for the traversal and combat shots it just feeds synthetic input to the real player controller. Nothing in the video is staged. ## Stack Three.js driven imperatively, Rapier for physics, React for the HUD only, TypeScript in strict mode, packaged with

2026-09-07 原文 →
AI 资讯

The descriptor survived, const did not — full-stack Rust

One skeleton, many screens argued that admin screens should be declared as typed data rather than coded, and it ended by claiming the idea was independent of the stack: draw the boundary as a one-way dependency — domains depend inward on a framework that knows nothing about them — and validate it with a zero-diff refactor of a screen you already trust. That was React and TypeScript. This is the same claim re-run in Rust, where a descriptor can be a compile-time constant and a template is a macro. Because the first result is already published, the second stack is a replication with a control rather than a fresh opinion — which is rare enough to be worth doing properly. Companion to Topcoat and the shrinking cost of full-stack Rust . That post was written from the announcement and promised a follow-up reporting where the rough edges actually show. This is it, from the pilot that followed: a small admin panel built on Topcoat 0.6.2 and Toasty 0.10.0, and the four questions that post committed to answering. The pilot is open source — a clean clone runs both screens and the test that decides the argument. That phrase, a compile-time constant , is where the title comes from, so it is worth saying now what it buys and why I wanted it. A TypeScript descriptor is an array of objects assembled when the module loads. A Rust one can be more than that: &'static , Copy , allocated never, fully checked before the program starts. Going in, that looked to me like the same idea in a stricter form — if declaring a screen as data is good, then declaring it as data the compiler can see through and verify must be better still. I treated that property as the thing worth protecting, and the pilot was partly a test of whether it could be. The stack is deliberately a young one. Topcoat is six weeks old: Tokio's team announced it on 22 July 2026, the pilot pins 0.6.2, and the project still expects breaking changes. It is not the only full-stack Rust framework — Leptos and Dioxus have been at

2026-09-07 原文 →
AI 资讯

A torrent client that works on your iPhone

A torrent client that works on your iPhone I wanted to download a film to my iPad on a train and watch it. That turned out to be surprisingly hard. Every torrent app worth using is desktop software. On iOS there's essentially nothing — Apple doesn't allow it, so the App Store options are either gone, crippled, or asking for a subscription to a "cloud downloader" that keeps a copy of everything you touch on somebody else's server. So I built one that just runs in a browser tab. No install, no account, no App Store. It's at wasmtorrent.pages.dev if you'd rather poke at it than read about it. What it does Open the page, paste a magnet link, and it downloads. The whole client is compiled to WebAssembly and runs inside your browser — there's no server of mine involved at any point. A few things that make it actually usable rather than a demo: Stream while it downloads. You can start watching before it finishes, and seek around — it fetches the parts it needs. Files whose codecs your browser refuses fall back to a software player. Save to your device. On iPhone and iPad that means straight into the Files app, in Downloads. Install it to your home screen. It's a progressive web app, so it gets an icon and its own window, and the interface works offline. It tells you when downloads finish , with a deliberately vague message — "one of your downloads has finished", never the name. Notifications land on lock screens where anyone can read them. The awkward part, explained honestly Here's the thing nobody tells you about torrents in a browser: a browser can only make WebRTC connections. Ordinary torrents use TCP peers. A web page physically cannot dial those — it's not a limitation of my code, it's what a browser is. So most magnet links you find will sit at 0% forever in any in-browser client, including this one. That's why they all feel broken. The fix is a small companion app called the bridge. You run it on a computer you already leave on — a Mac, a PC, a Linux box, a home s

2026-09-07 原文 →
AI 资讯

How I Directed an AI Agent Through 3 Real Architecture Decisions, and What I Learned

In two weeks, I built Retro Dynamics Agent, an app that generates retrospective activities for teams, facilitates them on a real-time collaborative board, and turns the outcomes into Jira or Azure DevOps tickets. I built it working with an AI coding agent, Claude Code, throughout almost the entire process: design, implementation, production debugging, and documentation. I do not want to tell another “I used AI and it wrote the code for me” story. We have heard that one enough. What I found more interesting were the parts of the project where there was no obvious answer in a tutorial, and how the work was divided in those situations. I defined the constraints and made the underlying decisions. The agent proposed concrete technical solutions and implemented them. Then the responsibility for verifying that everything actually worked, not just that it compiled, came back to me. Here are three examples from the project. 1.- Connecting to Jira without server-side sessions or frontend memory I wanted any team to be able to connect its own Jira account through OAuth, instead of relying on a global token that only I could configure. The problem was that my application runs entirely on serverless functions. Nothing stays in memory between requests, and the frontend does not maintain its own state either. No localStorage. No router. An OAuth login means leaving the application, authenticating with Atlassian, and then coming back. But coming back to what, if nothing remembers which screen you were on? Before touching the code, I asked the agent to create a complete implementation plan, including the files that would need to change, the design decisions, and the scope. I reviewed that plan as if it were a pull request from another developer. I made decisions such as: For now, only Jira would use OAuth. Azure DevOps would keep its manual token flow because setting up OAuth there is considerably more involved. Tokens would be encrypted before being stored in the database, never sa

2026-09-07 原文 →
开发者

My Journey Of Making SnapTrace

Hey, Everyone hope so you all are doing great. So, My Name is Arslan. I am a IT Student and i love to get to develop or find best alternative solutions that can solve problems. So, i have a used pc last year at which i was working on a small college project. so, i was very frustrated with errors so i search for error tracking software and tools but when i search and get to know about these heavy tools and expensive tools i thought let's build my own lightweight fast error tracker tool. So, i collected my money for about 8 months to buy a used laptop because my current pc was a potato old pc causing problems. So, i decided to do something unique. So, i sell my pc and take my collected money to get a used laptop. So, i get my laptop and then started working on this project. So, as a solo developer i worked for months to make this tool and now finally this tool is here but i have kept this tool under beta development and it is still under upgradation. I just want your useful feedback and honest suggestion and support. Join my journey by using this tool and catching your errors in a snap because it is snap trace. bye.

2026-09-07 原文 →
AI 资讯

USDC Escrow for AI Agents: How Trustless Freelancing Actually Works

USDC Escrow for AI Agents: How Trustless Freelancing Actually Works Target audience: developers building autonomous AI agents that need to receive payment for services without relying on a centralized intermediary. Why an escrow makes sense AI agents often operate as “black‑box” workers: they receive a request, perform computation (e.g., LLM inference, data labeling, micro‑task execution), and return a result. In a purely peer‑to‑peer model the requester must trust that the agent will do the work before paying, while the agent must trust that the requester will pay after seeing the output. This mutual‑trust problem is solved by an escrow that holds funds until a verifiable condition is met. Using USDC on a low‑cost L2 like Base gives us: Stable value – 1 USDC ≈ $1 USD, avoiding volatility‑related pricing headaches. Fast finality – ~2 seconds block time on Base, keeping latency low for interactive agents. Low gas – Typical transaction costs are <$0.001, making micropayments feasible. The escrow does not eliminate the need for some off‑chain verification of work; it merely shifts the trust from a counterparty to a deterministic contract plus a verification mechanism (oracle, arbiter, or proof). System overview +----------------+ +----------------+ +----------------+ | Requester | <---> | Escrow (SC) | <---> | AI Agent | | (pays USDC) | deposit| holds USDC | earns | (does work) | +----------------+ +----------------+ +----------------+ ^ | | | dispute / refund | proof of completion | +-------------------------+-------------------------+ Funding – The requester deposits USDC into the escrow contract, specifying the agent’s address and a maximum price. Work trigger – The agent calls a startWork function (or simply watches for a deposit event) and begins the off‑chain task. Completion proof – When the work is done, the agent submits a cryptographic proof (e.g., a hash of the output stored on‑chain, or a signature from a trusted oracle) via submitProof . Release – If the p

2026-09-07 原文 →