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

标签:#RAM

找到 2766 篇相关文章

AI 资讯

Protótipos: como a herança realmente funciona no JavaScript

Introdução Muitas linguagens como C#, Java, entre outras são descritas como orientadas a objeto, possibilitando o paradigma Programação Orientada a Objeto (POO). No entanto, quando falamos de JS, sabemos que por mais que existam objetos, ela é dita como uma linguagem orientada a protótipos, mas o que de fato isso significa, qual problema isso resolve e como muda a maneira como programamos? O problema Tanto a orientação a objeto quanto a orientação a protótipo lidam, entre outras coisas, com a questão de como a herança vai funcionar em determinada linguagem e é justamente nesse ponto que as duas abordagens mais se diferem. Em linguagens orientadas a objetos as classes de fato existem, contendo propriedades, métodos e servem como molde para a criação de objetos. Com isso, todo objeto criado a partir de uma classe herda suas propriedades e métodos ficando acessíveis para uso. Como não existem Classes de fato em JavaScript, a herança ocorre de maneira diferente, de objeto para objeto, ligados através da propriedade [[Prototype]] que possui uma referência ao seu protótipo, fazendo com que determinado objeto herde de seu protótipo propriedades e métodos que nunca foram definidos nele. Exemplo com array Quando criamos um array, seja de forma literal com [], ou de forma explícita com new Array(), o resultado final é o mesmo: um array cujo [[Prototype]] aponta para o Array.prototype. Essa propriedade .prototype possui um objeto contendo todas as propriedades e métodos que o [[Prototype]] referencia, possibilitando que todos os arrays possam usar métodos como push, pop, map, filter… Com isso, se irmos além e conferirmos o [[Prototype]] do Array.prototype vamos perceber que ele aponta para o Object.prototype que contém propriedades e métodos também disponível em todo essa cadeia que chamamos de prototype chain . Por fim, se tentarmos visualizar o protótipo do Object.prototype veremos que é null, pois ele representa o último elo dessa cadeia. Teste o código abaixo para ver na p

2026-09-04 原文 →
AI 资讯

Is it possible to deserialized a saved file of an old pascal system?

I'm working on making a latest system from an old pascal system (created in year 2008). And am trying to retrieve all of the data from that old system. It's has been said that the data was encrypted by the creator of the old system. But when i looked into the contents of the saved file using notepad, there are still readable text which are the raw data of the system. That made me think - it might not be encrypted. it might be serialized, instead. Like a saved file of c# unity game. The old system is still alive but the source code of it is no more. And the creator already passed away. So, i can't sif The internet or AI suggests that i use R language or python but it doesn't seem to work. So now, I'm trying to recreate the data's blueprint/record using pascal but there's a lot of variables and the arrangement of those variables must be correct as the original bluprint.. Can you give me other ideas to reverse-engineer the file? submitted by /u/Sil3nt_R3ap3r-1208 [link] [留言]

2026-09-04 原文 →
AI 资讯

What I learned building an enemy state machine in Godot 4

I wrote "just use a match statement, it's fine" three times before I stopped saying it. It is fine, right up until an enemy needs a fourth state and two of the transitions start depending on each other. Here is what actually cost time building enemy AI for a wave-based game, in the order it bit me. Lesson 1: the match statement is fine until state 4 A two-state enemy — chase, attack — is genuinely not worth a framework: func _physics_process ( delta : float ) -> void : match state : State . CHASE : velocity = ( player . global_position - global_position ) . normalized () * speed if global_position . distance_to ( player . global_position ) < attack_range : state = State . ATTACK State . ATTACK : attack_timer -= delta if attack_timer <= 0.0 : do_attack () state = State . CHASE The moment a third and fourth state show up — hurt, dead, stagger, windup — the match block stops being one enemy's logic and becomes a grid of every state times every other state it might transition to. That grid is where the bugs live, not in any single state. Lesson 2: the bug is never inside a state, it's in the transition Every state-machine bug I actually spent time on was the same shape: state A left some flag or timer set that state C didn't know to check. An enemy stuck mid-attack-animation forever, still receiving hits, was not a bug in the attack state — it was the hurt state interrupting attack without cleaning up attack_timer or resetting the animation. The fix that made these bugs findable is giving every state an explicit enter and exit , and never mutating another state's data directly: func change_state ( new_state : State ) -> void : if new_state == state : return _exit_state ( state ) state = new_state _enter_state ( new_state ) func _exit_state ( s : State ) -> void : match s : State . ATTACK : attack_timer = 0.0 sprite . stop () func _enter_state ( s : State ) -> void : match s : State . HURT : velocity = Vector2 . ZERO hurt_timer = HURT_DURATION sprite . play ( "hurt" ) On

2026-09-04 原文 →
AI 资讯

AI Can Write Your Code. Can It Actually Debug It?

AI Can Write Your Code. Can It Actually Debug It? AI coding assistants have changed how developers write software. You can describe a feature, generate a function, refactor a component, write a test, or explain an unfamiliar codebase in seconds. But there is one part of software development that is still surprisingly difficult: figuring out why something broke. Writing code and investigating a failure are two very different problems. When an application crashes, the answer usually isn't sitting inside the error message. You have to reconstruct what happened. The Problem With "Just Read the Stack Trace" Consider this Node.js error: TypeError: Cannot read properties of undefined (reading 'email') at getUser (/app/services/user.js:42:18) at processRequest (/app/controllers/auth.js:87:12) at async handler (/app/routes/auth.js:31:5) The immediate problem appears obvious. Something is undefined. But what caused it? Maybe: A database query returned no user. An API returned an unexpected response. Authentication middleware failed. A promise returned an unexpected value. A user record exists but its profile doesn't. An earlier function silently produced invalid state. The stack trace tells you where the program finally failed . It doesn't necessarily tell you where the bug began . That's the difference between error reporting and debugging investigation. AI Coding vs AI Debugging Most AI coding workflows look something like this: Developer ↓ Prompt ↓ AI ↓ Code Debugging is different: Failure ↓ Error ↓ Stack trace ↓ Execution path ↓ Application state ↓ Root cause ↓ Fix The AI needs to reason across that chain. Simply asking: "What does this error mean?" usually produces a list of possible explanations. That's useful, but it's not necessarily an investigation. A better question is: "Given this failure and its context, what is the most likely root cause, what evidence supports it, and how can I reproduce it?" That's a much more interesting problem for AI. A Simple JavaScript De

2026-09-04 原文 →
AI 资讯

Self-Healing CI Fixes Your Environment. Your Coding Agent Fixes the Code.

The agent is already in your workflow. The failed build is where it goes blind. AI coding agents have moved from novelty to daily tool. In Stack Overflow's 2025 Developer Survey, 84% of developers said they are using or planning to use AI tools in their development process, up from 76% the year before, and about one in seven professional developers now use AI agents at work every day . Among developers who have used agents at work, roughly 70% agree the agents have reduced the time they spend on specific tasks . There is one place, though, where that agent still tends to go dark: the failed CI run. The pipeline turns red, and your agent (like you) is handed a wall of log output from jobs it did not write, covering steps it did not touch. It has to reconstruct what actually broke before it can fix anything. That reconstruction is the expensive part, and it is exactly the part Latchkey is built to remove. This piece is about a clean division of labor. Latchkey's self-healing CI repairs the failures that are about your environment, not your code. For the failures that are genuinely about your code, Latchkey does not guess and patch on your behalf. Instead it hands your own coding agent a complete, structured account of the failure over the Model Context Protocol, so your agent can fix the bug with full context instead of starting from a log file. Two kinds of red build, and only one of them is yours to fix Almost every failed build is one of two things. Either the environment let you down (a flaky network, a full disk, a process killed for memory, a missing tool, configuration that drifted), or your code is actually wrong (a compile error, a failing test, a broken assertion). These two cases want opposite treatment, and conflating them is how teams end up rerunning pipelines and hoping for green. Latchkey's self-healing CI handles the first case. When a step fails on a Latchkey managed runner, Latchkey detects the failure, diagnoses the cause, and applies a fix while t

2026-09-04 原文 →
AI 资讯

The Pipeline Became the Attack Surface: What the 2026 CI/CD Shifts Mean for Reliability

The Pipeline Became the Attack Surface For most of the last decade, we treated the CI/CD pipeline as plumbing: invisible, trusted, and mostly ignored until it broke. That assumption is no longer safe. The clearest signal came in 2025, when attackers stopped going after the software a pipeline builds and went after the pipeline itself. This week's research pass pulled together three shifts that are all landing at once: a supply-chain attack that redefined the threat model, GitHub's response in its 2026 security roadmap, a pricing change that quietly rewrites the cost math, and a persistent gap between how much teams trust AI in general and how little they trust it inside CI. Here is what the sources actually say. The tj-actions attack changed the threat model On March 14, 2025, researchers discovered that the popular tj-actions/changed-files GitHub Action had been compromised. According to Palo Alto Networks Unit 42, the action was used by over 23,000 GitHub repositories at the time ( Unit 42 ). The mechanics are worth understanding, because they explain why this matters beyond one action. Attackers injected code that dumped the CI/CD runner's memory and wrote sensitive environment variables and secrets straight into the workflow logs. They retroactively modified multiple version tags to point at a single malicious commit, so pipelines that pinned to a tag rather than a commit SHA pulled the payload ( Unit 42 ). The incident is tracked as CVE-2025-30066, described as allowing remote attackers to discover secrets by reading action logs ( GitHub Advisory Database ). The compromise did not start with tj-actions. Unit 42 traced it back through a leaked personal access token that reached reviewdog/action-setup , a dependency in the chain, with earlier steps going back to late 2024 ( Unit 42 ). In other words, the pipeline's own dependency graph was the delivery vehicle. The takeaway is not "avoid one bad action." It is that the automation running your builds is now a firs

2026-09-04 原文 →
AI 资讯

CI Got Cheaper in 2026. Reliability Is Now the Harder Problem

The first half of 2026 reset two things at once for engineering teams: what continuous integration costs, and what it takes to keep delivery stable while AI pushes more change through your pipelines than ever. Those two stories are connected, and the connection is the part worth your time. The pricing reset On January 1, 2026, GitHub reduced prices for GitHub-hosted runners by up to 39%, with the size of the cut depending on the machine type ( GitHub Changelog ). Standard hosted-runner usage on public repositories stays free, as it was before. The DevOps publication SamExpert documented the specific per-minute moves. A Linux 2-core runner dropped about 25% (from $0.008 to $0.006 per minute). A Windows 2-core runner dropped about 38% (from $0.016 to $0.010). A Linux 64-core arm64 runner dropped about 39% (from $0.160 to $0.098) ( SamExpert ). If your CI runs mostly on hosted runners, that is real money back, and it is worth recalculating your monthly estimate against the new rates rather than assuming last year's numbers still hold. The same December 2025 announcement carried a more controversial proposal: a $0.002 per-minute charge for self-hosted runner usage in private repositories, scheduled to start March 1, 2026 ( DevClass ). GitHub framed it as ending a cross-subsidy, where revenue from hosted runners was effectively underwriting the cost of operating Actions for everyone, and said the large majority of customers would see no change to their bill. The reaction from developers who run CI on their own hardware was sharp, with some publishing the monthly figures they expected to owe for compute they already pay to operate themselves. Within about a week, GitHub posted that it was postponing the self-hosted billing change to re-evaluate its approach ( SamExpert ). Postponed, it is worth being precise here, is not the same as withdrawn. There is no new date and no guarantee the charge returns in its original form, but there is also no statement that it is gone for

2026-09-04 原文 →
AI 资讯

The 2026 GitHub Actions Reset: Cheaper Runners, Stricter Security, and Smarter Pipelines

The first half of 2026 rearranged three things at once for teams that live in GitHub Actions: what CI costs, how it is secured, and how much of it a machine can now do on its own. None of these landed cleanly. Prices went down for most people while a new platform charge quietly went up. A self-hosted runner fee was announced, met a wall of objections, and was pulled back within a week. And a security roadmap arrived that will change how workflows pin dependencies and scope secrets over the next two to three quarters. Here is a grounded read of what happened, with sources, and an honest account of where Latchkey fits. Hosted runners got cheaper, and a new platform charge arrived On January 1, 2026, GitHub reduced GitHub-hosted runner prices by up to 39%, with the size of the cut depending on the machine type (larger runners saw the larger relative reductions), per GitHub's own changelog ( github.blog ). In concrete terms, community reporting put the Linux 2-core rate moving from $0.008 to $0.006 per minute and the Windows 2-core rate from $0.016 to $0.010 per minute ( samexpert.com ). Alongside the cuts, GitHub introduced a $0.002 per-minute Actions cloud platform charge that applies to all Actions workflows. For GitHub-hosted runners, that charge is already bundled into the reduced meter price, so it is not a separate line item there ( github.com ). Two things stayed the same and are worth repeating, because they get lost in the noise: standard runner usage on public repositories remains free, and GitHub Enterprise Server pricing is unaffected ( github.com ). GitHub framed the net effect as small for most accounts: it stated that 96% of customers would see no change to their bill, and that of the 4% affected, 85% would see costs decrease while the remaining 15% faced a median increase of roughly $13 ( github.com ). That is a reassuring headline. It is also a reminder that the bill depends entirely on your own mix of runner sizes and minutes, which is exactly the thi

2026-09-04 原文 →
AI 资讯

The 2026 CI/CD Squeeze: Faster Code, Shifting Prices, and Where Reliability Fits

Two forces are pulling on delivery pipelines this year. Code is arriving faster than ever, and the cost of running the pipelines that ship it has been unusually unsettled. Let us look at both, honestly, and then talk about where reliability work fits. Pricing was a moving target, and it still is On December 16, 2025, GitHub announced a simpler Actions pricing model that included a new $0.002 per minute "cloud platform charge." The plan was for that charge to reach self-hosted runner usage in private repositories on March 1, 2026 ( GitHub Changelog ). The reaction was strong enough that GitHub reversed the self-hosted portion within days. As GitHub put it, they "missed the mark with this change by not including more of you in our planning," and postponed the self-hosted charge to re-evaluate the approach ( GitHub Changelog ). Postponed is not cancelled, so if you run self-hosted runners in private repos, this is worth watching rather than filing away. GitHub's own framing was that the change would touch a small slice of accounts: it reported that 96% of customers would see no change to their bill, and that of the 4% affected, most would actually see their Actions bill decrease ( GitHub Changelog ). Even so, the principle of paying a per-minute fee for software running on hardware you already own was the sticking point for many teams, and the reversal followed quickly. The other half of the announcement did take effect. On January 1, 2026, GitHub reduced the price of GitHub-hosted runners by up to 39%, depending on the machine type, while leaving free minute quotas unchanged ( GitHub Changelog ). GitHub pointed teams to its runner pricing docs and calculator for the exact per-machine rates rather than publishing a single headline number ( GitHub Changelog ). That "up to" is doing real work in the sentence: the reduction depends on which machines you actually use, so the only way to know your number is to look at your own usage mix. The practical takeaway: the ground u

2026-09-04 原文 →
AI 资讯

TinyML on ESP32-S3: Person Detection Without Sending Anything to the Cloud

Local inference that actually runs. Your smart camera is not smart. It's a snitch with a monthly bill. It sees a person, panics, compresses a blurry JPEG, uploads your hallway to a data center in Virginia, waits for a GPU to wake up and say "yeah, that's a person," and then charges you $9.99 to tell you what your own eyes could have seen in 100 milliseconds. We can do the same job for $12, with no WiFi, no cloud, and no one else ever seeing the pixels. This is how. The cloud is the bug, not the feature I get why we ended up here. Cloud was easy. You slap an RTSP stream on a Pi, send it to Rekognition, done. But for person detection specifically, cloud fails in three predictable, annoying ways. Privacy isn't a setting, it's a location. If the frame leaves your house, it's not private. It doesn't matter what the privacy policy says. Local inference means the frame lives for about a tenth of a second in PSRAM and then gets overwritten. The chip doesn't care about your pajamas. It doesn't have a retention policy. Latency ruins the whole point. Cloud roundtrip is 300ms when your WiFi is happy, two and a half seconds when your microwave is on. An on-device S3 does it in 80 to 120 milliseconds. Your light turns on when you walk in, not after you've already stubbed your toe in the dark. And cost compounds quietly. One camera is "free tier." Five cameras is a business model. The ESP32-S3 draws less than your keyboard backlight and runs on a power bank during a blackout. No API keys, no rate limits, no "your trial expired" email at 2am. If you need to know who the person is, sure, go cloud. If you just need to know is there a person here right now , local isn't just cheaper. It's the only design that isn't embarrassing. Meet the chip that finally doesn't make you hate yourself Forget the old ESP32-CAM. That thing had 520KB of SRAM and the emotional stability of a dying browser tab. You could run person detection on it if you liked watching the watchdog timer reboot your board

2026-09-04 原文 →
AI 资讯

CanvasKit Layout Traps: The Unbounded Constraint Bug That Only Blanks Release Builds

I shipped eight card and casino games to my portfolio in a single commit — solitaire, roulette, video poker, slots, baccarat, keno, war, higher-lower. All client-side Flutter web, all free, all deployed to Firebase Hosting in one push. flutter analyze was clean. I read the diff twice. The build succeeded. I deployed. Then I opened /games/roulette on the live site and got a page with a header, a subtitle, a bankroll readout, a spin button — and a completely blank rectangle where the betting board should have been. No red error screen. No console exception. No 404. Just an empty region the size of the thing that was supposed to be there, on a page where everything else rendered perfectly. The cause was one enum value: CrossAxisAlignment.stretch on a Row that, four widgets up the tree, was sitting inside a scroll view. In debug that combination throws a loud, well-written framework error. In release the assertion that produces that error doesn't exist, so nothing throws at all — the framework computes with infinity and paints nothing. A layout contract violation is not a type error, and no amount of static analysis is going to find it for you. This post is that bug in full, the family of unbounded-constraint traps it belongs to, why debug builds give you a false sense of safety, and the verification discipline I now refuse to skip. Eight games shipped, one board rendered nothing The symptom is worth describing precisely, because it's what makes this class of bug so slow to diagnose. The route loaded. The page scaffold — nav, page header, back link, related-games strip — was all there and correct. Analytics fired the pageview. The bankroll, the chip selector and the spin control rendered. Only the number grid, the largest single widget on the page, drew nothing at all. The space it occupied wasn't even collapsed to zero; it was just empty. The browser console was clean. Not "clean apart from a warning" — genuinely empty. Chrome DevTools' Elements panel showed what it al

2026-09-04 原文 →
AI 资讯

The CircleCI Cache Key Bug That's Silently Serving Your Builds Stale Dependencies

Your CircleCI pipeline is green. Every job passes. And yet your app is running against a dependency version that hasn't shipped in a month — nobody committed it, nobody bumped it, it just quietly showed up in production. If you've chased a bug like this, the culprit is almost never your code. It's your cache key. This is a five-minute read and a fifteen-minute fix. Quick Win Friday, deployed to your .circleci/config.yml . The failure mode CircleCI's dependency caching works on a simple contract: you compute a key from something that changes when your dependencies change (usually a lockfile checksum), and you save/restore a cache tied to that key. The contract breaks in three specific, extremely common ways: You checksum the wrong file. {{ checksum "package.json" }} looks reasonable until someone bumps a transitive dependency via package-lock.json without touching package.json . The checksum doesn't move. CircleCI happily hands back last week's node_modules . restore_keys does prefix matching, and people think it does exact matching. CircleCI tries your primary key first, then falls through restore_keys in order, and the first one is a prefix match against existing cache entries — not "give me the newest exact match." If your restore_keys list is too coarse (e.g. just v1-deps- ), you can restore a cache built from a completely different branch, with a completely different lockfile, and the job won't fail. It'll just quietly install nothing (cache hit, npm ci sees the modules are "there") or run against the wrong versions. There's no version escape hatch. When you inevitably need to force everyone's cache to invalidate — a corrupted cache entry, a package manager migration, a lockfile format change — there's no cheap way to do it, because the key format was never designed with a manual buster in mind. Each of these fails silently. No red X. No error in the logs. Just a build that ran with stale state, and a bug report three days later that nobody can reproduce locally

2026-09-04 原文 →
AI 资讯

LLMs Don't Have to Generate One Token at a Time: How Medusa and Multi-Token Prediction Cheat Autoregression

Hello, I'm Shrijith Venkatramana, and I'm building LiveReview — a blast-radius aware AI code review built for your business-critical systems. Star us to help devs discover the project, give it a try, and share your feedback to help improve the product. A modern LLM can contain hundreds of billions of parameters, run on extremely expensive accelerators, and still spend most of its inference time doing something that looks embarrassingly sequential: token 1 -> token 2 -> token 3 -> token 4 -> token 5 -> ... That is the awkward part of autoregressive generation. The model may process a whole prompt in parallel during the initial prefill, but once generation starts, the next token depends on the previous token. So generating 100 tokens looks conceptually like running the model 100 times. And for many serving workloads, that is exactly where the money goes. A family of techniques tries to break this bottleneck by asking a deceptively simple question: What if the model could predict several future tokens at once, then verify them in parallel? That idea leads to speculative decoding, Medusa-style multiple decoding heads, and the broader multi-token prediction approach used during training. The interesting part is that these are not merely "optimization tricks." They change the computational structure of decoding. This article develops that idea from first principles and then gets into the engineering details. 1. The problem: your GPU is doing an expensive sequential loop Consider ordinary autoregressive decoding. Given a prompt: The capital of France is the model predicts: Paris Then it feeds the new sequence back through the model: The capital of France is Paris and predicts the next token. Then again: The capital of France is Paris . and so on. Formally, the model factorizes the probability of a sequence as: P(x1, x2, ..., xT) = product over t of P(xt | x1, ..., x(t-1)) That conditional dependence is what makes language modeling so useful. It is also what makes decoding

2026-09-04 原文 →
AI 资讯

Don't claim a security boundary holds — demonstrate it

A system has to run a chunk of code you don't control —a plugin, a dependency, something generated— and you want to guarantee that code cannot touch the file system or spawn processes. Not that it "shouldn't": that it can't , mechanically. That's capability confinement, and it's one of the central problems of runtime security. Designing it and demonstrating it are two different things, and confusing them is expensive. A design is a claim You can write an impeccable document: "access to fs and to spawning processes is controlled like this, with these mechanisms, under this threat model". It's real and necessary work. But it's a claim . And the failure mode of a security boundary is that it looks like it holds until it doesn't —silent, invisible in tests, visible only when someone crosses it—. In security, an unverified claim has exactly the shape of a beautiful, wrong architecture. The design can assume that a module-loader hook fires at a point where it actually doesn't, and all the reasoning hanging off that is correct and worth nothing. The mechanisms exist, and there are several In Node, to name a concrete runtime, there are at least three layers, and they aren't interchangeable: The native permission model ( --permission , --allow-fs-read …), which cuts access to fs and to spawning processes at the whole-process level. SES / Hardened JavaScript (Compartments, lockdown() ), which confines what each module can import within the process. Module-loader interception , which controls what resolves when the code asks for something. Choosing well among them is the design. But choosing well doesn't prove the choice holds against the real dependency tree you're going to run. Demonstrate instead of claim The alternative to signing off a design is delivering a confinement harness : untrusted code that tries to reach the dangerous capability —open a file, spawn a process— against the real runtime and its real dependency tree, and a log that shows each attempt was blocked . O

2026-09-04 原文 →