AI 资讯
Beyond Blind Search: 5 Powerful Lessons from the Architecture of Intelligence
"Intelligence isn't about searching everywhere—it's about knowing where not to search." Artificial Intelligence is often associated with neural networks, large language models, and autonomous systems. But long before modern generative AI, computer scientists were solving a much deeper question: How do intelligent systems make decisions efficiently? Whether you're building search algorithms, recommendation systems, autonomous robots, or distributed systems, the architecture of intelligence teaches timeless lessons about solving problems under uncertainty. Let's explore five powerful ideas that shaped AI—and why they matter far beyond computer science. ✈️ 1. The Pilot's Dilemma: Why Blind Search Fails Imagine you're a pilot. Suddenly, one of your engines fails. In the next few seconds, there are hundreds of switches, buttons, and controls available. If you treated every control equally, you'd spend precious time trying random combinations. That is exactly how uninformed search works. Algorithms like: Breadth-First Search (BFS) Depth-First Search (DFS) have no knowledge of where the solution might be. They simply explore. Start ├── Option A ├── Option B ├── Option C └── ... The larger the search space becomes, the less practical this strategy is. A pilot doesn't blindly flip switches. They use additional knowledge : Engine pressure Fuel flow Hydraulic readings Warning systems Those clues dramatically reduce the number of possibilities. This is exactly what AI calls Informed Search . Instead of exploring everything, intelligent systems use knowledge to eliminate impossible paths before searching them. 🧠 2. Heuristics: The Cheat Code of Intelligence The secret behind informed search is something called a heuristic . A heuristic is simply an educated estimate. Mathematically, h(n) represents the estimated cost from the current state to the goal. One important rule always holds: h(goal) = 0 Once we've reached the goal, there's no remaining cost. Example: Finding Bucharest
AI 资讯
Your RAG Retrieved the Right Documents but Still Gave the Wrong Answer
Your retriever returned the right documents. The similarity scores look fine. The answer is still wrong. If you've shipped RAG, you've seen this — and it's the failure that survives every retrieval upgrade. What everyone tries Reranker. Higher top-k. Hybrid search. A better embedding model. All of these chase the same goal: documents more similar to the query. They help when the right document wasn't being retrieved. They do nothing when the right document was retrieved and the answer is still wrong. Why it doesn't work Similarity answers "is this chunk about the same topic?" It does not answer "does this chunk contain the facts needed to support the answer?" Those come apart constantly. A chunk can be highly similar — same vocabulary, same subject — and contain nothing that actually grounds the answer. Hand the model a pile of on-topic text and it will produce a fluent, plausible, even cited-looking answer. The grounding is cosmetic: the text was nearby, not load-bearing. High similarity with a wrong answer isn't a contradiction. You asked retrieval to find related text. It did. Nobody asked whether the text was enough. The one shift Stop treating retrieval output as evidence. Treat it as candidate material that has to pass an explicit evidence check before it can support an answer. Put a step between retrieval and generation: does the retrieved set actually contain the facts this answer requires? If not, abstain. When the documents don't contain the facts, the system should return nothing rather than a confident guess. Relevant context in, only sufficient evidence allowed through. That's the line between a RAG demo and a RAG system you can trust in production. I write about the three boundaries where production RAG dies — query, evidence, output — from the angle of shipping under security and model constraints. Read the full version on my blog , where this connects to the practical RAG Failure Diagnosis Kit for teams debugging production RAG.
AI 资讯
Try One of macOS 27’s Best Features Right Now
Apple’s fall macOS release will let you build Shortcuts by typing what you want to happen. But Claude Code and Codex users don’t have to wait.
AI 资讯
A prosthetic hand is now teaching an industrial robot & PepsiCo signed for autonomous freight. Here's what you missed this week.
PSYONIC's prosthetic touch data is now training ABB robots. Gatik signed the first Fortune 50 commercial autonomous freight contract with PepsiCo. Burro drove Physical AI onto the construction site. Experts set $20k as the humanoid price target. And someone just called Edge AI the Windows of robotics. This week, Physical AI crossed three invisible lines at once. A company that makes prosthetic hands figured out that the touch data from amputees is exactly what industrial robots need to learn how to grip. A Fortune 50 company signed not a pilot but a commercial contract for autonomous freight. A 44-horsepower robot drove off the warehouse floor and onto the construction site. And two separate conversations about software and pricing suggest that the next wave of robotics adoption will be driven by access, not capability. Here is what happened, and why it matters beyond the headlines. Value Description Fortune 50 PepsiCo becomes first to sign a commercial contract for autonomous freight with Gatik $20k Target price point for humanoid robots, Robotics Summit consensus: achievable by 2028–2030 1M hours Burro's field experience backing the Grande 44 autonomous outdoor platform 100+ Pressure sensors per fingertip in PSYONIC's Ability Hand, now training ABB GoFa A Prosthetic Hand Is Now Teaching an Industrial Robot How to Grip The standard approach to teaching a robot how to handle objects has been simulation, teleoperation, or labor-intensive physical demonstrations. PSYONIC and ABB just introduced a different source of data : the hands of people who have already learned to feel again. PSYONIC's Ability Hand is a prosthetic with more than 100 pressure sensors per fingertip . The company has been collecting kinesthetic data from users with upper-limb amputations. That data, which captures how a human hand adjusts grip pressure, contact area, and force across thousands of everyday tasks, is now being fed as training data into ABB GoFa robot arm models. The implication is no
AI 资讯
How I Cut My Multimodal AI Costs by 97% — A Freelancer's Guide
How I Cut My Multimodal AI Costs by 97% — A Freelancer's Guide Last month I almost killed a side gig because of a single line item on an invoice. A client wanted me to build a document-processing tool that could read scanned PDFs, pull text out of photos, and answer questions about charts. Easy enough — except I'd quoted the job assuming I'd use GPT-4o for the vision work. When I actually ran the numbers, I realized the API bill would eat my entire margin. I'd be working for free. Maybe worse. So I did what every freelancer does when the big-name vendor gets too expensive: I went hunting. And I landed on Global API, which routes to a bunch of multimodal models I've honestly never heard clients talk about. After a few weeks of testing, I figured out which ones are worth my billable hours and which ones aren't. This is everything I learned, plus the exact code I'm shipping to clients. Why Multimodal Even Matters for Solo Devs Two years ago, "multimodal" was a buzzword you'd hear at conferences. In 2026 it's table stakes. I've personally used vision models to: OCR receipts for an expense-tracking app (boring but pays the rent) Convert screenshots of legacy code into editable source for a Y2K-era company migration Read bar charts from PDF reports for a finance client who hates spreadsheets Analyze medical imaging samples for a startup MVP (this one was scary) Every one of those jobs started as a quick conversation with a prospect and turned into real invoices because I could say yes. The bottleneck was never capability — it was always cost. When GPT-4o charges north of $10/M output tokens, a single 2,000-token response on a tricky chart costs me about two cents. Multiply by 10,000 images per month and you've got a $200 API line item before you've paid yourself. That's a problem when the whole job is worth $400. So I tested every multimodal model I could find on Global API. Here's the lineup I ended up evaluating. The Contenders Nine models, three providers, one freelanc
AI 资讯
How I Run a 50-Agent AI Workforce on a Single 6GB GPU
Build-in-public. This is the real architecture behind running ~50 local AI agents on 6GB of VRAM — one GPU lock, an eviction watchdog, a resource governor, and a model router. Originally posted on my blog. The question I get most often is some version of "there's no way you run that many agents on a 6GB laptop GPU." The honest answer: not the way you're picturing it. I don't run 50 models at once. I run one model at a time, very deliberately — and most of the engineering is about scheduling, not inference. Here's the actual architecture. The hard constraint: 6GB of VRAM A single consumer GPU with 6GB of VRAM holds roughly one 7B-parameter model at a usable quantization. Two at once? It thrashes — the GPU starts swapping, latency explodes, and eventually a driver out-of-memory can take the whole machine down. I've had the desktop freeze from exactly that. So the first design rule wrote itself: only one heavy model is allowed on the GPU at any moment. That sounds limiting. It isn't — because almost nothing I run is latency-sensitive. A blog post that publishes at 7am doesn't care if it was generated at 6:52 or 6:58. Once you accept that your AI workforce is a batch system, not a chat window, the whole problem changes shape. A lock, not a crowd Every agent that needs the GPU has to take a lock first. It's a simple file-based queue with: FIFO ordering PID-based ownership Stale-lock detection, so a crashed job can't wedge the line forever If an agent can't get the lock within its timeout, it skips gracefully and tries again on its next scheduled run instead of piling up. So at 50 agents, what's really happening is: dozens of cron-scheduled Python workers wake up throughout the day, and the ones that need the model form an orderly line for it. The fleet is huge; the GPU contention is always exactly one. That's the trick. It's less "50 models" and more "50 employees sharing one very busy workstation, politely." Eviction and a VRAM watchdog Even with the lock, idle models l
开发者
Congrats to the Gemma 4 Challenge Winners!
We are so excited to announce the winners of the Gemma 4 Challenge! This is officially our most...
AI 资讯
llama-bench skipped FA on capable GPUs — b9437 corrects it
What flipped in b9437 Build b9437 , published on May 30, 2026 at 20:56 UTC , ships two targeted default-value corrections to llama-bench . Flash attention ( -fa ) shifts from a hard-coded off to auto ( LLAMA_FLASH_ATTN_TYPE_AUTO ), and the GPU-layer count ( -ngl ) changes from the legacy sentinel 99 to -1 . Both values now match what llama-server and llama-cli already used — the bench tool was simply never updated to track them until this build. Quick Answer: Before b9437 (published May 30, 2026) , llama-bench hard-coded -fa off , silently skipping flash attention even on CUDA, Metal, and Vulkan hardware. Build b9437 sets the default to -fa auto and -ngl -1 , matching llama-server and llama-cli . Any pre-b9437 baseline on FA-capable hardware needs a flag-matched re-run to remain valid. PR #23714 , reviewed and merged by maintainers JohannesGaessler and pwilkin, adds the same -fa auto|off|on tri-state flag to llama-bench that the rest of the toolchain already supported. With LLAMA_FLASH_ATTN_TYPE_AUTO as the new default, flash attention activates automatically when the runtime detects a capable backend (CUDA, Metal, Vulkan); on CPU-only hosts it stays off with no error and no output change. Parameter Before b9437 After b9437 Behavioral impact -fa off (hard-coded) auto ( LLAMA_FLASH_ATTN_TYPE_AUTO ) GPU-capable hosts bench with FA active by default; pre/post comparisons require explicit flag-matching -ngl 99 (offload-all sentinel) -1 (runtime decides) CPU-only builds no longer attempt full GPU offload; eliminates spurious CUDA errors when no GPU is present The following verified script (executed successfully, exit 0) demonstrates the behavioral gap in concrete terms — on a capable GPU, the pre-b9437 defaults schedule zero FA rows while b9437 defaults schedule one: def old_llama_bench ( device ): # Before b9437, the default bench matrix used FA=0, so FA rows were skipped. return [{ " device " : device [ " name " ], " ngl " : 0 , " fa " : 0 }] def b9437_llama_bench ( de
AI 资讯
Tim Cook says RAM expenses are ‘unsustainable’ and Apple is going to raise prices
Apple is planning to raise prices in response to the ongoing memory shortage. In an interview with The Wall Street Journal, Apple CEO Tim Cook says "price increases are unavoidable:" We're doing our best to mitigate the huge increases that are being passed to us, and we've been trying to shield our customers from the […]
AI 资讯
A model with R-squared near 0 can still give valid 90% prediction intervals - here's why (and the catch)
I recently calibrated a recovery-rate model that had only two weak features. Its point accuracy was almost nothing — R² basically zero. I expected its uncertainty estimates to be junk too. They weren't: the 90% conformal prediction intervals covered ~89% of held-out outcomes. Valid, just wide . That surprised me enough to nail it down, because it contradicts a belief a lot of us carry around: "my model isn't accurate, so I can't trust its uncertainty." For split conformal prediction, that's backwards. Here's the precise statement, a runnable demo, and the one caveat that actually bites. Coverage is a property of the procedure, not the model Split conformal prediction gives a distribution-free, finite-sample marginal coverage guarantee : P( Y ∈ Ĉ(X) ) ≥ 1 − α and it holds for any point model, as long as the calibration and test data are exchangeable. The model is a black box. You fit it however you like, then on a held-out calibration set you take the (1−α) quantile of the absolute residuals, and that quantile becomes the half-width of your intervals. Nowhere does that construction require the model to be good. A bad model just has large residuals, so the calibration quantile is large, so the intervals are wide — wide enough to still cover at the stated rate. Accuracy doesn't buy you validity ; it buys you efficiency (narrower intervals at the same coverage). The demo (numbers are reproducible, seed fixed) Same dataset and target, three models from strong to useless, target coverage 90%: model R² marginal coverage mean interval width gradient boosting 0.741 0.895 5.39 weak linear (1 noisy feature) 0.061 0.905 10.39 predict-the-mean −0.000 0.907 10.83 All three land at ~90% coverage. The only thing that changes is width: the good model's intervals are half as wide . That's the whole story in one table — validity is constant, efficiency tracks accuracy. import numpy as np from sklearn.linear_model import LinearRegression from sklearn.ensemble import GradientBoostingReg
AI 资讯
Neural Networks with PyTorch and Lightning AI Part 3: Moving Training Logic into Lightning
In the previous series, when we optimized our neural network, we had to write quite a bit of training code ourselves. First, we created an optimizer object that used Stochastic Gradient Descent (SGD) to optimize final_bias . Then we wrote loops to calculate the derivatives required for gradient descent. We trained the model for up to 100 epochs . For each training example, we: Ran the input through the neural network to get a prediction. Calculated the loss. Calculated the derivatives of the loss function. After processing all three training points, we used: optimizer . step () to take a small step toward a better value for final_bias . Then we used: optimizer . zero_grad () to clear the accumulated gradients before starting the next epoch. All of this required a considerable amount of training code. Let's see how Lightning helps simplify this process. Organizing Training Logic with Lightning Previously, we created a class to store the weights, biases, and the forward() function. The optimization-related code was written separately outside the class. With Lightning, we can keep all of this logic in one place. We start by creating the class as usual, and then add a few new methods. Configuring the Optimizer The first method is configure_optimizers() . def configure_optimizers ( self ): return SGD ( self . parameters (), lr = self . learning_rate ) This method tells Lightning how the neural network should be optimized. The learning rate is stored in the self.learning_rate variable that we defined earlier. Defining a Training Step Next, we add a method called training_step() . def training_step ( self , batch , batch_idx ): input_i , label_i = batch output_i = self . forward ( input_i ) loss = ( output_i - label_i ) ** 2 return loss This method receives: A batch of training data from the DataLoader. The index of that batch. Inside the method, we: Extract the input and label from the batch. Run the input through the neural network. Calculate the loss using the squared r
AI 资讯
What an LLM Actually Does: Predicting the Next Word, Explained
"How does ChatGPT think ?" It doesn't. The entire mechanism behind every chatbot is almost anticlimactic: it predicts one next word , adds it, and repeats. I built a tiny interactive predictor so you can be the model — and it explains both the magic and the flaws. 🔮 Be the model: https://dev48v.infy.uk/ai/days/day6-next-token.html This is Day 6 of AIFromZero — AI literacy, one concept a day, no code to follow. 1. It only predicts the NEXT word Given everything so far, the model outputs a probability for every possible next word, picks one, appends it, and runs again with the longer text. Paragraphs, code, poems — all of it is this one step on repeat. "the cat sat on the ___" → P(mat) high, P(bird) low 2. It's a probability over the WHOLE vocabulary The output isn't one word — it's a number for every word it knows (100,000+ for a real model). Most are near zero; a handful are plausible. The bars in the demo are that distribution, over a tiny vocabulary. 3. Autoregression: feed the output back in After picking a word, it becomes part of the input for the next prediction. Predict → append → predict again. Because each new word conditions on all the previous ones, short local choices add up to coherent long text. 4. Temperature = the creativity dial Once you have probabilities, how do you choose? Temperature reshapes them before sampling: Near 0: the top word always wins — safe, repetitive. High: the odds flatten, so rarer words get a real chance — creative, error-prone. p = p ** ( 1 / temperature ); // then renormalise and sample Drag the slider in the demo and watch the bars sharpen or even out. That one knob is what an API calls "creativity." 5. Where do the probabilities come from? In my toy, from counting which word followed which in a few sentences (a "bigram" with 1-word memory). A real LLM replaces the counting with a giant neural network trained on much of the internet, and its memory spans thousands of words. The mechanism is identical — only the quality of th
AI 资讯
Loss Functions: MSE vs MAE vs Cross-Entropy, Visualized
Pick the wrong loss function and your model optimises the wrong thing — perfectly. The loss is the single number training tries to shrink, so it quietly defines what "wrong" even means. I built an interactive visualiser of MSE, MAE, and cross-entropy so you can see why the choice matters. 🎯 Drag the prediction: https://dev48v.infy.uk/dl/day6-loss-functions.html This is Day 6 of DeepLearningFromZero. Loss = one number for "how wrong" The network's output is compared to the truth and collapsed into one scalar. Everything in training exists to make that number smaller. Choose the loss and you've defined the network's entire goal. MSE — square the error (regression) const mse = ( pred , y ) => ( pred - y ) ** 2 ; Squaring means off-by-4 hurts 16×, off-by-1 hurts 1×. MSE obsesses over large errors — great when big misses are unacceptable, risky when outliers will drag the model around. MAE — absolute error, outlier-robust const mae = ( pred , y ) => Math . abs ( pred - y ); Linear penalty: off-by-4 hurts exactly 4× off-by-1. One wild outlier can't dominate. The trade-off is a constant gradient, so it can be slower and less precise near the answer. Cross-entropy — for classification When the output is a probability, you don't use MSE. Cross-entropy rewards confident-and-right and brutally punishes confident-and-wrong: const bce = ( p , y ) => - ( y * Math . log ( p ) + ( 1 - y ) * Math . log ( 1 - p )); Predict 1% for the true class and the loss screams toward infinity. In the demo, switch to Classification and slide p toward 0 to watch it explode. The slope is what learning actually uses Backprop doesn't follow the loss value — it follows the loss's gradient (slope) downhill. That's why the shape matters: cross-entropy's steep slope when very wrong gives a strong corrective push, helping classifiers learn faster than MSE would. grad = dLoss / dPred ; // gradient descent steps along this Choosing the loss is a design decision Predicting a price? MSE or MAE. Yes/no? Binary
AI 资讯
Naive Bayes From Scratch: A Spam Filter Built From Word Counts
Naive Bayes ran real spam filters for years, and it's the rare ML model whose "training" is just counting . No gradient descent, no iterations — count words, apply Bayes' rule, multiply. I built one from scratch and visualised exactly which words push a message toward spam. 📨 Interactive demo (type a message): https://dev48v.infy.uk/ml/day6-naive-bayes.html This is Day 6 of MachineLearningFromZero — algorithms from scratch, no scikit-learn. 1. Bag of words — order doesn't matter Naive Bayes treats a message as a set of words. "free cash now" and "now cash free" look identical to it. That throws away grammar, but for spam detection the words present matter far more than their order — and it makes the math tiny. 2. Training = counting For every word, how often does it appear in spam vs ham? for ( const { text , label } of trainingData ) for ( const w of tokenize ( text )) counts [ label ][ w ] = ( counts [ label ][ w ] || 0 ) + 1 ; free and click flood spam; meeting and tomorrow live in ham. One pass over the data, done. 3. Bayes' rule flips the question You measured P(words | spam) , but you want P(spam | words) . Bayes flips it: P(spam | words) ∝ P(spam) × P(words | spam) P(spam) is the prior (how common spam is); the likelihood multiplies in the word evidence. 4. "Naive" = pretend words are independent The trick that makes it fast: assume each word is independent given the class, so the likelihood is just a product: P(words | spam) = P(w1|spam) × P(w2|spam) × ... Real words aren't independent ("credit" and "card" co-occur), so it's a naive lie — but the classification still lands right astonishingly often. 5. Smoothing + logs keep it stable Two practical fixes. Add 1 to every count (Laplace smoothing) so an unseen word doesn't zero out the whole product. And add logarithms instead of multiplying tiny probabilities, which would underflow to 0: score [ label ] = Math . log ( prior [ label ]); for ( const w of words ) score [ label ] += Math . log (( counts [ label ][
AI 资讯
Vibe citing: how KPMG used AI to write a report about AI and AI made them look like fools
vibe citing: how KPMG used AI to write a report about AI and AI made them look like fools by t474-r0b07 There are companies that charge you to tell you how to use AI responsibly. KPMG is one of them. 250,000 employees. 138 countries. Decades advising governments and corporations on how to avoid costly mistakes. In October 2025 they published a report titled "Total Experience: Redefining Excellence in the Age of Agentic AI" . They wrote it with AI. The AI invented 88% of the sources. Nobody verified anything. They published it anyway. // what is "agentic AI" — because the title matters An agentic AI is not a chatbot. Not the assistant that answers your questions. It's a system that makes decisions and executes actions on its own, without a human approving each step. You give it an objective and it acts, corrects, moves forward. It's the product everyone in the tech sector was selling in 2025. KPMG was selling it too. That's why they needed a report proving their clients were already using it. Spoiler: they weren't. And the report invented it anyway. // the forensic analysis GPTZero — a company specialized in detecting AI-generated content — ran a full audit on the report. First: what is an AI hallucination, because the term is going to come up a lot. When a language model doesn't have the information you ask for, it doesn't say "I don't know." It generates a response that sounds correct. It invents with the same confidence it would use if it actually knew the truth. Perfect format. False content. No warning. That's a hallucination. Now the numbers from the KPMG report: TOTAL CITATIONS: 45 REAL CITATIONS: 5 INVENTED CITATIONS: 40 ACCURACY RATE: 11.1% 40 of 45 citations have invented titles, authors that don't exist, or sources that don't say what KPMG claimed they said. Half of the factual claims in the report are false or misattributed. A firm that charges for intellectual rigor published a document with 11% accuracy. // the organizations that read the report and sai
AI 资讯
How I Cut Costs 65% Migrating LangChain to DeepSeek
How I Cut Costs 65% Migrating LangChain to DeepSeek I want to tell you about a switch I made recently that genuinely surprised me. If you're running LangChain in production and haven't explored the DeepSeek models yet, this one's for you. Let me show you what I learned, what broke, and what I'll never go back to. The short version? I was burning cash on a generic LLM setup. I migrated to DeepSeek through Global API's unified interface, and my monthly inference bill dropped by over 60%. Setup took me less time than brewing coffee. Let me walk you through it. Why I Even Looked at This in the First Place Here's the thing about working in AI engineering: the model landscape moves so fast that whatever you chose six months ago is probably overpriced now. That's been my experience, anyway. When I first built my LangChain pipeline, I defaulted to a popular name-brand model because, well, that's what everyone was using. It worked. It was fine. Then I looked at my AWS bill. That's when I started digging into alternatives. And let me tell you, the rabbit hole is deep. Global API alone exposes 184 AI models at prices ranging from $0.01 to $3.50 per million tokens. That's a wild spread. The trick is finding the sweet spot where cost meets quality, and for migration workloads (think: code translation, schema conversion, content rewrites), I found it with DeepSeek. Let me show you the numbers that actually mattered to me. The Pricing Reality Nobody Talks About I built a comparison table when I was making this decision, and I want to share it because staring at these numbers side by side is what convinced me. Here's the lineup I evaluated through Global API: DeepSeek V4 Flash sits at $0.27 per million input tokens and $1.10 per million output tokens, with a 128K context window. That's my default for most production traffic now. Fast, cheap, and smart enough for almost everything. DeepSeek V4 Pro comes in at $0.55 input and $2.20 output with a beefier 200K context. I use this when
AI 资讯
Email Triage Taxonomies for LLM Classification
The most important design decision in an email classifier isn't the model — it's the label set, and here's the one I keep coming back to: You triage email into one of four categories: URGENT — production incidents, executive requests; reply within 1 hour ACTION — code reviews, meeting follow-ups; reply same day FYI — informational, no response needed NOISE — newsletters, marketing, automated notifications From: {sender} Subject: {subject} Snippet: {snippet} Return ONLY the category name. Nothing else. That's the working prompt from the Nylas email triage recipe , and almost every line encodes a taxonomy-design lesson worth unpacking. Most people building email agents obsess over model choice and prompt phrasing. The recipe's quiet thesis is that the label set itself does the heavy lifting — get the taxonomy right and a cheap model classifies well; get it wrong and no model saves you. Why four is the magic number The recipe states it flatly: four is the right number. Three loses fidelity — everything important collapses into one overloaded bucket and you've built a binary classifier with extra steps. Five and the model starts confusing categories, because the boundaries between adjacent labels get too thin to express in a definition. Notice what makes these four work. They aren't topics — they're response obligations . URGENT means "reply within the hour," ACTION means "reply today," FYI means "no response needed," NOISE means "archive." Each label maps to exactly one behavior. That's the test I'd apply to any email taxonomy: if two labels lead to the same action, merge them; if one label leads to two different actions depending on content, split it. The same principle shows up in the sales context. The Agent Accounts overview describes an outreach agent classifying replies as interested / not now / unsubscribe — three labels, because the workflow has exactly three branches: book the meeting, schedule a follow-up, stop emailing. The taxonomy is the decision tree, fla
AI 资讯
Fast Automatic ML Hyperparameter tuning Using Optuna (w. MLflow model registry and IRIS DB)
This article presents a straightforward approach to automatically and efficiently tune hyperparameters for machine learning models using Optuna as the optimisation framework. We explore how to use both Optuna’s native storage options and InterSystems IRIS as a database backend to track the progress of hyperparameter searches. We also show how MLflow can be used to monitor experiments and manage models through its tracking and model registry UI. This article is based on this Kaggle Notebook , which you can run and directly edit yourself. When training ML models, the choice of hyperparameters can strongly influence performance. They are not the only factor, but they can significantly affect both convergence and generalisation. Tuning hyperparameters manually takes a lot of effort. This is especially true because hyperparameters interact with each other, so tuning them independently is usually not enough. For example, higher regularisation may require a lower learning rate for more stable optimization. A more complex model may require stronger regularization to avoid overfitting, but at the same time, a very small learning rate on a complex model can make learning too slow. Optuna is an MIT-licensed open source library, which allows commercial use, that automates hyperparameter search for ML models developed with the most popular frameworks such as scikit-learn, PyTorch, TensorFlow, and LightGBM. It works by defining a search space and an objective metric to either minimize or maximize. Optuna then explores the search space efficiently to find well-performing configurations. Here we use Optuna to tune a LightGBM model on a dummy dataset and show how to scale the search using shared database storage. We will also use MLflow for experiment tracking and model registry, and IRIS DB as a possible Optuna storage backend for concurrent studies. We will use the California Housing dataset, commonly used in ML examples, to populate IRIS tables and run the tuning workflow. Note:
AI 资讯
How I Built Production-Grade AI Systems While Still a Student
🚀 Hello, DEV Community! I'm Nader Al Shawki , a final-year AI Engineering student at Al-Razi University, Yemen. This is my first post here, and I'm excited to start sharing my journey with this amazing community. 🎯 Who Am I? I'm passionate about building production-grade AI systems that solve real-world problems. My main areas of focus are: 🖼️ Computer Vision & Deep Learning 🤖 ML Model Deployment (Docker, FastAPI, REST APIs) 🧠 LLMs, RAG, and AI Agents (currently learning) 📊 Data Visualization & Analytics (Power BI) 💡 What I've Built So Far 1. 🍅 Tomato Leaf Disease Detection Platform Tech: YOLOv8, PyTorch, FastAPI, Docker What it does: Detects tomato leaf diseases from images with real-time inference. Containerized with Docker for easy deployment. 2. 🫁 Pneumonia Detection System Tech: PyTorch, CNN Architecture, Medical Imaging What it does: A deep learning model that detects pneumonia from chest X-ray images. 3. 📊 Sales Profit Analysis Dashboard Tech: Power BI, DAX, Data Analysis What it does: Interactive dashboard for tracking sales KPIs. 4. 😀 Face Detection & Emotion Recognition Tech: OpenCV, Deep Learning What it does: Real-time face detection, age estimation, emotion recognition, and gender classification. 5. 🍽️ Restaurant Website Tech: HTML5, CSS3, JavaScript What it does: Fully responsive restaurant website with interactive UI. 🌱 What I'm Currently Learning LLMs (Large Language Models) RAG (Retrieval-Augmented Generation) LangChain & AI Agents Workflow automation with n8n 🔗 Let's Connect 🐙 GitHub: Naderalshawki 💼 LinkedIn: in/nader-al-shawky 📫 Email: naderalshawki@gmail.com Thanks for reading! I'll be posting regularly about AI projects, tutorials, and lessons learned. Stay tuned! 🚀
AI 资讯
Why Most AI Startups Waste Money on GPUs
Every day, startups rent expensive GPUs to power AI applications. The problem is that most of those GPUs spend a surprising amount of time doing nothing. Imagine renting an apartment and only using one room while paying for the entire building. That's effectively what many AI teams do with GPU infrastructure. The Hidden Cost of GPU Rentals When you rent a GPU, you're usually paying for uptime. Whether your application is processing requests or sitting idle at 3 AM, the bill keeps running. For many early-stage products: Traffic is inconsistent Usage spikes are unpredictable Most requests arrive in short bursts As a result, GPU utilization can be far lower than expected. The Utilization Problem A startup might rent a GPU for an entire month. But how much of that compute is actually being used? During development: Developers test occasionally Demos happen a few times a day Customer requests arrive sporadically The GPU remains available 24/7, but actual inference workloads often occupy only a small fraction of that time. Yet the infrastructure bill reflects full-time usage. Why This Matters For startups, infrastructure costs directly affect runway. Every dollar spent on idle compute is a dollar that cannot be spent on: Product development Customer acquisition Hiring Experiments Reducing wasted infrastructure spend can significantly improve efficiency. A Different Model Instead of paying for GPU uptime, what if developers only paid when inference actually occurred? For example: Pay per token generated Pay per image generated Pay per second of video generated This approach aligns cost with actual usage rather than reserved capacity. The Future of AI Infrastructure As AI adoption grows, efficiency becomes increasingly important. The next generation of AI infrastructure may look less like traditional server rentals and more like utilities: Use what you need. Pay for what you use. Nothing more. What has your experience been with GPU utilization and AI infrastructure costs? I