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

今日精选

HOT

最新资讯

共 21147 篇
第 115/1058 页
AI 资讯 Dev.to

Every engineering metric gets gamed. One of them structurally can't.

OrbitLens Ace → ace.orbitlens.io A busy quarter is easy to stage. Code that's still there in two years isn't. Pick any metric a team has ever used to judge people, and someone has quietly figured out how to move it without doing the underlying thing. Lines of code rewarded typing, so people typed. Commit counts rewarded committing, so commits got smaller and more frequent. Velocity rewarded closed points, and points drifted upward until a "3" meant nothing. DORA measured how often you deploy, so teams shipped trivial changes just to move it. Even churn — the number the "code health" tools lean on — is something you can lower on purpose, which means you can manage the number instead of the mess underneath it. None of that requires dishonest engineers. It's Goodhart's law doing what it always does. Every one of those numbers is a measure of activity , and activity is cheap to produce. Once you're paid for activity, the fastest way to get paid more is to produce more of it — not more of whatever the activity was supposed to be a sign of. So the question worth asking isn't which activity metric is least bad. It's whether a git history contains anything at all that you can't move just by being busier. It turns out there's one. And it's not because we were clever — it's because of what the thing is actually made of. What lasts isn't something you do Take everything a person wrote, wait a while, and ask a smaller question than "did they work hard." Ask whether the specific lines are still there. Not reverted, not rewritten, not quietly swallowed by someone else's refactor. Still holding weight at HEAD. That's survival. We read it with time-decayed git blame : a line's weight fades month by month unless the line keeps existing, and it counts for more once other people have built on top of it instead of leaving it as a private island. Survival that others have built on is what we call gravity — the structural pull that outlives the person who created it. Try to game it and w

machuz 2026-07-12 17:49 5 原文
AI 资讯 HackerNews

How does a Dev's job look like in a few years?

I'm a experienced/senior developer which is frequently using ai, guiding coding agents, etc. I wonder, how does my job look like in a few years? Which skills might be the best ones to have? Currently, having business knowledge, development experience helps greatly with guiding coding agents, creating MVPs/PoCs in "no time", improving code, etc. But what if coding agents/ai would overtake this job?

korrak 2026-07-12 17:39 2 原文
AI 资讯 Dev.to

The Physics of Bounded Rationality: Why AI Needs a "Cognitive Mechanics" Engine

@kungfufk Since the dawn of computing, we have built Artificial Intelligence on a flawed premise: perfect rationality. We brute-force algorithms to find the optimal solution, assuming infinite time and infinite capacity. But humans don't work like that. As Herbert Simon famously coined, we operate on Bounded Rationality. We make decisions based on limited time, limited cognitive capacity, and limited information. What if, instead of forcing AI to be perfectly rational, we created a mathematical equivalent for human processing? What if we modeled human cognition using the laws of physics — wave theory, thermodynamics, and mechanical energy equations — to build a heavy, complex, but highly probabilistic AI engine? Here is a blueprint for a new field of research: Computational Cognitive Mechanics . 1. The Core Equations of Cognitive Processing To model bounded rationality mathematically, we first need to define the relationship between Knowledge ($K$), Cognitive Capacity ($C$), and Processing Time ($T$). Based on human observation, we can establish these foundational proportions: Knowledge vs. Time — The more knowledge you possess, the faster you can generate a decision. $$T \propto \frac{1}{K}$$ Capacity vs. Time — High cognitive capacity (skills, processing power) inversely relates to the time required to solve a problem. $$T \propto \frac{1}{C}$$ Knowledge vs. Capacity — This is the most fascinating limit. Knowledge does not scale linearly with capacity. Gaining true knowledge requires exponential capacity (effort/skill). Therefore, knowledge is roughly proportional to the square root of capacity. $$K \propto \sqrt{C}$$ By integrating these, we can build a baseline processing algorithm for an AI. Instead of giving an AI unlimited time to compute, we cap its computing time based on a synthetic "Knowledge and Capacity" matrix, forcing it to use heuristics — just like a human. 2. Cognitive Wave Theory & FFT: Information as Interference In physics, waves interact throug

kungfufk 2026-07-12 17:37 4 原文
AI 资讯 Dev.to

Checkpoint-Skip Gate: Task Success 100%, Checkpoint Never Ran

Checkpoint-skip gate: a multi-agent pipeline can finish with task_success: true while the mandatory confirmation checkpoint never ran. checkpoint_skip_gate.py replays a recorded JSONL trajectory against a declarative spec of mandatory checkpoints and handoff contracts, offline, and blocks when the road was wrong. The verdict never consults the final metric. That is the point. AI disclosure: I wrote checkpoint_skip_gate.py with an AI assistant and ran it myself, offline, on Python 3.13.5, standard library only, no network. Every number, exit code, and hash in the output blocks below is pasted from a real local run. I ran each scenario twice to confirm STDOUT is byte-for-byte identical, and the tool prints a sha256 of its own report so you can reproduce the exact bytes. The Alberta write-up and the arXiv paper I cite are other people's work, attributed inline, and their numbers stay out of my fixtures. In short: task_success=true proves the pipeline arrived. It does not prove the mandatory steps happened, happened in order, or that each agent-to-agent handoff delivered what the next agent assumed. A trajectory can be perfectly green and structurally wrong. The gate replays a recorded trajectory against a spec you declare: checkpoints that must precede specific actions, plus contracts for each handoff (required fields, verified flags). The final metric is printed for contrast and ignored for the verdict. The demo that matters: two trajectories identical except one JSONL line, the confirm_with_user checkpoint event. Both end task_success: true . Delete that line and the verdict flips from PASS exit 0 to BLOCK exit 1 checkpoint-skipped . It also tracks unverified values across handoffs. A number that travelled a connected chain of two handoffs with no hop verifying it blocks as unverified-claim-propagated-2-hops . Everyone shared the number. Nobody verified it. Offline, keyless, zero network, fail-closed: broken input exits 2, never a silent green. The whole 8-fixture sw

Alexey Spinov 2026-07-12 17:35 6 原文
AI 资讯 Dev.to

Extracting Invoices From WhatsApp Photos With AI Vision (Apps Script + Google Sheets)

Every logistics and field-sales team runs the same expensive process: a driver photographs a receipt into a WhatsApp group, and a back-office clerk manually types the invoice number, total, and date into a spreadsheet. Hundreds of receipts a week = transcription errors and thousands of wasted hours. AI vision models kill that bottleneck. Here's the pipeline that turns a blurry field photo into clean structured data in seconds. Why vision models beat traditional OCR OCR reads characters. Modern vision models (Claude Vision, Gemini Vision, GPT-4 Vision) read structure — they distinguish a tax ID from a total, and a date from an amount, even on crumpled, angled, or poorly lit receipts. No brittle per-vendor parsers. The pipeline (3–8 seconds end to end) WhatsApp image → Apps Script doPost → forward to vision model → model returns JSON { InvoiceNumber, TotalAmount, VendorName, Date, Category, confidence_score } → confidence routing: > 90 → auto-append to ledger 70–90 → flag for human review < 70 → ask driver to re-photo → write row to Google Sheet (+ link to original image) → auto WhatsApp confirmation to driver The confidence_score is the whole trick — it's what stops bad extractions from silently polluting your ledger. Model selection (this drives your bill) Gemini Vision — cost-efficient default, strong multilingual OCR, great on clean receipts. Claude Vision — highest accuracy on degraded receipts; use for high-stakes flows. GPT-4o Vision — competitive, strong structured extraction. Pattern: Gemini for the first pass, escalate only low-confidence cases to Claude / GPT-4o. The economics ~500 receipts/week: vision API $10–40 + WhatsApp API $30–60 + Apps Script free = ~$40–100/month . Versus a clerk at ~25 hrs/week = $2,000–4,000/month in loaded labor. Per-receipt cost: $0.005–0.02 (compress images to ~1024px to cut it further). Accuracy: 92–97% on legible receipts, 75–85% on handwritten/damaged — hence the confidence routing. Pitfalls to avoid Auto-appending with no c

Hayrullah Kar 2026-07-12 17:33 5 原文
AI 资讯 Dev.to

Turning WhatsApp Into a Mobile ERP for Field Logistics (Apps Script + Google Sheets)

Field-service software has an adoption problem: drivers won't use it. Heavy app, another login, crashes in low-signal areas. So the "real-time" data still shows up as end-of-shift phone calls. The fix that actually sticks: stop building an app and use the one drivers already live in — WhatsApp. With Apps Script and Google Sheets behind it, WhatsApp becomes a frictionless mobile ERP. Here's the build. WhatsApp as a data-entry terminal A driver texts Status ABC-1234 Delivered . An Apps Script doPost webhook receives it, parses it, and updates the Sheet in real time. Latency goes from hours to milliseconds — and there's nothing to install, so adoption hits 90%+ in a week (vs. 50–70% for custom apps). Two-stage parsing for messy input Real drivers type "done," not clean commands. So: Regex first pass — handles ~70% of messages (clean format) instantly and for free. LLM fallback — the remaining ~30% goes to a cheap model (GPT-4o-mini / Gemini Flash) with the known cargo IDs and valid statuses. It returns normalized JSON + a confidence score. Below-threshold messages surface to a dispatcher. The LLM normalizes correctly 95%+ of the time (~5% manual), and it handles multilingual input with zero extra code. Driver msg → Apps Script doPost → regex pass → (fail) LLM fallback w/ confidence score → Sheet update (timestamp + raw-message log) → optional outbound (route change, POD photo request) Why Google Sheets is the right backend Dependent formulas: time-to-delivery, SLA-breach flags Pivot tables for reporting Apps Script triggers for automatic client emails Conditional formatting dashboards Native Calendar / Maps / Drive integration (POD photos → Drive folder) It runs on free Google Workspace infrastructure with minimal API cost. Bidirectional by default The same integration pushes messages back to drivers: route changes, delivery instructions, shift reminders, exception alerts, proof-of-delivery photo requests — all in the same thread. Pitfalls that get your number banned T

Hayrullah Kar 2026-07-12 17:32 3 原文
AI 资讯 Dev.to

Handling Lazy-Loaded Content in Automated Screenshots

You set up Puppeteer, navigate to a page, call page.screenshot() , and the bottom half of your image is blank placeholder boxes. Welcome to lazy loading. Most modern sites defer images and heavy content until the user scrolls. Your headless browser never scrolls. So those elements never load. Here's how to deal with it. The scroll trick The most common fix is to programmatically scroll down the page before taking the screenshot: async function scrollToBottom ( page ) { await page . evaluate ( async () => { const delay = ms => new Promise ( r => setTimeout ( r , ms )); const distance = 300 ; while ( window . scrollY + window . innerHeight < document . body . scrollHeight ) { window . scrollBy ( 0 , distance ); await delay ( 150 ); } window . scrollTo ( 0 , 0 ); }); } await page . goto ( " https://example.com " , { waitUntil : " networkidle2 " }); await scrollToBottom ( page ); await page . waitForTimeout ( 1000 ); await page . screenshot ({ fullPage : true }); The 150ms delay between scrolls gives IntersectionObserver -based lazy loaders time to trigger. Too fast and you'll scroll past elements before they start loading. That final waitForTimeout after scrolling back to top lets any remaining images finish rendering. Not elegant, but necessary. Why networkidle2 isn't enough You'd think waitUntil: "networkidle2" would handle this. It waits until there are no more than 2 network connections for 500ms. But lazy-loaded images haven't even been requested yet at that point — they're waiting for a scroll event that never happens. networkidle2 only helps with content that loads on page init. For scroll-triggered content, you need the scroll. The loading="eager" override Some sites use the native loading="lazy" attribute. You can override it before images load: await page . evaluateOnNewDocument (() => { Object . defineProperty ( HTMLImageElement . prototype , " loading " , { set : function ( val ) { this . setAttribute ( " loading " , " eager " ); }, get : function () { retu

Vitalii Holben 2026-07-12 17:24 3 原文
AI 资讯 Dev.to

BioTactix AI: Turning Soccer Fan Toxicity into Empathy with Real-Time Edge Analytics

This is a submission for Weekend Challenge: Passion Edition What I Built Soccer is defined by passion, but that passion often turns toxic when fans and commentators do not understand the limits of human performance under extreme pressure. During a 90-minute World Cup match, when a team collapses in the final ten minutes, the narrative defaults to harsh judgments like, "they lost their nerve." BioTactix AI was born out of a passion to change that global conversation. It is a securely licensed, real-time sports analytics architecture designed to solve the " Human-Machine Bottleneck. " By quantifying the exact intersection of physical exhaustion, cognitive delay, and psychological pressure, it transforms raw biological telemetry into context-aware, Explainable AI (XAI). Instead of relying on static dashboards, **BioTactix AI **provides real-time narratives to foster empathy among fans, actionable tactical alerts to prevent defensive collapses for coaches, and critical 14G-impact safety overrides for referees. Demo You can view the full demonstration and the real-time terminal output of the BioTactix AI Master Engine here: Watch the Demo on YouTube VIDEO LINK: https://www.youtube.com/watch?v=LQbuIVqc8D0 ** **Code The complete project, including the core biotactix_ai_master_engine.py script, is hosted publicly in github repository. The repository is fully secured with a software license to ensure the intellectual property and architectural blueprint remain protected. https://github.com/minakshihub/BioTactix-AI How I Built It Building a system to process 100-Hertz live biological data across a 40-man roster without compute bottlenecks required moving beyond standard web development approaches and leaning heavily into advanced storage systems engineering. Sovereign Edge Compute & VFS Routing: Instead of wasting CPU cycles continuously scanning the entire roster, the architecture leverages a custom Sovereign Virtual File System (VFS). This enables highly efficient data inge

Minakshi Aggarwal 2026-07-12 17:22 3 原文
AI 资讯 Dev.to

Building Accessible Popups Natively with the HTML5 Element

Many developers still rely on heavy, third-party JavaScript frameworks or external UI libraries just to create simple popups and modal windows. This introduces bloated bundle sizes, slows down page speed, and often ruins accessibility (a11y) for keyboard users and screen readers. Fortunately, you can build an accessible, highly interactive modal window completely natively using the modern HTML5 <dialog> element. The Code Setup Here is how simple it is to build a native modal with semantic HTML, minimal JavaScript, and a touch of modern CSS styling. 1. The Markup (index.html) <main> <h1> Native HTML5 Dialog Element </h1> <p> Click the button below to open a completely native, accessible popup modal. </p> <button id= "openModalBtn" > Open Modal Window </button> </main> <dialog id= "myModal" > <h2> Native Modal Title </h2> <p> This modal is rendered natively by the browser. Focus is trapped automatically! </p> <button id= "closeModalBtn" > Close Modal </button> </dialog> ### 2. The Logic (script.js) Instead of manually managing visibility states or toggle classes, the browser gives us built-in `.showModal()` and `.close()` methods: javascript const modal = document.getElementById('myModal'); const openBtn = document.getElementById('openModalBtn'); const closeBtn = document.getElementById('closeModalBtn'); openBtn.addEventListener('click', () => { modal.showModal(); }); closeBtn.addEventListener('click', () => { modal.close(); }); dialog ::backdrop { background-color : rgba ( 0 , 0 , 0 , 0.6 ); backdrop-filter : blur ( 4px ); } dialog { border : none ; border-radius : 8px ; padding : 2rem ; box-shadow : 0 4px 12px rgba ( 0 , 0 , 0 , 0.15 ); } Interactive Demos & Source Code Working Live Code Demo: ( https://codepen.io/editor/CoderDecoding/pen/019f5548-f0cb-75f8-b915-b9fdb33e92d1 ) Public Code Repository: ( https://github.com/CoderDecoding/native-dialog-demo )

Dedicated Coder 2026-07-12 17:20 5 原文
AI 资讯 Dev.to

I Love Fragrances, So I Built a 6-Game Arcade + Concierge About My Obsession

Hi, my name's Ibrahim, I'm a university student, and I have a problem: I love fragrances way more than my bank account loves me for it. It started small, the way these things always do. A cheap Middle Eastern attar someone gave me as a gift, the kind that costs less than a coffee but somehow smells like it belongs in a much fancier bottle. Then another. Then I started actually reading about notes, pyramids, accords, sillage, the whole rabbit hole. Fast forward through a lot of saved-up allowance and skipped nights out, and I've now got about 20 bottles on my shelf. Mostly affordable Middle Eastern gems (some of them genuinely punch way above their price), with a small handful of designer pieces I saved up for and treat like trophies. If you're a fellow fragrance enthusiast, you already know the feeling: you don't just "wear" a scent, you collect them, you study them, you have opinions about whether a note is top, heart, or base and you will absolutely fight someone about it. That obsession is basically the entire reason this project exists. So when I saw the DEV Weekend Challenge's "Passion" prompt, there was only one thing I could possibly build. What I built: recommendmeafragrance recommendmeafragrance is a browser arcade for fragrance nerds: six small daily games built around real perfume data (notes, brands, years, price tiers), plus an AI Concierge you can actually talk to about what you're in the mood for. Every game feeds into a personal "shelf" that tracks which fragrances you've discovered, plus streaks so you have a reason to come back tomorrow. Here's the tour. 🧪 Scentle: Wordle, but for your nose A new fragrance is picked every day (the same one for everyone, worldwide, no matter your timezone). You get 6 guesses, and after each one you get Wordle style feedback: was the brand exact or just the same house family, did the real answer come out earlier or later than your guess, is it pricier or cheaper, same gender, same concentration, how many notes do you

Ibrahim Awab 2026-07-12 17:12 4 原文
AI 资讯 Dev.to

Tokens and DAOs: The Real Technical Problems Behind On-Chain Communities

Tokens and DAOs are often presented as simple ideas: issue a token, distribute ownership, let the community vote, and build a decentralized organization. In reality, the technical problems behind tokens and DAOs are much deeper. A token is not only an asset, and a DAO is not only a voting system. Together, they create an economic, governance, security, and coordination layer that must work reliably in a hostile, open environment. The first major problem is token design. Many projects treat token creation as a deployment task, but the real challenge is defining what the token actually controls. Does it represent governance power, protocol revenue, access rights, reputation, staking weight, or all of these at once? When one token is used for too many purposes, the system becomes fragile. For example, a token designed for liquidity may not be suitable for governance, because the most active traders may not be the most aligned decision-makers. Good token architecture should separate economic utility, governance authority, and long-term reputation where possible. The second problem is distribution. A DAO can be decentralized in branding but centralized in practice if token ownership is concentrated among founders, investors, or early insiders. On-chain governance depends heavily on voting power, so distribution directly affects decision quality. Poor distribution creates governance capture, where a small group can control treasury spending, protocol upgrades, or parameter changes. This is not only a social issue; it is a technical design issue. Vesting contracts, delegation systems, quorum rules, voting delay, and proposal thresholds all influence whether governance is resilient or easily manipulated. Another core issue is governance security. DAO voting is not automatically safe just because it happens on-chain. Token voting can be attacked through flash loans, bribery markets, vote buying, low-participation proposals, and governance fatigue. If a malicious proposal pas

Hiren Kava 2026-07-12 17:10 3 原文