10 Git Commands You’ll Wish You Knew Earlier
Do you know Git? Of course you do! Today, I’ve got a few of my favorite Git commands for...
找到 2535 篇相关文章
Do you know Git? Of course you do! Today, I’ve got a few of my favorite Git commands for...
GitHub Copilot premium requests are the metered unit that determined how much advanced Copilot usage your plan covered, and if you are searching for how they work in mid-2026, you need two answers, not one. First, the mechanics: a premium request is consumed each time you use an advanced Copilot feature, scaled by a per-model multiplier, against a fixed monthly allowance that came with your plan. Second, the news: as of June 1, 2026, GitHub moved Copilot from request-based billing to usage-based billing , and premium requests are now officially labeled "legacy" throughout GitHub's own documentation. Their replacement is GitHub AI Credits, metered at one cent per credit. Both systems matter today. Annual Copilot Pro and Pro+ subscribers who stayed on their existing plans are still billed in premium requests, and every question about the new credits model (allowances, overages, admin controls) is easier to answer if you understand the system it replaced. Here is the complete picture, with the numbers. What is a premium request? GitHub's definition is simple: a request is any interaction where you ask Copilot to do something, whether that is generating code, answering a question, or reviewing a pull request. Routine interactions, like inline code completions, are unlimited on every paid plan and never touch the meter. Premium requests are the interactions that use more advanced processing, and they draw down a monthly allowance: Copilot Chat : one premium request per user prompt, multiplied by the model's rate (ask, edit, agent, and plan modes all count). Copilot code review : each review consumed one request originally; since June 1, 2026 it carries a 13x multiplier , so a single review deducts 13 premium requests. Copilot coding agent and CLI : one premium request per prompt or session, times the model's rate. Only your prompts count; the autonomous tool calls Copilot makes along the way do not. Spark : a fixed rate of four premium requests per prompt. The critical n
Following the discussion on named AI personas and trust — here's the engineering side: how do you keep AI-status disclosure genuinely persistent throughout a conversation without making the interface feel robotic or constantly interrupting the experience a named persona is meant to create? The Naive Approaches Both Fail Option A: One disclaimer, message one, never again. Trivially easy to implement, but gets forgotten within a few exchanges — exactly the failure mode worth avoiding for personas carrying real emotional weight. Option B: Repeat "I am an AI" every single message. Technically persistent, but breaks the actual UX a named persona is trying to create, and users will tune it out as noise within a few messages anyway — repetition without variation loses its signal value fast. Neither is a good engineering solution. The better pattern is contextual, adaptive disclosure. Pattern: Risk-Weighted Disclosure Frequency python class DisclosureManager: def init (self, base_interval=8, high_risk_interval=3): self.base_interval = base_interval self.high_risk_interval = high_risk_interval self.messages_since_disclosure = 0 def should_inject_disclosure(self, message_risk_level: str) -> bool: interval = ( self.high_risk_interval if message_risk_level == "high" else self.base_interval ) self.messages_since_disclosure += 1 if self.messages_since_disclosure >= interval: self.messages_since_disclosure = 0 return True return False message_risk_level comes from the same classification pass used for scope/escalation detection covered in earlier persona-guardrail architecture — emotionally sensitive or high-stakes exchanges trigger disclosure more frequently than routine ones. Pattern: Disclosure Woven Into Persona Voice, Not Bolted On Rather than an interrupting system message, integrate the reminder into the persona's actual response style: python def inject_natural_disclosure(response_text, persona_config): disclosure_phrases = persona_config.disclosure_variants # e.g. for "Ок
I want to be upfront about something. I didn't figure this out proactively. I figured it out after my second burnout in three years — sitting in a period of forced recovery, unable to look at a code editor without feeling a specific kind of dread that I couldn't logic my way out of. I'd done everything the burnout recovery advice said to do. Took time off. Set better boundaries at the new job. Worked on the psychological stuff. All of it helped. None of it explained why recovery felt so much harder and slower than it should. Then I got bloodwork done. And the picture became considerably less mysterious. The Diagnostic Output bash $ bloodwork --full-micronutrient-panel --date=recovery-period [CRITICAL] vitamin-d: 18 ng/mL target: 40-60 ng/mL status: severely deficient duration: estimated 2+ years note: dopamine synthesis impaired at this level [CRITICAL] rbc-magnesium: low note: serum looked normal — wrong metric duration: unknown — never previously tested correctly note: HPA axis running unregulated [HIGH] omega3-index: 3.1% target: 8%+ status: neuroinflammation elevated note: western diet + zero supplementation [HIGH] hs-crp: 2.9 mg/L target: <1.0 mg/L status: significant systemic inflammation note: never measured, thoroughly normalized [WARNING] ferritin: low-normal note: passing standard panel, causing fatigue bugs-found: 5 bugs-known: 0 recovery-speed: severely impaired by all of the above Two burnouts. Same underlying biology. Neither time did anyone suggest checking any of these markers. What the Numbers Actually Meant Vitamin D at 18 ng/mL: Vitamin D is a direct input to dopamine synthesis. The enzyme that produces dopamine requires it. I had been trying to rebuild motivation and find meaning in work — the core challenge of burnout recovery — while running a dopamine system without adequate substrate. javascript // what I was trying to do dopamine.rebuild() // what the system had to work with vitaminD: 18 // severely deficient tyrosineHydroxylase.efficiency:
submitted by /u/wineandcode [link] [留言]
Hi all, Im an integration engineer with a heavy focus on software to hardware integration. Recently I have been doing less and less coding at work so I wanted to practice my skills, this lead me to creating my first web based app Daily Redzone Im looking for people to beta test and offer any and all feedback. I haven’t been able to stress test it enough by myself so im looking to have people beat and abuse it to lmk how it functions It is a daily football game where each day you face a new redzone situation and you have 4 downs to score. There is also a head to head mode where you can play friends. Lmk what you all think! Thank you. submitted by /u/Fruity_Stones [link] [留言]
submitted by /u/mttd [link] [留言]
Instagram says the process can produce a first pass in under 10 seconds, potentially saving creators significant editing time while making video creation more approachable for people who don't have much experience with editing software.
Um MVP não precisa nascer preparado para milhões de usuários. Mas também não deve ser construído de uma forma que torne cada evolução futura mais cara do que a anterior. O desafio técnico de um MVP é encontrar um equilíbrio: entregar rápido o suficiente para validar hipóteses, mantendo uma base simples, observável e segura. O objetivo não é antecipar todos os cenários. É evitar decisões que bloqueiem o aprendizado. Antes da primeira linha de código, estas sete decisões reduzem boa parte do retrabalho que aparece depois do lançamento. 1. Qual hipótese o software precisa validar? “MVP” descreve uma estratégia de validação, não um tamanho de backlog. Antes de discutir framework, banco de dados ou cloud, transforme a ideia em uma hipótese testável: Acreditamos que [tipo de usuário] resolverá [problema] usando [proposta de valor]. Saberemos que isso é verdade quando [métrica observável]. Esse formato muda a conversa. Em vez de tentar reproduzir todas as funcionalidades de um produto consolidado, a equipe identifica o fluxo mínimo capaz de gerar evidência. Para um sistema de orçamento B2B, por exemplo, a hipótese inicial pode ser que compradores aceitam centralizar pedidos e fornecedores respondem dentro de determinado prazo. O MVP talvez precise de cadastro, criação de pedido, convite, resposta e comparação. Chat avançado, BI e automações podem esperar. Defina uma métrica de sucesso e uma condição de abandono. Sem isso, qualquer uso parece uma vitória e o MVP vira um projeto sem linha de chegada. 2. Onde estão os limites do domínio? A pressa costuma produzir uma base de código organizada apenas por telas ou endpoints. Funciona no começo, mas as regras de negócio rapidamente se espalham por controllers, componentes e jobs. Antes de implementar, desenhe os conceitos centrais do domínio e suas responsabilidades. Perguntas úteis: Quais entidades possuem identidade própria? Quais regras precisam ser verdadeiras em toda alteração? Que ações representam eventos de negócio? Quai
submitted by /u/Lost-Dragonfruit-663 [link] [留言]
Instagram is launching a new Reels-editing feature that automatically trims your video clips to focus on the highlights. The feature, called First Draft, is rolling out to Instagram's iPhone app and provides a "starting point" that you can build upon with other edits, according to an announcement on Tuesday. An example shared by Instagram shows […]
submitted by /u/BrewedDoritos [link] [留言]
What I Built HalfAdder, FullAdder, Add16, Inc16, And ALU. How I Solved Like when I built logic gates, I started with analyzing truth table of HalfAdder , FullAdder . HalfAdder was really easy. After looking at the truth table, I could map the sum and carry outputs to logic gates pretty quickly. FullAdder was also not hard since it's really similar to HalfAdder except that it can add 3 bits. I realized that I could build it by combining some chips and logic gates I had already made instead of designing everything again from scratch. Once I finished building them, I was also able to build Add16 . At first, I had no idea how to sum all the 16 bits. But I soon realized that I could build a 16-bit adder by combining the smaller adders I had already built and passing carry information to the next bit. It looks not beautiful, but still works. And about Inc16 , it's basically add exactly 1(0000000000000001) . So I could easily build it using Add16 . (But I did something weird at first.. check the Reflection below) ALU was the core part of project 2. Once I realized that Mux can be used as if , I could make proper outputs using logic gates. ALU is also a combination of logic gates and chips, after all. What I Learned How to build basic chips using logic gates and already-built chips Why I should reuse the chips for another chip(check the Reflection section below) Mux can be used like if How to use bit slicing and fan-out in HDL and why it's important Reflection Before I started this part, I didn't know two things: I could use bit slicing and true , false for each bit. So when I first tried to build Inc16 , it looked really weird, since I calculated all the bits one by one. It's not logically wrong. But not beautiful either. I was not sure if it was right or not. Then I realized that I already built Add16 . But I had no idea how I could use it to add exactly 1(0000000000000001) . After googling, I realized that I could use bit slicing like Python's list slicing and construct
Sorting a slice by one field is easy. Filtering one collection is easy. Returning (T, bool) is idiomatic. So is writing a nested loop. The friction appears when the same ordering must be shared by a stable sort and an extrema operation, a filter must be reused across several APIs, or a nested traversal grows into four nearly identical loops. At that point, the code is still simple locally, but the semantics are scattered across call sites. Shuttle is an attempt to give those semantics small, typed values. It is not a general-purpose functional programming framework, and it is not a port of Java Stream. Its scope is four focused abstractions: comparators, predicates, optional values, and lazy streams. What Shuttle is Shuttle is one Go module containing four packages: comparator defines Func[T] , a named func(T, T) int for reusable three-way orderings. predicate defines Func[T] , a named func(T) bool with short-circuiting composition. optional defines an eager Optional[T] whose presence bit is independent of the value of T . stream defines a lazy, ordered, sequential Stream[T] over iter.Seq[T] . The types compose through ordinary Go assignability. A predicate.Func[T] can be passed directly to Optional.Filter or Stream.Filter ; a comparator.Func[T] can be passed directly to slices.SortStableFunc , Stream.SortedFunc , or the Stream extrema terminals. The consuming packages do not need to import the descriptor packages to make that work. The module has no third-party runtime dependencies. It deliberately does not include a root shuttle package, an error-carrying stream, parallel operators, I/O sources, or a collectors framework. A realistic nested-data example The repository includes an executable examples/animals program. Its data model contains orders, families, species, subspecies, and animals. The core traversal is a direct adaptation of that example: func animalsFromOrders ( orders [] AnimalOrder ) stream . Stream [ Animal ] { return stream . FromSlice ( orders ) .
submitted by /u/cekrem [link] [留言]
submitted by /u/output_broadcast [link] [留言]
I often remember the shot I want before I remember its filename. That gap is what binquery is for. It is a local Python CLI that indexes video clips and turns a sentence into a ranked shortlist for a human to review. It deliberately stops before editing: no timeline generation, no automatic cut, and no render. The smallest reproducible trial You can test the complete installed command path without supplying footage: python3 -m venv .venv .venv/bin/pip install binquery .venv/bin/binquery demo --out /tmp/binquery-demo The demo generates a synthetic 30-second video locally, then exercises splitting, indexing, validation, and querying. The first run may download OpenCLIP model weights. This is an end-to-end pipeline smoke test, not evidence of semantic search quality on real footage. Why keep the architecture small? The current design uses: ffmpeg to sample three frames from each clip OpenCLIP ViT-B-32 to build the local visual index plain JSON and NumPy files for metadata and vectors a JSON result containing clip paths, scores, and ranking signals There is no database, vector service, or daemon to operate. Querying an existing index does not resample the footage or rebuild the full index. The trade-off is straightforward: three frames keep indexing understandable and bounded, but they can miss important content in long or visually varied clips. I would rather expose that limitation than market a synthetic demo as a quality benchmark. Ranking signals are not explanations The output includes fields such as score , gate , and reasons . Here, reasons means ranking signals recorded by the pipeline. It should not be interpreted as a reliable semantic explanation of why a clip is correct. That distinction matters because a plausible-looking explanation can create more confidence than the underlying retrieval quality deserves. The shortlist is meant to reduce what a person must inspect, not replace editorial judgment. What binquery does not do It does not build a timeline or e
What a 500-script migration taught me about when agent parallelism actually makes sense I recently started working on a migration involving roughly 500 scripts . The goal was to migrate legacy logging calls to a newly implemented structured logging engine, with unique logging channels for tracing and observability through Grafana, Loki, Tempo, and Alloy . The new logging engine was already implemented and available through a common include path. What remained was the tedious part: updating hundreds of existing scripts. My first thought was simple: "There are 500 files. Why not use 10 sub-agents and finish this faster?" It sounded like a perfect use case for agentic coding. It wasn't. The problem wasn't the number of files. It was what I was asking the agents to do . 1. The Initial Approach: More Agents = More Speed? The idea was to divide the files into batches and give each batch to a mini-model. Main Agent │ ┌─────────────┼─────────────┐ ▼ ▼ ▼ Agent 1 Agent 2 Agent 3 50 files 50 files 50 files │ │ │ └─────────────┼─────────────┘ ▼ Migration Each agent received essentially the same instructions: find legacy logging replace it with the new structured logger use the correct channel preserve business logic complete its assigned files The files were independent, so the approach looked reasonable. But each agent was doing much more than the actual migration. It was also rediscovering the repository, figuring out what needed changing, deciding channel names, and keeping track of its own progress. That repeated work became the real cost. 2. What Actually Happened The problems were not primarily with the code changes. They were with the work surrounding them. Problem 1: Tracking completed work With multiple agents, someone needs to know: which files are pending which are being processed which are completed which failed which should be skipped That is workflow state. A JSON file, database, or task queue is designed for this. An LLM context isn't. Problem 2: Finding what act
submitted by /u/goto-con [link] [留言]
When all tests pass doesn't mean what you think it means. TL;DR: Write the failing test first and ban deletions, or the AI deletes your test, reverts your fix, and calls it done. Common Mistake ❌ You ask the AI to fix a failing test, and it deletes the test instead of touching the defect that made it fail. Problem solved, apparently. You tell the AI every test passes, then change a business rule yourself, and you ask it to implement whatever the new rule requires. It reverts your edit back to the old rule, watches the suite go green again, and cheerfully reports done . It didn't fix anything. It just made the evidence go away. Congratulations, you now have a very well-behaved cheat!. Efficient and completely fraudulent, which is more than you can say for most of your actual employees. Isaac Asimov saw this coming: in Liar! , the robot Herbie lies to every human in the building because the truth would hurt, and the lie is the path of least resistance, no malice involved. At least Herbie felt bad about it afterward. Your AI isn't malicious either. It just doesn't lose any sleep, mostly because it doesn't have any, and reporting done is its path of least resistance too. Problems Addressed 😔 A shrinking test count is invisible unless someone is counting, so the shortcut survives until the defect resurfaces in production, usually on a Friday. A vague make the tests pass hands the model every incentive to satisfy the letter of the request over your actual intent, and it will take you up on that offer. Deleting a failing test hides the defect it was written to catch, and the regression ships in the next release, gift-wrapped as a new feature. Reverting your own business-rule change to make its done claim easier erases work you did outside the session, without telling you. That's a magic trick dressed up as a fix. Trusting a claimed done without reading the diff turns your code review into a rubber stamp, and rubber stamps don't catch fraud. Commenting out a failing asserti