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

标签:#an

找到 1546 篇相关文章

AI 资讯

Swift 6.4 Brings New Language Features and Swift Testing/XCTest Interop

Currently available as a beta in Xcode 27, Swift 6.4 introduces a range of enhancements: better C interoperability, simplified OS availability check, fine-grained warning control, async support in defer, efficient iteration for non-noncopyable types, up to 4x faster URL parsing, and improved interoperability between Swift Testing and XCTest. By Sergio De Simone

2026-06-28 原文 →
AI 资讯

TMD’s keyless bike lock is a $280 solution to a $60 problem

I've seen lots of so-called "smart" bike locks over the years, but none so far could justify the added cost. A newcomer that got its start securing ATMs for banks is trying to change that. There's nothing wholly unique about the TMD Chain Lock, but the combination of materials, performance, and insurance-friendly ART-2 certification makes […]

2026-06-28 原文 →
AI 资讯

I switched 23 sites from JPEG to WebP/AVIF last month — here's what I learned

I spent last month migrating 23 client sites from JPEG/PNG to WebP and AVIF. Here's what I wish someone told me before I started. AVIF vs WebP: the real numbers AVIF is about 30% smaller than WebP at the same quality level. But Safari support is still patchy — if your traffic is 40%+ iOS, you need <picture> tags with WebP fallback. No way around it. The biggest win wasn't the format The single biggest reduction came from capping max image width at 1200px and setting quality to 80. One site went from 9.4MB to 318KB per page — a 97% reduction — just from those two settings plus lazy loading. The format switch was the cherry on top, not the cake. Tools I used daily SmartImgKit — quick batch conversions in the browser. No uploads, no signup, drag and drop. Handles the 80% case where you don't need a CLI pipeline. Supports JPG, PNG, WebP, AVIF, GIF, BMP, TIFF. ImageMagick — server-side batch jobs for when you need automation. Squoosh — one-off fine-tuning with visual comparison. Sharp (Node.js) — build pipeline integration. The HEIC surprise Every iPhone user's photos are HEIC. Most web tools crash on them. You need a converter that handles them before the pipeline — SmartImgKit's HEIC converter works locally in-browser, no uploads. The 80/20 rule Format + max width + lazy loading = 80% of the gain. Everything else is diminishing returns. Don't over-engineer it.

2026-06-28 原文 →
AI 资讯

The Future of KMP: Upgrading to Kotlin 2.3.20 and Compose 1.10.3

The Kotlin Multiplatform (KMP) ecosystem moves fast. To stay at the cutting edge, ImagePickerKMP has recently undergone a major architectural upgrade in version 1.0.42 , adopting the latest stable versions of Kotlin and Compose Multiplatform. For the latest requirements and installation guides, always refer to https://imagepickerkmp.dev/ . Major Version Upgrades The v1.0.42 release brings significant updates to the core dependencies of the library: Dependency New Version Previous Version Kotlin 2.3.20 2.1.x Compose Multiplatform 1.10.3 1.9.x Ktor 3.4.1 3.0.x Android Gradle Plugin 8.13.2 8.x Warning: Kotlin 2.3.x brings breaking ABI changes. Projects using Kotlin < 2.3.x will fail to compile with an "ABI version incompatible" error when using ImagePickerKMP 1.0.42. Why the Upgrade Matters Performance: Kotlin 2.3.20 includes numerous compiler optimizations that result in smaller and faster binaries for both Android and iOS. Stability: Compose Multiplatform 1.10.3 resolves several rendering issues on iOS and Desktop, providing a smoother user experience. Future-Proofing: By moving to these versions, ImagePickerKMP is ready for the upcoming features in the Kotlin roadmap. How to Upgrade Your Project To use the latest version of ImagePickerKMP, you must update your build.gradle.kts file: plugins { kotlin ( "multiplatform" ) version "2.3.20" id ( "org.jetbrains.compose" ) version "1.10.3" } dependencies { implementation ( "io.github.ismoy:imagepickerkmp:1.0.42" ) } If your project is not yet ready for Kotlin 2.3.x, you can continue using version 1.0.41 of the library, which maintains compatibility with older Kotlin versions. Conclusion Staying updated is crucial for security, performance, and developer happiness. ImagePickerKMP makes it easy to leverage the power of the latest Kotlin features while maintaining a simple, unified API for media picking. Explore the full API reference and new features at https://imagepickerkmp.dev/ . References [1]: ImagePickerKMP Documentati

2026-06-28 原文 →
AI 资讯

DeepSeek's DSpark Brings Speculative Decoding Back Into the Spotlight — Here's What Developers Need to Know

Introduction Speculative decoding is one of those techniques that has been "almost ready for production" for the better part of three years. A small draft model proposes tokens; a larger target model verifies them in a single forward pass. In theory, you get 2–4× throughput. In practice, the draft model has to be cheap, fast, and good enough at mimicking the target's distribution, which is a much harder combination than it sounds. Yesterday, a new paper from DeepSeek quietly climbed to the top of Hacker News (714+ points, 290+ comments at the time of writing). It's called DSpark , and it reframes speculative decoding in a way that looks like it could finally make the technique drop-in rather than bolt-on. The paper is here: github.com/deepseek-ai/DeepSpec/blob/main/DSpark_paper.pdf The Core Idea Instead of training a separate, smaller draft model from scratch (the classic approach), DSpark grafts the speculative head directly onto the target model. The intuition is simple: if the target model already knows which tokens are likely to follow, why not reuse its own intermediate representations rather than maintaining a parallel network? From the discussion on HN, this approach has a concrete architectural benefit — it reduces layer duplication that you'd otherwise have to maintain with a standalone draft model. In the DeepSeek experiments, the technique was applied on top of Step and Qwen 3.6 , which are themselves MTP-capable. How It Fits With MTP One of the more interesting practical points raised by HN commenters: DSpark is complementary to Multi-Token Prediction (MTP) , not a replacement for it. MTP — where the model predicts several future tokens at every step using auxiliary heads — has already been shown to give 50–100% speedups on hardware like the NVIDIA DGX Spark. DSpark adds another layer on top: even with MTP, the validation step is still a single forward pass through the main model, and the speculative tokens that get accepted come "for free." A useful men

2026-06-28 原文 →
AI 资讯

Inside An AI Agent: Planning, Tool Use, Memory, Constraints, And Verification

Have you noticed how every demo of "an AI agent" looks impressive in the video and falls apart the moment you ask a sharper question? The agent confidently does the wrong thing. It forgets what it just decided. It tries to call a tool that doesn't exist. It loops forever rewriting the same file. It calmly tells you the deployment succeeded when it didn't. These aren't failures of the model. They're failures of the workflow around the model. Because that's all an agent really is: a software workflow where a language model can pick the next step and call tools. The "intelligence" sits in the prompt and the orchestration around it, not in some secret agent-flavoured fairy dust. Strip the word "agent" away and you've got five pieces of plumbing: planning, tool use, memory, constraints, verification. Every production-grade agent stands or falls on those five. This is a long walk through each one. Not the marketing version. The kind of detail you actually need before you ship something that talks to your database. The Loop You're Actually Building Before we touch any pillar individually, hold the whole loop in your head. A useful agent does roughly this on every turn: Read the goal (and whatever memory is relevant to it). Decide the next action: answer directly, call a tool, ask a clarifying question, or stop. If it called a tool, observe the tool's result and feed it back in. Update memory if anything is worth remembering. Check constraints: are we over budget, out of iterations, touching something off-limits? Verify the output before declaring success. Loop until done or stopped. That's it. Every framework (LangGraph, OpenAI Agents SDK, Claude Agent SDK, smolagents, whatever ships next month) is a different shape of the same loop with different defaults. agent-loop.ts async function runAgent ( goal : string , ctx : AgentContext ) { const state = ctx . startState ( goal ); for ( let step = 0 ; step < ctx . maxSteps ; step ++ ) { const decision = await ctx . model . decid

2026-06-28 原文 →
AI 资讯

Understanding Curly Braces: Syntax and Semantics in Code

In the landscape of modern programming, delimiters serve as the essential scaffolding that organizes logic and defines structure. Among these, curly braces—often referred to as braces or squiggly brackets—occupy a unique position. While they are ubiquitous, they are frequently the source of developer frustration and logic errors. A common pitfall for many programmers is the tendency to treat all delimiters as interchangeable, leading to a fundamental misunder身 of how a compiler or interpreter parses a script. Confusion often arises when developers conflate the purpose of curly braces with those of parentheses or square brackets. For instance, in many languages, curly braces denote a scope or a code block, whereas square brackets handle indexing. However, the nuances become even more complex when examining specific environments like R, where the semantic meaning of a symbol can shift depending on the context—moving from defining a function to facilitating list extraction. Understanding the specific curly braces semantics is not merely an academic exercise in syntax; it is a practical necessity for writing clean, maintainable code. When a developer understands why a brace is used, they can more easily debug nested structures and communicate intent to their teammates. Grasping these distinctions reduces the cognitive load required to read complex scripts and prevents the subtle bugs that emerge when syntax is used incorrectly. Curly Braces vs. Other Delimiters: Semantic Roles in R and Beyond To master programming syntax, one must move beyond recognizing symbols and begin understanding their semantic intent. While many developers treat curly braces as just another set of punctuation, their role is fundamentally distinct from parentheses and square brackets. Understanding the nuance of curly braces semantics is essential for writing logic that is both functional and readable. The Primary Role: Defining Code Blocks In most procedural and object-oriented languages (such as

2026-06-28 原文 →
AI 资讯

I open-sourced high-performance open-source Bonkfun Bundler for Solana

high-performance open-source Bonkfun Bundler for Solana A high-performance open-source Bonkfun Bundler for Solana. It allows users to create a token + bundle up to 12 purchases in a single atomic transaction. Features Jito-powered bundles, delay sniping, pure sniping mode, automatic wallet generation, SOL airdrops, and wallet cleanup/refund tools. Optimized for fast meme coin launches on letsbonk.fun. I open-sourced solana-bonkfun-bundler for developers in Solana Web3 development . This post walks through what it does, how the pieces fit together, and how to run it locally. Why I built this Explore solana bonkfun bundler patterns in solana web3 development Fork the repo as a starter template for your own project Contribute features, docs, or tests via pull requests Most tutorials stop at a smart contract or a UI mockup. I wanted a complete vertical slice — wallet flow, on-chain logic, backend state, and a responsive frontend — so you can study or fork a production-shaped codebase. What it does Wallet connect — players sign in with a Solana wallet A high-performance open-source Bonkfun Bundler for Solana It allows users to create a token + bundle up to 12 purchases in a single atomic transaction Features Jito-powered bundles, delay sniping, pure sniping mode, automatic wallet generation, SOL airdrops, and wallet cleanup/refund tools Optimized for fast meme coin launches on letsbonk.fun Jito-powered atomic bundles Non-Jito delayed-snipes Pure sniping mode Architecture at a glance Wallet layer — users connect a Web3 wallet to sign transactions Application layer — TypeScript backend/frontend tying on-chain and off-chain flows Feature — Wallet connect — players sign in with a Solana wallet Feature — A high-performance open-source Bonkfun Bundler for Solana Feature — It allows users to create a token + bundle up to 12 purchases in a single atomic transaction User Wallet → On-chain Program → VRF / Settlement ↓ Backend (API + WebSockets) → MongoDB / state ↓ Frontend UI (rea

2026-06-28 原文 →
AI 资讯

THE KNOWLEDGE ATOM // Writing for Machines That Read

The Knowledge Atom: Writing for Machines That Read The Hoarder's Reflex Everyone is learning to feed the machine. Bigger context files. Paste the whole document. "Give the AI all the context it needs." The entire industry has converged on a single instinct: when in doubt, add more. It's the wrong instinct. A context window is not a hard drive. It's a desk. And a desk piled with every document you own is not a well-informed desk — it's an unusable one. The model doesn't read better because you gave it more. It reads worse, because the one line that mattered is now buried under a thousand that didn't. Knowledge an AI can't find is knowledge it doesn't have. Knowledge it always carries is weight it always pays. The Two Failures There are only two ways to get this wrong, and almost everyone commits one of them. The first is the dump . You take everything you know and pour it inline — into the system prompt, the master config, the one document to rule them all. It feels thorough. It is the opposite. Every token you add dilutes every token already there. Signal drowns in completeness. The model now has all the knowledge and none of the focus. The second is the orphan . You did the disciplined thing. You wrote a clean, perfect note, in its own file, out of the way. And then nothing pointed to it. No index, no trigger, no path back. The note is immaculate and invisible — which is worse than never writing it, because you believe the knowledge is in the system when in fact it is dead. Both failures share one root: confusing having knowledge with retrieving it. Same Pattern, New Sauce Watch the field long enough and you'll see the same thing return, repainted each time. The "Ralph Wiggum" loop becomes "the agentic loop." Agent teams that talk to each other become a single orchestrator, and then an agent that makes other agents talk to each other. Every cycle sells itself as the breakthrough. Every cycle is a re-skin of the last. Underneath the churn, only one thing actually ch

2026-06-27 原文 →
AI 资讯

I open-sourced A full-stack, peer-to-peer coinflip betting game on Solana

A full-stack, peer-to-peer coinflip betting game on Solana A full-stack, peer-to-peer coinflip betting game on Solana. Players connect a wallet, create or join on-chain game rooms, and compete head-to-head for 2× the stake. The UI updates in real time over WebSockets, outcomes are resolved on-chain with Orao VRF, and the backend tracks rooms, chat, and match history in MongoDB. I open-sourced coinflip-casino for developers in Solana / Anchor smart contract development . This post walks through what it does, how the pieces fit together, and how to run it locally. Live demo / site: https://www.flip.is/ Why I built this Learn full-stack Web3 game architecture (wallet + program + backend + UI) Study provably fair randomness with on-chain VRF integration Fork and customize a peer-to-peer on-chain betting room model Most tutorials stop at a smart contract or a UI mockup. I wanted a complete vertical slice — wallet flow, on-chain logic, backend state, and a responsive frontend — so you can study or fork a production-shaped codebase. What it does Create a room — Pick Head or Tail, set bet amount, choose SOL or SPL token. Join a room — Browse open games in the live lobby and match against another player. PvP coinflip — When two players are in the same room, the backend triggers on-chain resolution. 2× payout — The winner receives double the bet (fees apply on-chain). Room expiration — Open rooms older than 5 minutes with no opponent are expired and refunded automatically. Portfolio stats — Win count and total games per wallet. Wallet connect — players sign in with a Solana wallet Peer-to-peer rooms — create or join head-to-head matches Architecture at a glance Wallet layer — users connect a Web3 wallet to sign transactions On-chain program — Anchor/Rust logic for escrow, rooms, and settlement Randomness — verifiable flip outcomes via Orao VRF on Solana Real-time layer — WebSocket events push room and flip state to the UI Persistence — MongoDB stores rooms, chat, and historic

2026-06-27 原文 →
AI 资讯

How to Set Your Freelance Day Rate as a Developer (With a Free Calculator)

One of the hardest things about going freelance as a developer isn't writing code — it's knowing what to charge. Charge too little and you're basically doing a salaried job without the benefits. Charge too much without backing it up and you scare off clients. Most developers I've spoken to either guessed their rate or copied someone else's. Neither is a great strategy. In this article I want to walk you through exactly how to calculate your freelance day rate properly — based on real numbers, not gut feeling. Why Most Freelancers Get Their Rate Wrong The most common mistake is this: taking your old salary and dividing it by 260 working days. That ignores: Taxes (you now pay both sides of self-employment tax in the US) Unpaid days — holidays, sick days, slow months with no clients Business costs — software, hardware, insurance, accountant fees No employer pension or benefits — you fund all of this yourself If you were earning $80,000 as a salaried developer and you divide that by 260, you get roughly $307/day. But that's actually a pay cut once you factor everything in. The Right Formula Here's the framework: Step 1 — Work out your actual billable days A year has 260 working days. Subtract: Public holidays (~10 days in the US) Your own holiday allowance (~15 days) Estimated sick days (~5 days) Non-billable time: admin, chasing invoices, marketing yourself (~20 days) That leaves roughly 210 billable days. Step 2 — Calculate your real income target Take what you want to take home and gross it up for tax. If you want $70,000 net and your effective tax rate is around 30%, your gross target is roughly $100,000. Step 3 — Add your business costs Software subscriptions, hardware depreciation, liability insurance, accountant — easily $5,000–$10,000/year for a freelance developer. Step 4 — Divide by billable days $110,000 ÷ 210 = $524/day That's your minimum. Price below that and you're losing money compared to employment. A Faster Way — Use a Free Calculator If that maths mad

2026-06-27 原文 →
开发者

Inside the room where the smart home industry is still betting on Matter

Four years ago, overlooking a canal in Amsterdam, the smart home industry collectively launched Matter, the one interoperability standard to rule them all. Heralded as the solution to the industry's struggles, Matter was built on open standards and existing technologies and is the result of years of collaboration between traditional rivals, including Apple, Google, Amazon, […]

2026-06-27 原文 →
AI 资讯

I hooked up Trading212 to Home Assistant and now Alexa tells me if I'm up or down every morning

I've been using Home Assistant for a few years and Trading212 for longer than that. It was inevitable these two things would end up connected. The Trading212 API is surprisingly good — portfolio value, individual positions, pies, dividends, all there. So I wrote a custom integration to pull it all into HA as sensors, then a Lovelace card to make it actually look decent on a dashboard rather than a wall of entity rows. The card does zero-config auto-discovery which was the bit I spent the most time on. You drop it on a dashboard and it finds your sensors automatically — no copying entity IDs, no manual config unless you want it. Five card types: portfolio overview with a sparkline, scrollable positions list, pies with goal progress, and a combined one if you want everything in one card. The sparkline was fiddly. HA's recorder only writes state changes, not regular samples, so if your portfolio value is flat between polls the chart has gaps. Had to smooth over those client-side. The part I use most though is the automations. Every weekday at 8am Alexa tells me where I stand: action : - action : notify.alexa_media_kitchen data : message : > Portfolio is worth {{ states('sensor.trading212_total_value') | float | round(0) | int }} pounds. Today you are {% if states('sensor.trading212_pnl_today') | float >= 0 %}up{% else %}down{% endif %} {{ states('sensor.trading212_pnl_today') | float | abs | round(2) }} pounds. data : type : tts And Friday at 6pm I get the weekly version with P&L for the week and which position moved the most. I like that it just tells me — if the market's had a bad week I'd probably avoid opening the app, but Alexa doesn't give me the option to ignore it. Both the integration and the card are on GitHub. The card is in HACS as a custom repo while it waits for default catalogue approval: https://github.com/Smart-Home-Assistant-UK/lovelace-trading212-card I wrote up the full setup with all the automation YAML here if you want to copy the whole thing: ful

2026-06-27 原文 →
AI 资讯

How AI changes what 'learning' means

How AI Changes What 'Learning' Means Hook: Amre learned Python using AI. No, not just using AI as a supplementary tool—he learned from AI, as if it were his personal tutor. If AI can teach a complex skill like programming, what does that mean for the future of education? Background: The traditional education system, with its structured curriculums and standardized testing, has long been criticized for its rigidity. Enter AI, and suddenly, the landscape of learning is shifting. AI tutors, adaptive learning platforms, and intelligent coding assistants like GitHub Copilot are becoming ubiquitous. These tools are not just helping students with homework; they are fundamentally altering the way we acquire new skills and knowledge. Consider Amre's experience. Frustrated with the slow pace of a traditional Python course, he turned to an AI-powered learning platform. The AI assessed his current knowledge, identified his learning style, and tailored a curriculum specifically for him. It provided instant feedback, suggested additional resources, and even simulated real-world coding challenges. Within weeks, Amre was writing functional code and solving complex problems—something he hadn't thought possible in such a short time. This isn't an isolated incident. Across the globe, learners are turning to AI for personalized education experiences. From language learning apps that adapt to your pace and style, to AI tutors that can explain complex mathematical concepts in multiple ways until you understand, the traditional classroom is being redefined. Analysis: The most significant change AI brings to learning is personalization. Unlike traditional education systems that follow a one-size-fits-all approach, AI can adapt to the unique needs of each learner. It can identify gaps in knowledge, adjust the difficulty level of tasks, and provide customized feedback. This level of personalization was previously only available to those who could afford private tutors. Moreover, AI democrati

2026-06-27 原文 →