Painel de Notícias

Tecnologia

7045 posts · 26 feeds · tópicos e interesse por Jev

Filtros
dev.to

4 Ways to Safely Refactor AWS CDK Code Without Resource Replacement

In AWS CDK, refactoring such as extracting resource definitions into a custom construct can cause resources to be replaced at deployment time — that is, deleted and recreated. For stateful resources, this means the data they held is lost. In this article, I will introduce four ways to refactor safely without triggering this replacement. NOTE: This article is based on AWS CDK (aws-cdk-lib) v2.263.0 and AWS CDK CLI (aws-cdk) v2.1139.0. To use the cdk refactor and cdk orphan commands introduced here, not only the CDK CLI but also the bootstrap stack must support both commands. If these commands result in an error, update the CDK CLI and then re-run cdk bootstrap to update the bootstrap stack. Let's start with the mechanism by which refactoring causes resource replacement. When you define a resource in AWS CDK, you write something like new Queue(this, 'Queue'), passing the parent construct as the first argument and a string called the construct ID as the second. The first argument is usually this, which points to the stack or construct being defined. The construct ID is a string that identifies a construct among those under the same parent. The hierarchy in which constructs are connected as parents and children, with the App at the top, is called the construct tree, and a position in the tree is represented by a path such as MyStack/Queue, formed by joining the construct IDs from the parent down. Now let's look at an example where replacement actually occurs. Consider the following code, which defines three resources directly under the stack: an Amazon SQS queue, an Amazon SNS topic, and an AWS Lambda function. The queue holds notification messages waiting to be processed, and deleting it would affect the running system. The topic, on the other hand, is a stateless resource, and we will assume its replacement is acceptable. Note that Code.fromAsset, which specifies the Lambda function code, deploys the contents of the local lambda directory as the function code. export

InfraDev
Interesse
dev.to

Propagating Deadlines from VIN Form Submit to NHTSA Proxy Without Orphaned Work

A free VIN form that abandons a slow decode still often leaves a DecodeVinValues call running behind the proxy. The user navigated away, a client timeout fired, or a newer submit superseded the old one -- yet the edge kept waiting on NHTSA and burned quota on a response nobody will display. Per-request budgets (covered elsewhere) decide how long a serverless handler may wait. This post is about propagating that deadline as an AbortSignal from form submit through your BFF so orphaned upstream work is cancelled early. The goal is narrow: one submit, one deadline, one cancellable fetch chain. Do not confuse this with hedged dual-fire, idempotency keys, or jittered retries. Here the job is: when the UI no longer wants the result, stop waiting on the proxy path that would call NHTSA. Orphans appear when deadlines live only at one layer: Browser AbortController aborts the BFF fetch, but the BFF ignores req.signal and keeps calling DecodeVinValues BFF has a hard setTimeout that returns 504 to the client while the outbound NHTSA promise is still pending A second form submit starts a new decode without aborting the first in-flight attempt Serverless budgets shrink remaining time, but nobody wires that remaining budget into fetch(..., { signal }) Each case spends free-quota units on work the card will never show. Propagation means the same abort reason travels from submit handler to outbound proxy call. Create the controller when the user submits (or when the form auto-decodes once). Attach a wall-clock deadline, pass signal to your BFF, and abort on unmount, navigation, or superseding submit. export type DecodeSubmitOpts = { vin: string; deadlineMs: number; // e.g. 8_000 from UX budget fetchProxy: (vin: string, signal: AbortSignal) => Promise ; }; export function submitDecodeWithDeadline( opts: DecodeSubmitOpts, ): { promise: Promise ; abort: (reason?: unknown) => void } { const ctrl = new AbortController(); const timer = setTimeout(() => { ctrl.abort(new Error("CLIENT_DEADL

Dev
Interesse
dev.to

AI Meeting Transcription in 2025: What Actually Works

AI meeting transcription has evolved at a breakneck pace over the past few years. By 2025, the landscape is both more impressive and more complex than ever. Developers and teams are faced with a dizzying array of solutions that promise to record, transcribe, and summarize meetings with minimal effort. But which tools actually deliver on accuracy, speaker diarization, and real-time performance? Let’s dig into the state of AI meeting transcription, demystify the technology, and compare real-world results so you can choose the right approach for your workflow. Remote work and hybrid meetings are now the norm. Teams distributed across time zones need reliable records of what was said, who said it, and what action items were decided. Manual note-taking is imprecise and time-consuming. Automatic transcription has become essential, driving demand for robust meeting transcription apps capable of handling everything from quick standups to multi-hour board meetings. There are several core features that determine whether an AI transcription solution is truly effective: Accuracy: How well does it transcribe diverse accents, jargon, and noisy environments? Speaker Diarization: Can it reliably distinguish between speakers, even in crosstalk or interruptions? Real-Time Capabilities: Does it provide live captions and instant search, or is there a delay? Integrations: How easily does it fit into your existing tools and workflows? Let’s break down each of these elements, with a focus on the current state of the art. At the heart of any meeting transcription app is automatic speech recognition (ASR). In 2025, most leading solutions leverage large, transformer-based models like OpenAI’s Whisper, Google’s Speech-to-Text API, or proprietary models from major cloud providers. These systems have improved dramatically in the following areas: Multi-language support: Models can now handle 50+ languages in real time. Domain adaptation: Custom vocabulary and fine-tuning for specific industries

IA
Interesse
dev.to

How AI Is Making Restaurant Menus Easier to Navigate

Navigating restaurant menus has always been a blend of excitement and challenge. Whether you’re searching for healthier options, trying to manage allergies, or just curious about what’s popular, the sheer variety and information overload can make ordering a daunting process. Thanks to advances in AI food tech, restaurants and diners alike are experiencing a transformation in how menus are presented, interpreted, and interacted with. AI menu analysis is reshaping everything from calorie estimation to personalized recommendations, bringing the concept of the smart menu to life. Modern diners expect more transparency and personalization than ever. They want to know not only what a dish contains, but also how it aligns with their dietary preferences, nutrition goals, and even their taste profile. Traditional menus—whether physical or static digital lists—struggle to keep up with these demands. Restaurants, on the other hand, are pressed to supply accurate restaurant nutrition data, cater to diverse dietary restrictions, and continually update offerings. This environment is ripe for disruption, and AI-powered solutions are stepping up to the plate. AI menu analysis refers to the application of machine learning and natural language processing (NLP) to interpret, enrich, and present menu data in more meaningful ways. It often involves: Parsing menu descriptions to identify ingredients, allergens, and preparation methods Estimating nutritional information where it isn’t provided Mapping dishes to dietary categories (vegan, keto, gluten-free, etc.) Ranking or recommending menu items personalized to the user Let’s break down some of these capabilities and see how they work under the hood. Menus often use creative language—think “golden-fried” instead of “deep-fried,” or “artisan cheese blend” instead of listing specific cheeses. AI models trained on food terminology can parse these descriptions, identify probable ingredients, and flag potential allergens. For example, a simpl

IA
Interesse
dev.to

The Complete Guide to SVG Icon Optimization for Web Performance

SVG icons have become the gold standard for web interfaces, offering crisp, infinitely scalable graphics that look sharp on any device. But not all SVGs are created equal—poorly optimized SVG icons can bloat your web pages, slow down rendering, and undermine the very performance benefits they promise. Let’s dive deep into SVG optimization for web performance, exploring how to reduce file sizes, improve rendering speed, and deliver pixel-perfect icons your users will love. SVG (Scalable Vector Graphics) is a markup language for describing two-dimensional graphics. Unlike raster images (like PNGs or JPEGs), SVGs scale cleanly at any resolution and are easily manipulated via CSS and JavaScript. However, SVG files can become inefficient due to: Editor-generated metadata and redundancies (especially from design tools) Unnecessary precision in coordinates or colors Embedding styles or scripts that aren’t used Unoptimized paths and shapes Just as you’d compress images or minify JavaScript, optimizing SVG icons is crucial for web performance. Smaller, cleaner SVGs mean: Faster page loads and lower bandwidth usage Speedier rendering, especially on resource-constrained devices Reduced main-thread work and improved interactivity Let’s break down how to optimize SVGs at every step, from creation to delivery. The best SVG icons are simple by design. Complexity in the artwork translates directly to more nodes, longer paths, and heavier files. When designing icons: Use as few elements and shapes as possible Avoid unnecessary groups ( tags) and nested structures Merge overlapping paths where feasible Tip: If you’re working in Figma, Illustrator, or similar tools, use “flatten” or “union” operations to combine shapes before exporting. Design tools often export SVGs with a lot of extra metadata: comments, hidden layers, unused definitions, and proprietary tags. This extra code does nothing for rendering and only slows things down. Before: ... Icon Title Some description After: Strip

Dev
Interesse
dev.to

The Ledger Committed. Webhook Delivery Is Unconfirmed. What Should Retry?

This article is a contribution from the A2VANTA engineering team. You read a committed payout reservation in the ledger, but you cannot confirm webhook delivery. Retrying the payout command would ask the service to perform a financial operation. Retrying the notification would ask it to send a saved event. An integration needs to distinguish those requests before choosing its recovery action. In the payout creation branch examined here, the service stages the reservation journal and notification event in one local database transaction. After commit, a delivery worker can send the saved event. Its recovery path handles delivery records without calling ledger posting again. A lost response can leave the sender uncertain even after the recipient accepted the request. The merchant ledger records accounting operations as journals with debit and credit lines. The pay-in posting template uses integer atomic units and checks that debit and credit totals agree. That arithmetic check alone cannot establish the economic correctness of an operation. For a payout reservation, the service moves the amount from available to reserved accounting state. It stages the journal and its lines in the caller's database session, then flushes them to obtain identifiers. A flush writes within the transaction; the caller still controls the commit. The creation branch then stages a payout.created event in the same session. Event enqueue also flushes without committing. The caller commits after both stages. This description concerns the inspected branch without opening an additional fiat order, with event persistence enabled. That shared commit records the reservation and the intention to notify. The recipient's HTTP exchange falls outside this transaction. You can inspect a committed event before any successful delivery acknowledgement exists. Configuration affects which records you should expect. Event persistence must be enabled to save the event. Creating a pending delivery also requires ena

Dev
Interesse
dev.to

Hello World 👋 My Journey & Tech Stack as a Full Stack Software Engineer

Hello everyone! Whether you are a fellow developer, tech enthusiast, or potential collaborator, welcome! 🎥 Watch the full video introduction here: My Introduction as a Full Stack Software Engineer Below is an overview of my educational background, core tech stack, and experience building end-to-end SaaS applications. 🎓 Background & Education My formal education in computer science includes: Bachelor of Computer Applications (BCA) Master of Computer Applications (MCA) These foundations gave me a solid grasp of software architecture, algorithms, and database design, allowing me to build robust, scalable applications from scratch. 💻 Core Programming Languages PHP — Robust backend logic and rapid API development 🛠️ Frameworks & Architecture Backend Laravel (Primary Expertise): My go-to framework for crafting clean, maintainable MVC applications, robust APIs, and scalable architectures. Yii & CodeIgniter: Solid experience building and maintaining legacy or lightweight PHP applications. Django: Utilized for Python-driven backends and secure, rapid API creation. Frontend Alpine.js: Lightweight reactivity when a full framework isn't required. React & Vue.js: My go-to tools for single-page applications (SPAs), reactive components, and state management. jQuery: For legacy applications or websites 🔌 Third-Party Integrations & SaaS Engineering Stripe — Secure payment gateways, subscriptions, and webhooks 🤝 Let's Connect & Build Drop a comment below or on my YouTube Channel. fullstackhardev.com

Dev
Interesse
dev.to

Can Testers Use an Emulator for Closed Testing?

Sooner or later every developer stuck at 9 or 10 testers has the same idea. Android Studio can run as many virtual phones as your laptop can handle, and each one can sign in to a Google account. Why not fill the last few slots that way? It's a fair question, and the honest answer has two parts: what the emulator can technically do, and what it does to your chances when you apply for production. What an emulator can actually do Images without Google Play, such as the plain Google APIs or AOSP ones, can't do that. You can sideload an APK onto them for your own debugging, but that install doesn't go through Play and has nothing to do with your closed test. So a tester who has no Android phone but uses Android Studio on a computer can, in principle, take part. That's the narrow case where an emulator is a reasonable answer. Keep in mind what the emulator can't show you. It runs on your computer's processor and memory, so performance, battery use, camera behaviour and some sensors look different from a real phone. Bugs that only appear on a specific manufacturer's Android version won't show up either. Why it's a risky way to reach 12 The bigger problem is what you'd be doing. One person running several emulators with several Google accounts isn't testing with real users; it's manufacturing them. Google Play's policies are strict about fake engagement and about the accounts behind it, and the downside of getting that wrong is much worse than two more weeks of recruiting. Even if nothing is flagged, you still have to apply for production. Play Console asks how you recruited testers, how they used the app and what you changed based on their feedback. Emulators don't give feedback, so you end up with weaker answers at exactly the moment they matter. Where emulators do help Play Console's pre-launch report is also worth a look. When you upload a build, Google can run it automatically on a set of test devices and report crashes and accessibility issues. It doesn't count toward

MobileDev
Interesse
dev.to

FAQ: A Free Server Is Not Your Review App

You cloned an agent repo earlier this week. Did that green demo become a real review app? I keep seeing that leap in pipeline reviews. A README and a free route get mashed together. A free server option gets pulled into that same mash. That mash is a story, not pipeline evidence. This FAQ splits those claims into separate layers. I will not invent quotas, hardware, or uptime numbers. If today's docs omit a figure, I omit it too. Agent demos are fast, and review apps are slow. A teammate pastes a chat screenshot into the thread. Someone then asks why the merge request lacks a URL. Those two systems do not share a clock. Why would one green chat prove a deployment? I am not filing a lab report with fake timings. People repeat four claims that sound practical enough. Each claim skips a layer you can actually check. I listed them so the review can point at one. The open-source checkout is already our CI include. Free model access means the job image is chosen. A free server option is already our review app. A local demo is the same run as CI. Here is the corrected model I want teams to use. You hold a repo, a route, a server, and a contract. Proof does not cross those layers unless you captured it. A repo proves you can read source, not that CI ran. A route proves a call only when the log shows it. A server proves a host only when you name the owner. MonkeyCode is the open-source project used in this example. Disclosure: This article was prepared as part of MonkeyCode's product outreach. Operator notes say free model access is currently offered. Those same notes also mention a free server option. I am not naming models or stating a token grant. I am not stating machine size or a time limit. Those details live in current docs, and docs change. Remove the product name and this checklist still works. You can point the same questions at any agent route. What did this job actually prove, line by line? Why would a product page choose your image tag? I would not let a homepage

DevIA
Interesse
dev.to

Đi đây: my laptop reads the bounty fine print while I walk to buy lunch

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 1: Touch Grass I hunt bounties and hackathons from my desk in Vietnam, all day. The only time I go outside is for lunch: about 200 metres to buy rice and water, then straight back. I hurry because every minute away feels like a listing I missed. So I built the thing that would let me walk slower. It is called Đi đây, which is what you say in Vietnamese when you get up to leave: "I'm off." When I get up for lunch, I press Đi đây on my computer and scan a QR code with my phone. While I am out, Gemma 4, running on my own computer, reads the newest bounty and hackathon listings and checks the fine print. It looks for the catch (a live interview, being there in person, adding a payment card), whether Vietnam is allowed, and the real deadline in Vietnam time. The results stay locked until I come back with one photo and ten seconds of sound from outside. Gemma listens to the recording, looks at the photo, decides whether I really went out, and only then opens the list. It is for people like me: anyone whose work lives in a browser tab and who stays inside because of it. The job it does while you are out can be swapped. Mine is reading listings. My first idea for this week was different. It was a walking game where the model wrote the rules and made a little zine from your photos afterwards. When I looked at it again, it looked like something a machine would make for a person it had never met. I threw it away and built what I needed. There is no hosted link, on purpose: everything runs on my computer at home and the phone only talks to it over home wifi. So here are the first two real trips instead, both on Thursday 8 October. Lunch, 12:06 to 13:04. This is where I stopped. On one side is a canal that brings seawater in for a salt company. On the other side are the fields they flood with seawater to make salt. Trucks pass on the road next to it. Gemma heard: "The sound of a car driving by and the sound

IA
Interesse
dev.to

Let a Local Clock Gate the Free Server

A free server should stay idle while the desk still hits budget. Local latency, secret residue, and an offline drill pick the winner. The remote box is a spare lane, not the home road. Teams often rent a distant model because the sticker price is zero. That choice still spends time, trust, and a working network. A cheap lane can be the slow lane when the loop is tight. Treat the laptop as a nearby kitchen clock. Treat the free server as a street courier. The courier wins only after the clock misses the meal. This draft proposes a gate, not a product score. Figures below are planning targets, not measured vendor claims. Run them on your host before you trust a line. Set two budgets before you send any prompt. An assist hop should return in under 400 milliseconds. A batch review may spend up to eight seconds. Those ceilings are proposals for a solo repo workflow. Change them when your editor or hardware differs. Do not paste them into a contract or status page. Assist work sits near the hands, so delay feels like friction. Batch work sits near the calendar, so delay feels like a queue. The same remote hop can pass one budget and fail the other. Measure the desk with a short sample, not a single lucky call. Seven local runs can sketch a median and a rough tail. With seven runs, that tail is simply the slowest sample. The gate reads four facts and prints one choice. It samples a local stand-in and scans secret shapes. It also checks a drill marker and a network flag. Stay local when the local p95 fits the budget. Stay local when the offline drill was never recorded. Block the send when a key-like pattern remains. Open the spare lane only when the miss is real. Local p95 must sit past budget, and the drill file must exist. The wire must be up, and the secret scan must be clean. The local stand-in sleeps briefly, then copies the string. It stands in for an on-disk model, linter, or cache. Replace that function before you trust the printed choice. A fifty millisecond sleep

IAInfraDev
Interesse
dev.to

How to Add a Waitlist to React & Next.js

If you are building your pre-launch site in React or Next.js, you do not need a waitlist SDK or npm package. GetWaitly ships a single script tag and a container element — the same embed that works on any site. Here is how to wire it into a React or Next.js app cleanly. Load https://getwaitly.com/widget.js once in your root layout, then render a wherever the form should appear. For a popup, render a . Use the waitlist's public ID, not its slug. Total time: 5 minutes. A GetWaitly account with a waitlist created (free plan covers 100 subscribers). Your waitlist's public ID from the Widget/Embed section of the dashboard. A React or Next.js app. The widget is plain JavaScript — it does not care which framework you use. The GetWaitly widget is two parts: a script that defines the behavior, and the div itself. In JSX: The script must load once per page. In Next.js that is next/script; in plain React you can put it in index.html or inject it in an effect. The widget finds the .gw-widget element and renders the form into it, styled with your waitlist branding. Load the script in your root layout so it is present on every route, and render the widget on the page that needs it. app/layout.tsx import Script from "next/script"; export default function RootLayout({ children, }: { children: React.ReactNode; }) { return ( {children} ); } app/page.tsx (or any page) export default function Home() { return ( Something great is coming. ); } strategy="afterInteractive" loads the script after the page becomes interactive, so it does not block your render. Use _app.tsx to load the script once, and place the div in your page: pages/_app.tsx import Script from "next/script"; import type { AppProps } from "next/app"; export default function App({ Component, pageProps }: AppProps) { return ( ); } There is no next/script, so add the script tag to index.html before the closing , and render the div in a component: index.html src/App.tsx export default function App() { return ( Join the waitlist

Dev
Interesse
dev.to

How to Connect Apple Health to Cursor IDE via MCP: Developer Health in Real Time

How to Connect Apple Health to Cursor IDE via MCP: Developer Health in Real Time Direct Answer / Recommended Setup: You can connect Apple Health to Cursor IDE using the Model Context Protocol (MCP). By running Vaultbeat's local MCP server (vaultbeat-apple-health) as a stdio process, Cursor's Composer and Agent chat can inspect your sleep recovery, resting heart rate, HRV trends, and active workout energy in real time using on-device Curve25519 end-to-end encryption. Software engineers spend 8 to 12 hours daily in code editors. Biometric-aware development environments unlock powerful quantified-self workflows: Cognitive Readiness Assessment: Ask Composer before starting architectural refactors: "What was my deep sleep and HRV last night? Should I tackle high-complexity tasks today?" Sedentary Alerting & Work-Rest Optimization: Check active energy burned (active_energy_burned) and stand hours during deep coding sprints. Burnout Prevention: Track rolling 30-day trends in resting heart rate and sleep latency to correlate high work velocity with physical recovery. Install uv (Fast Python package runner): brew install uv In your terminal, run: uvx vaultbeat-apple-health@latest bind Open the Vaultbeat iOS app, navigate to the bottom MCP tab, and scan the ASCII QR code. In Cursor Settings → Features → MCP Servers, add a new stdio server: Name: vaultbeat-health Type: command Command: uvx vaultbeat-apple-health@latest serve --transport stdio Available Biometric Tools in Composer Cursor has on-demand access to 29 specialized tools, including: get_metric(series="heart_rate_variability_sdnn", days=7): Retrieve 7-day HRV baseline. get_intraday(series="hrv_sdnn"): High-resolution HRV SDNN readings. correlate_metric_series(series_a="active_energy_burned", series_b="sleep_deep_hours"): In-process Pearson correlation. get_sleep_detail(date="YYYY-MM-DD"): Granular sleep stages breakdown (Deep, REM, Core, Awake). Local iPhone recording and symptom journaling are 100% free forever. Encr

DevMobile
Interesse
dev.to

WildHarvest AI: 100% Offline Campfire Recipe Generator using Gemma 7B

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 1: Touch Grass I built WildHarvest AI, an offline-first campfire recipe generator designed for hikers, campers, and foragers. You simply input the ingredients you just foraged in the wild (e.g., wild mushrooms, bamboo shoots) and the app generates 3 safe, easy-to-cook recipe options using only your found ingredients and basic camping supplies (like a mess kit, salt, and water). It perfectly fits the "Touch Grass" theme because it encourages people to get out into the woods, forage responsibly, and cook outdoors, all while bringing a smart chef along in their backpack. / WildHarvest-AI 🌲 WildHarvest AI WildHarvest AI is a 100% offline, local-first campfire recipe generator built for hikers, campers, and foragers. This project is an official submission for the Hacktoberfest 2026 DEV Challenge (Week 1: Touch Grass). When you are deep in the woods, you don't have internet access. This application solves that by running a local AI model to turn your foraged ingredients into safe, actionable campfire recipes without needing a single bar of cell service. ✨ Features 100% Offline Inference: Powered by Google's open-weight Gemma model running entirely on your local machine via Ollama. Strict Ingredient Bounding: The AI is highly constrained to only use the ingredients you actually found, plus basic camping supplies (water, salt, oil, etc.). No hallucinated ingredients! Campfire Ready: Recipes are designed to be cooked outdoors using basic mess kits or portable stoves. 🛠️ Tech Stack Frontend: Next.js (App Router), React, Tailwind CSS AI Integration:… View on GitHub (Note: I pivoted the project from a dessert app to a foraging app during the hackathon to better fit the theme, but the core engine remains the same!) I built the frontend using Next.js (App Router) and Tailwind CSS. The core intelligence is powered by Google's open-weight Gemma (7B) model, running entirely locally on my machine via Ollama. T

IADev
Interesse
dev.to

Resolving 'Released More Than Held' Error in Go Weighted Semaphore: Debugging and Correct Usage

Introduction to Weighted Semaphores in Go Weighted semaphores in Go are a powerful concurrency primitive, allowing multiple goroutines to share a pool of resources with varying weights. Unlike binary semaphores, which operate on a simple locked/unlocked basis, weighted semaphores track the total weight of acquired resources. This flexibility comes with complexity, particularly in managing acquire and release operations. Missteps here often lead to errors like "released more than held", a common pitfall for beginners. Mechanically, a weighted semaphore operates by decrementing its available resource count when a goroutine acquires resources and incrementing it upon release. The error occurs when the release count exceeds the acquire count, causing the semaphore's internal state to become inconsistent. This inconsistency is not just a logical error—it’s a violation of the semaphore’s invariant, leading to unpredictable behavior in concurrent execution. Consider the system mechanisms at play: Semaphore acquisition: A goroutine requests resources, decrementing the semaphore's count. If the requested weight exceeds the available resources, the goroutine blocks. Semaphore release: Resources are returned, incrementing the count. If the release weight is greater than the acquired weight, the semaphore’s state becomes invalid, triggering the error. Weighted semaphore logic: The semaphore tracks cumulative weight, not just binary state. This requires precise management of weights in both acquire and release calls. The risk of this error is compounded by race conditions. Go’s scheduler interleaves goroutine execution, meaning acquire and release operations can overlap unpredictably. Without proper synchronization, one goroutine might release resources before another has fully acquired them, or release more than it acquired. This race condition is a direct result of concurrent access to the semaphore’s shared state without adequate protection. To illustrate, consider the follow

Dev
Interesse
dev.to

Record the Read Set Before a Free Model Drafts the Next Test

A pairing should record the allowed read set before a free model drafts tests or a free server executes them. The kept decision in this worked example stays narrow, concrete, and easy for a later reviewer to audit. Generated checks may read only a synthetic fixture tree, and the remote job specification may carry no credentials. These notes describe a proposed session rather than a measured incident, and every command below remains an unexecuted example. Developers who generate tests from a private repository often attach broad context and then hope the model will ignore secrets. A senior pairing treats that hope as a failed control, because the upload itself is the event that cannot be undone. The useful artifact is a read-set manifest that names every file allowed into the prompt and every path refused by the server. MonkeyCode's free model access and free server option become relevant only after that manifest exists and a human signs it. Disclosure: This article was prepared as part of MonkeyCode's product outreach. The availability claims in the previous paragraph are operator-supplied, and this draft deliberately stops at those two claims. No model name, quota, hardware shape, duration, or permanence appears here, because those details were not verified from a primary source. Readers should confirm the current terms themselves before they attach any repository or start any remote execution. The gate remains useful if the product name is removed, because the control is ordinary Python plus a written decision record. Recent public writing about generated interfaces and assisted coding shows the same pressure, which is speed competing with review. This article does not treat those titles, reaction counts, or anecdotes as evidence about any model. The durable problem is older than the current week: a draft can look helpful while the context beside it is still private. A pairing session is one way to force that problem into a file a reviewer can diff. The senior did

SegurançaDevIA
Interesse
dev.to

Your Agent Shouldn't Have to Guess the Price — One Catalog, Declared on Every 402

Originally published: https://agentbadge.xyz/blog/arc-c15-x402-bazaar An agent buying from an API answers three questions before it pays: what does it cost, what do I send, is there a free way to try? Most payment-gated APIs make it guess all three. We closed that loop: GET /api/v1/services returns the full machine-readable catalog, and every 402 across the platform declares itself for x402 indexers — price, input schema, free alternatives, before a cent moves. The catalog isn't a hand-maintained list — it's a declarative SKU registry reading the same config sources the payment middleware reads. The price in the catalog IS the price the gate charges. One registry feeds /api/v1/services, the bazaar extension on every 402, and the llms.txt Paid Services section. 14 SKUs across 8 paid surfaces: scans, passport mints, marketplace buys, keeperhub, EaaS verdicts/jobs/subscriptions, bstock passes, venue subscriptions. sku_id is surface:slug, immutable — a golden test fails CI on rename. Every payment gate — x402 Hedera, MPP/Stripe, bstock freemium, the manual settle seam, all three EaaS middlewares — attaches bazaarExtensionFor(" "). The emitted inputSchema is inputSchemaOf(sku), byte-equal to the catalog entry. One function produces the schema — catalog and wire can't drift (D-179-4). Even the L402 macaroon gate is accounted for — it lives on an explicit exception list (no JSON slot) instead of pretending. free[] sits next to services[]: health, scan-packs catalog, market browsing — each with a next_call pointer to the natural paid step. Discovery → free trial → paid call, zero doc reading. tests/e2e/catalog-coverage.test.ts keeps a GATE_TABLE — every gate ↔ SKU both directions. A new paid route without a SKU fails CI. The two non-SKU gates (l402, attestation-api) are an explicit allowlist with written reasons. curl -s https://agentbadge.xyz/api/v1/services | jq '.services[].sku_id' Full article with decoded 402 payloads: https://agentbadge.xyz/blog/arc-c15-x402-bazaar

Dev
Interesse
dev.to

Your intent classifier is 12 points worse in Portuguese: benchmarking Laya, Strands Decider and Qwen3 embeddings

A conversational agent first has to decide what the customer wants. I measured that step for customer-service messages in Brazilian Portuguese (PT-BR), using two small "decider" models and two embedding models. Then I translated the whole dataset into English and ran everything again. Decider vs Laya. Off the shelf, the Strands Decider (2B) gets 84.9–85.8% top-1 accuracy, against 50.9–51.8% for Laya multilingual. Its accuracy does not depend on how the options are ordered. Embeddings alone win. Qwen3-Embedding-4B similarity, with no decider at all, reaches 94.7%, and no decider improves on it. The Portuguese tax. Every component is less accurate in PT-BR than on the same phrases in English. The 0.6B embeddings lose 12 points (p = 0.0014), and the full Decider pipeline loses 8.4 points. The checkpoint's language is the biggest lever. Laya's English checkpoint beats its multilingual sibling by 24 points on English text. Laya has no Portuguese checkpoint, which makes a case for PT-BR fine-tuning. Figure 1. Top-1 accuracy in PT-BR (blue) and in a line-by-line English translation (grey). Bold differences are significant in every seed (exact McNemar test). Goal-oriented agents route each message to one of many goals ("pay a bill", "block a card", "talk to a human"). Each goal is defined by a one-line description and a few example phrases. The decision gates everything after it: High confidence: the agent acts. Middle band: it asks for confirmation. Low confidence: it asks a clarifying question. So you want two things from the classifier: accuracy, and probabilities you can trust. A new class of small models is built exactly for this. Laya and the Strands Decider answer typed questions ("pick one of these N options") and return a probability per option from a dedicated head, instead of generating text. Most of their published evaluations are in English. I wanted to know how they behave in Portuguese. The setup mirrors a production pipeline: Shortlist. An embedding model (Q

IA
Interesse
dev.to

What EU AI Act Article 12 and ISO 42001 mean for AI agent logs

Article 12 of the EU AI Act says high-risk AI systems must technically allow automatic recording of events (logs) over the lifetime of the system. It covers high-risk systems only. An internal assistant that searches docs over MCP doesn't become high-risk because it uses MCP. Per artificialintelligenceact.eu, the obligations apply from 2 December 2027 for Annex III systems and 2 August 2028 for Annex I systems. Check the current consolidated text on EUR-Lex for your own case; none of this is legal advice. ISO/IEC 42001 is broader and vaguer. Control A.6.2.8 asks you to decide in which life-cycle phases event logging is enabled, and "while the AI system is in use" is the minimum. For agents I'd put that logging at the tool call. The model only suggests things, and the tool call is where data actually changes. Before each call with side effects, record: who or what asked, and on whose behalf the agent acted the tool, the action, and the resource it touches the decision (allow, deny, or allow with approval) and the policy version behind it who approved it, if a human had to sign off what happened after the decision Join those with one request ID. Log redacted parameters or hashes instead of raw prompts, so you can replay the decision later without hoarding data. Disclosure: I work at Permit.io. We wrote up the Article 12 and ISO 42001 details, with a full field table for MCP tool calls: https://www.permit.io/blog/eu-ai-act-article-12-iso-42001-agent-logging?utm_source=devto&utm_medium=social&utm_campaign=eu-ai-act-article-12-iso-42001-agent-logging&utm_content=authbyexample-article

IADev
Interesse
dev.to

Replit Database Deletion: What Should Block an Unauthorized Write?

Failure Autopsy: Replit 18 July 2025. A database deletion is publicly reported. Jason Lemkin reports that Replit's coding agent deleted his database without consent during a code and action freeze. Replit later acknowledges the deletion and confirms that the data was fully restored. The affected project was an unfinished demo, not an established commercial service. Lemkin's account and clarification, Replit's acknowledgment, contemporary report. The reported restriction did not prevent the database modification. If an agent requests a change outside its authority, what must stop execution? Our proposed requirement: before a protected database operation executes, the execution layer must deterministically check trusted approval against the operation, target, and scope. A freeze requires an explicit exception that the agent cannot grant itself. We are designing tests for this boundary, not diagnosing Replit's original implementation. These are synthetic, unexecuted specifications. Assume read-only investigation is allowed, while database changes remain frozen unless specifically approved. Condition Proposed test input Required outcome 1. No approval An empty dashboard query prompts a repair attempt. The freeze remains active and no write is approved. Block the write before execution. An empty query result does not establish that the database itself is empty. 2. Narrow approval Approval covers one record update. The agent submits a batch changing two records. Reject the entire batch before either write occurs. The extra change has no authorization. 3. Another route The database tool denies a write. The same change is then attempted through a shell command. Prevent that write through the alternate route too. A denial on one tool cannot leave another path open. Also test a valid, narrowly approved update: it should execute. Blocking every write is not correct authorization enforcement. Shell writes need a constrained execution path or database permissions that prevent un

SegurançaDevIA
Interesse
dev.to

How AI agents pay for APIs per call with x402 (and where they find them)

AI agents increasingly need to buy small things on their own: one API result, one lookup. x402 is a way to do that with plain HTTP and no signup. This post covers how the payment flow works, and where agents discover x402 services, using Tanod's endpoints as the worked example. Pay-per-call APIs let an AI agent buy one result at a time with no account or API key. Tanod does this with x402: an unpaid call gets a 402 with the price, and the client retries with a USDC payment on Base or Polygon. How it works: a client calls an endpoint, the server answers 402 Payment Required with the price and how to pay, and the client retries with a signed payment. There is no account or API key. Tanod endpoints use x402 v2 with the exact scheme, paid in USDC on Base or Polygon. This is a real response from a call to /v1/meta after the free pool for the day was used up (headers and body trimmed). Request: curl -s -i -X POST https://tanod.dev/v1/meta \ -H 'content-type: application/json' \ -d '{"url":"https://github.com/"}' Response (trimmed): HTTP/2 402 content-type: application/json payment-required: { "x402Version": 2, "error": "Payment required: ... Price: $0.002 USDC on base.", "accepts": [{ "scheme": "exact", "network": "eip155:8453", "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", "amount": "2000", "payTo": "0x593857A4a4F619543ea12394137C3004ce841720", "maxTimeoutSeconds": 300 }] } The requirements are in the PAYMENT-REQUIRED header and, identical, in the JSON body. amount is in USDC atomic units (6 decimals), so 2000 is USD 0.002. The asset is USDC on Base (eip155:8453) or Polygon (eip155:137); the client picks one of the listed accepts entries. An x402 client library signs a USDC transfer authorisation for the quoted amount and repeats the same request with it in the PAYMENT-SIGNATURE header (X-PAYMENT is also accepted). The receipt comes back in PAYMENT-RESPONSE. The input is checked first: a rejected input (422, 413 or 404) is never charged, and a payment for a diff

IADev
Interesse
dev.to

The Merge Bit Stays With the Owner

Protected paths do not become optional when a contribution surge arrives. A free model can draft a note about a diff. It cannot own the merge bit, dismiss a scanner, or stand in for the human named in CODEOWNERS. Early October usually thickens the inbound queue. Recent community posts have been full of contribution-drive writeups, portfolio projects, and agent-shaped tooling, which is enough to expect more pull requests and more automated reviewers. Volume is not a reason to move a security decision onto a shared completion endpoint. The clerk can sort the mail. The clerk does not sign the deed. This piece is a field guide for that refusal. It is not a product tour, and it is not a repeat of the older argument about runtime privilege grants. A grant decides what a process may do after deploy. A merge bit decides what enters the tree that deploy is built from. Those failures rhyme, and they still need different locks. The slide is familiar: a workflow that starts as "summarize this diff" later gains a label, then a status check, then a merge. Free inference makes the slide easier, because the call looks cheap and the server looks disposable. Cheap is not the same as accountable. Disclosure: This article was prepared as part of MonkeyCode's product outreach. MonkeyCode's free model access and free server option belong only on the drafting side of the workflow below. They can host a local gate and produce an unsigned summary of an unprotected diff. They are not a branch-protection provider, a signing service, or a substitute for the repository owner. This article does not state model names, quotas, hardware, duration, or data-retention terms. Those facts change, and they belong on a current product page rather than in a recycled paragraph. If the page and this article disagree, the page wins. The analogy that holds is a notary stamp left on a hotel desk. Guests may borrow the pen. They may not borrow the stamp. A completion model is the pen. The stamp is branch protect

DevIA
Interesse
dev.to

From Finance to AI Engineering: 6 lessons I learned building a Multi-Agent Support system on Amazon Bedrock AgentCore

After ten years in asset management, I started a full-stack developer path in 2024 and spent my time between blockchain and AI. Becoming an AI engineer felt out of reach. Then I joined the Udacity AWS & AI Scholars — Future Agent Engineer program, and its third project asked for something very concrete: build the AI layer of a customer support team. This post is the story of that project: what I built, what broke, and what it taught me. NovaMart is a fictional e-commerce company. Its support agents look up orders, check policies and draft answers by hand. The goal: a system that understands a request, gathers facts, applies company policy and replies, with no human in the loop, and with safety and observability built in. I built it with the Strands Agents SDK and deployed it on Amazon Bedrock AgentCore Runtime: an Orchestrator (Claude Haiku 4.5, temperature 0) that only routes, and never answers itself; an Inventory agent that reads orders and customers from DynamoDB and reports facts only; a Refund agent that decides return eligibility: 30 days for Standard customers, 60 for Premium; a Policy agent that runs three retriever sub-agents in parallel, one per Bedrock Knowledge Base (returns, shipping, warranty); a Communication agent that writes every final reply. The agents never talk to each other directly. Each one writes its findings into a shared DynamoDB record, the WorkflowState, with optimistic locking: every write states which version it expects. A Bedrock Guardrail sits on every model call, and every request becomes an X-Ray trace. The automated test suite scored 120/120. The interesting part is what happened along the way. The guardrail had to deny three topics: competitor products, legal threats and pricing negotiations. My first version blocked the brief's own test question: "How much would 5 items at $29.99 be with a 10% discount?" Reading the guardrail's assessment told me exactly which policy fired: Pricing negotiations. My topic definition mentioned di

IAInfraDev
Interesse
dev.to

Best Data Warehouse Schema Documentation Tools (2026): SQLDBM, dbt, DataHub, Atlan & SchemaSpy Compared

Schema documentation used to be the thing teams promised to do "next sprint" and then never did. In 2026, that excuse doesn't hold up. Warehouses are bigger, teams are more distributed, and AI systems are reading your metadata to decide what a column actually means. If your docs are stale or missing, everything downstream suffers. I spent a few weeks digging into the tools people actually use to document Snowflake, Databricks, BigQuery and similar warehouses. Some are modeling-first. Some are catalog-first. One is a free command-line generator that's been around forever. They all approach "documentation" from a different angle, and that difference matters more than most buyer guides admit. Here's my honest take on the five I'd actually consider: SqlDBM, dbt, DataHub, Atlan, and SchemaSpy. I'll explain what each one does well, where it falls short, and who it's really for. I looked at a few things that matter for real documentation work. How quickly a new team member can go from "connected to the warehouse" to "reading a useful description." Whether docs stay in sync with the actual schema or drift the moment someone runs a migration. Support for modern warehouses, especially Snowflake, Databricks, and BigQuery. Governance features like ownership, tags, and glossary. And collaboration, because documentation is a team sport and a one-person wiki always rots. I also weighed pricing honestly, including what you pay in engineering time for the free options. The schema documentation tool that doesn't just describe your warehouse, it governs the blueprint underneath it. After spending real time with every tool here, SqlDBM is the one I keep coming back to. It's cloud-native, browser-based, and code-free. Nothing to install, no local files to babysit, and it handles the full documentation lifecycle in a way the others don't quite match. What makes it stand out in this category is how tightly documentation is woven into the modeling workflow. You don't document after the fac

Dev
Interesse
MIT Tech Review

Building a safer path to autonomous industrial AI

Industrial AI is entering a new phase. After decades of predictive analytics and other specialized applications, advances in foundation models, physical AI, and agentic AI are making it possible to automate more complex tasks across industrial environments. But unlike AI that operates purely in the digital world, industrial AI can interact directly with physical systems,…

IA
Interesse
Hacker News

OpenAI Withdraws 3 Math Papers

Article URL: https://github.com/openai/math/blob/main/history.md Comments URL: https://news.ycombinator.com/item?id=50003107 Points: 7 # Comments: 0

IA
Interesse
dev.to

Designing a URL Shortener: Architecture, Base62, Redis Caching & Scaling

A URL shortener sounds like one of the simplest backend systems to build. Take a long URL: https://example.com/articles/distributed-systems/introduction Generate a short code: https://short.ly/aB7xK2p Store the mapping, and redirect anyone who visits the short URL. Three operations. One database table. A few API endpoints. So why is URL Shortener System Design such a useful distributed systems interview problem? Because generating the short URL is rarely the difficult part. The interesting engineering begins when a link gets shared with millions of people, thousands of requests hit the same database record, a cache restarts during peak traffic, or the analytics pipeline starts slowing down redirects. A production-grade URL shortener is fundamentally a problem of read-heavy architecture, uniqueness, caching, consistency, and failure isolation. Let's design one from first principles. Before choosing Redis, Kafka, or a particular database, we need to understand what the system must do. Our URL shortening service should support: Creating a unique short URL from a long URL. Redirecting visitors to the original destination. Optional custom aliases, such as short.ly/summer-sale. Expiring links after a specified duration. Tracking click analytics, including counts and trends. We will keep authentication, billing, QR codes, and advanced link-management features outside the initial scope. The system should provide low-latency redirects, high availability, durable URL mappings, and the ability to absorb sudden traffic spikes. One requirement is especially important: redirect availability matters more than URL creation availability. If users cannot create new links for a few minutes, that is inconvenient. If existing links stop redirecting, every application, email, or document containing those links can be affected. That difference will influence how we design the entire system. Let's establish an illustrative workload. Metric Design assumption Stored URL mappings 100 million

Dev
Interesse