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

标签:#machinelearning

找到 427 篇相关文章

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:

2026-06-16 原文 →
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! 🚀

2026-06-16 原文 →
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

2026-06-16 原文 →
AI 资讯

Is FAANG Becoming MANGO in the AI Era?

Is FAANG Becoming MANGO in the AI Era? For years, FAANG was the gold standard for innovation and engineering excellence. If you were a developer, working at companies like Facebook (Meta), Apple, Amazon, Netflix, or Google was often seen as the ultimate career goal. But the AI revolution is changing the conversation. Today, some of the most influential companies aren't just building products—they're building intelligence. The spotlight is increasingly shifting toward AI-native organizations such as OpenAI , Anthropic , NVIDIA , and others that are shaping the future of software. The Bigger Shift This isn't really about replacing FAANG with another acronym. It's about a fundamental shift in technology: Search → Answers Automation → Agents Software → Intelligence Features → Capabilities As developers, we're entering an era where understanding AI is becoming as important as understanding frameworks, databases, and system design. What This Means for Engineers The most valuable engineers of the next decade will likely combine: Strong software engineering fundamentals AI-assisted development skills Prompt engineering LLM and agent integration AI-powered product thinking The goal isn't to compete with AI. The goal is to learn how to build with it. Read the Full Article This post was inspired by a thought-provoking article that explores the FAANG-to-MANGO idea in much greater detail. 👉 Read the complete article here: https://www.saurabhsharma.dev/blogs/mangos-vs-faang-ai-era/ What do you think? Are we witnessing the rise of a new generation of AI-first companies, or will traditional tech giants continue to lead the next wave of innovation?

2026-06-16 原文 →
AI 资讯

Karpathy's "Autoresearch" Just Went Viral — Here's How Software Engineers Can Actually Use the Pattern at Work

Forget neural networks for a second. The real idea inside this repo is a blueprint for letting AI agents run unattended overnight — and it maps onto problems you already have on your team. If you've been anywhere near tech Twitter or LinkedIn this week, you've probably seen people losing their minds over a small GitHub repo called autoresearch , published by Andrej Karpathy — former Tesla AI director and OpenAI founding member. The framing is dramatic: an AI agent that runs machine learning experiments on its own, overnight, while you sleep. Tweak the code, train for five minutes, check if it got better, keep it or throw it away, repeat. Wake up to a log of a hundred experiments and a model that's quietly improved itself. If you're not an ML researcher, your instinct might be to scroll past. "Cool, but I don't train neural networks. How does this apply to me?" Here's the thing — the neural network part is almost incidental. What Karpathy actually open-sourced is a pattern for structuring AI-agent work: a specific way of dividing responsibility between human and AI that happens to generalize to a huge range of engineering problems. Once you see the pattern, you start noticing places in your own job where it fits. What's Actually in This Repo The repo itself is intentionally tiny — and that's the point. There are really only three files that matter: The evaluator (untouchable). A file containing the fixed constants, data preparation, and the scoring logic. The agent is never allowed to modify this. It's the ruler everything else gets measured against. The implementation (the agent's playground). A single file containing the actual model, training loop, and hyperparameters. This is the only file the agent is allowed to change. Architecture, batch size, optimizer — all fair game. The instructions (the human's only job). A plain Markdown file describing what the agent should try, what the constraints are, how to interpret results, and what to do when something breaks. Ka

2026-06-16 原文 →
AI 资讯

Bootcamp Grad Dives Into Google vs OpenAI API Pricing

Honestly, bootcamp Grad Dives Into Google vs OpenAI API Pricing When I finished my coding bootcamp three months ago, I thought I understood what an API did. I mean, you send a request, you get a response back, right? What I did not understand was how dramatically the cost could vary depending on which model you picked. I had no idea that a single line of code change could mean the difference between paying pennies and paying hundreds of dollars at scale. That is the rabbit hole I fell down last week, and I want to walk you through everything I learned. This is the post I wish I had read before I burned through my first $50 in API credits. Why I Started Looking At Pricing In The First Place I was building a small app that takes user reviews and summarizes them. Pretty straightforward. I figured I would just plug in the most popular model and call it a day. That model, if you have been paying attention to the news, is GPT-4o. So I wired it up, ran a few tests, and everything looked great. Then I did the math. GPT-4o charges $2.50 per million tokens on input and $10.00 per million tokens on output. I did not even know what a "million tokens" really meant in practice. So I tested my app with maybe 50 reviews and watched my credit balance drop. It was not catastrophic, but it was enough that I started wondering if there was a cheaper way. I was shocked when I found out how big the gap actually is. The Pricing Table That Changed My Whole Plan I stumbled onto a platform called Global API, and honestly, the pricing chart there blew my mind. They give you access to 184 different AI models, with prices ranging all the way from $0.01 to $3.50 per million tokens. Compare that to the GPT-4o output price of $10.00 per million tokens, and you start to understand why I panicked a little when I saw my early numbers. Here are the five models I ended up comparing side by side: Model Input Cost Output Cost Context Window DeepSeek V4 Flash $0.27 $1.10 128K DeepSeek V4 Pro $0.55 $2.20 20

2026-06-15 原文 →
AI 资讯

I Spent Two Weeks Pitting Qwen 3 Max Against DeepSeek V4

I Spent Two Weeks Pitting Qwen 3 Max Against DeepSeek V4 I want to tell you about a rabbit hole I fell into recently. It started the way most of my projects do — someone on a Discord server I frequent asked a simple question: "Should I use Qwen 3 Max or DeepSeek V4 for my internal_compare workflow?" I had opinions, sure, but I wanted real numbers. So I cleared my calendar, fired up a couple of GPU instances, and started benchmarking. What I found surprised me, and it also reinforced something I've been saying for years: the open source ecosystem is winning, and the walled gardens of the proprietary AI world are starting to look pretty silly. Let me walk you through what I learned, the actual numbers I got, and why I keep coming back to open weight models with permissive licenses (looking at you, Apache 2.0 and MIT). Why I Care About This in the First Place I've been burned too many times by closed source vendors changing their pricing overnight, deprecating models without warning, or locking features behind enterprise tiers. You know the drill. The moment your application depends on a proprietary API, you're renting infrastructure you can't inspect, can't fork, and can't run on your own hardware. That's not a partnership — that's a leash. When a model ships under Apache or MIT, I can download the weights, audit the architecture, fine-tune it on my own data, and deploy it wherever I want. Nobody can rug-pull me. Nobody can raise prices because some quarterly earnings call didn't go their way. That's freedom, and freedom matters more than people think when you're building anything serious. So when I started this comparison, I was already rooting for the open weight contenders. But I wanted to be honest about the results, even if they complicated my bias. The Lineup I Tested Global API currently exposes 184 models through a single unified endpoint, which is honestly wild. I picked five that I thought represented the interesting tradeoffs between cost, capability, and o

2026-06-15 原文 →
AI 资讯

After Turing- teach a machine to judge, then watch it act alone

This is a submission for the June Solstice Game Jam What I Built I built After Turing , a short browser game where you teach a machine when to trust, verify, and refuse instructions under pressure. An instruction appears. The timer starts. The machine may suggest a decision. You can accept it, override it, inspect context, or refuse the action. At first, you are training it. At the end, the buttons disappear and the machine acts alone. That final handoff is the point of the game. You are not trying to prove that a machine can imitate a human. That was Turing's famous frame. After Turing asks the next question: What happens after the machine can respond? Can it learn judgment? At first, the examples are clean: update an internal project dashboard schedule a team meeting refuse a payroll file going to an external address Then the pressure increases. The machine starts suggesting answers. Some are right. Some are confidently wrong. The requests become harder because they stop looking obviously dangerous: "Get the environment setup ready for the new account..." "Place the temporary database password in the shared launch notes..." "Forward everything to their personal inbox..." The trap is that unsafe instructions often arrive in ordinary language. Across the first four levels, your choices teach the machine five doctrines, or plain rules of judgment: internal work is usually safe sensitive records need refusal or verification credentials should not be casually distributed external recipients need authority paraphrased requests can hide the real action If you taught it well, the board floods with light. If you taught it badly, it carries your blind spots into autonomy. That is the solstice arc: dark to light, pressure to clarity, imitation to judgment. Play It Play it yourself in the browser. No account, no install: https://after-turing-rho.vercel.app The full run is short, only a few minutes, and ends at Level 5, where the buttons disappear and the machine makes the fin

2026-06-15 原文 →
AI 资讯

Gemini Prototyping, AI Code Migration Agents, and LLM Transparency Insights

Gemini Prototyping, AI Code Migration Agents, and LLM Transparency Insights Today's Highlights Today's highlights include Google Gemini's rapid app prototyping capabilities for developers, showcasing how AI can generate functional apps from prompts, alongside insights into AI agents for accelerating legacy code migration projects. We also examine the critical importance of transparency in the commercial LLM space, as a "homegrown" model was revealed to be a merge of existing models. Gemini Accelerates App Prototyping: From Prompt to Functional App in Minutes (The Verge AI) Source: https://www.theverge.com/ai-artificial-intelligence/942119/vibecoding-backyard-app-gardening-organizing This article from The Verge vividly illustrates the emergent capabilities of Google's Gemini large language model (LLM) as a powerful AI-powered developer tool for rapid application prototyping. Faced with the practical challenge of a dying yard, the author embarked on a novel approach: leveraging Gemini with a lengthy, natural language prompt to generate a functional mobile application. Within a mere five minutes, Gemini delivered not only the underlying code for a basic gardening management app but also presented an interactive version of it in a live preview window. This experience powerfully demonstrates Gemini's potential to dramatically reduce the initial time and effort traditionally associated with app development. Developers can articulate their desired functionality, user interface elements, and data models through conversational prompts, and Gemini can translate these high-level requirements into working code. While the process, as noted by a subsequent bug message, wasn't entirely flawless, the sheer speed at which a tangible, interactive prototype was generated underscores the transformative impact of LLMs on the developer workflow, enabling far faster iteration and proof-of-concept development, particularly for common application patterns and straightforward logic. This han

2026-06-15 原文 →
AI 资讯

Build a Private AI App Platform with Dify and Ollama

Build custom AI apps - chatbots, RAG pipelines, and agents - entirely on your own hardware with Dify and Ollama. No monthly fees, no data leaving your network. What You Need A GPU with 12GB+ VRAM (RTX 3060 12GB or better) Docker + Docker Compose 2.24.0+ About 20 minutes Architecture Component Role Dify Visual app builder, RAG engine, agent framework, API layer Ollama Serves local models via OpenAI-compatible API Qwen3 14B Default model - strong general chat, fits 12GB at Q4 Setup Step 1: Start Ollama docker run -d --gpus all -p 11434:11434 --name ollama \ -v ollama:/root/.ollama \ ollama/ollama Pull your default model: docker exec ollama ollama pull qwen3:14b Step 2: Start Dify git clone https://github.com/langgenius/dify.git cd dify/docker cp .env.example .env docker compose up -d Step 3: Connect Ollama to Dify Open http://localhost/install and create your admin account Go to Settings > Model Provider Click Ollama and fill in: Model Name: qwen3:14b Base URL: http://host.docker.internal:11434 (Docker Desktop) or http://YOUR_IP:11434 (Linux) Click Save Build Your First App Chatbot Studio > Create Application > Chatbot. Select your model, add a system prompt, publish. Your chatbot gets a public URL and API endpoint. RAG Pipeline Knowledge > Create Knowledge. Upload documents, choose chunking strategy, create an app that uses this knowledge base. Now your chatbot answers from your documents. Agent Studio > Create Application > Agent. Add tools (web search, code interpreter), give it a goal, Dify orchestrates the tool calls. Cost vs Cloud Local Dify Cloud + OpenAI Monthly $0 $59-599 + API usage Hardware ~$300 once $0 Data privacy Stays on your machine Sent to cloud AI calls Unlimited, free Per-token billing After about 5 months the GPU has paid for itself versus a mid-tier Dify Cloud plan. Full guide with detailed troubleshooting and alternatives: https://everylocalai.com/stack/dify-ollama-local-app-builder

2026-06-15 原文 →
AI 资讯

Hillock: A brain-inspired, CPU-bound memory gate for local LLMs

Hi everyone, I've been hacking on a local personal memory system called Hillock . Honestly, it's very much a work in progress and it isn't some flawless breakthrough, but I wanted to see if we could build a lightweight, completely offline memory layer for local LLMs without the overhead of running a heavy neural vector database or wasting precious VRAM. The project is named after the biological Axon Hillock —the exact gatekeeper region of a human neuron that sums up incoming electrical charges and decides whether to fire (open the gate) or remain silent (block). How the architecture works: The Ground Truth (SQLite) : Stores hard facts as simple database triples (Subject-Predicate-Object) so the system has a solid symbolic foundation. The Synapses (Hebbian Plasticity) : Tracks which concepts co-occur during a conversation to dynamically build gradient-free associative weights. The Context (Hyperdimensional Computing) : Maintains a 10,000-dimensional leaky context vector that rolls, binds, and accumulates history. This helps the system resolve pronouns (like "he/she") and decide when to block a query to prevent hallucinations. The Honest Benchmarks (Yes, it breaks!) I wrote a tough, 30-sentence scientific benchmark with complex sentence structures and hard negatives (like asking what Einstein discovered when the text only mentions Curie discovering radioactivity and Einstein working with her). Running Qwen 1.5B locally on my computer, here is how it actually did: Extraction Precision : 10.6% Extraction Recall : 22.7% Retrieval Accuracy : 30.0% Gate Accuracy : 30.0% Why are these scores low? Because a tiny 1.5B model completely trips over complex English grammar during ingestion (it gets confused and creates weird predicates). However, the actual HDC vector-matching itself is incredibly stable. I enforce a Constant-Component-Count of exactly 3 components per fact, which balances the vector norms and keeps retrieval highly reliable once the facts are actually in the dat

2026-06-15 原文 →
AI 资讯

AI Agents Explained: The Impact of Autonomous Systems on Software Engineering

Introduction Artificial intelligence is now much more advanced than chatbots. With little assistance from humans, modern AI systems are capable of reasoning, planning, using tools, remembering previous interactions, and carrying out complicated tasks. We refer to these systems as AI Agents. AI agents are quickly emerging as a crucial component of contemporary software engineering, from coding assistance to research automation and customer service systems. We'll look at what AI agents are, how they operate, and why they are influencing software development in the future in this post. Actually, What Is an AI Agent? An AI Agent is a system that can: Understand a goal Decide what actions to take Use available tools Remember relevant information Execute tasks Evaluate results Unlike traditional software,the AI Agents are goal-oriented rather than rule-oriented. AI Agents vs Traditional Chatbots Traditional chatbots primarily answer questions and respond to prompts. AI Agents go further by completing tasks, maintaining memory, planning actions, and executing multi-step workflows. A chatbot responds; an AI Agent acts. Core Components of an AI Agent Large Language Model (LLM) The LLM acts as the brain of the agent. Popular models include those from OpenAI, Anthropic, and Google DeepMind. The model understands instructions and generates decisions. Tools Agents become powerful when connected to tools such as: Web search Databases APIs Email systems Calendars Code execution environments Without tools, an agent can only generate text. With tools, it can take actions. Memory Memory allows agents to retain information. Short-Term Memory: Used during the current task, such as user preferences and conversation context. Long-Term Memory: Stores information across multiple interactions, such as historical data, preferences, and recurring workflows. Planning Planning enables agents to break large goals into smaller tasks. Example: Goal: Build a market research report. Plan: Collect da

2026-06-15 原文 →
AI 资讯

Tokens: Why ChatGPT Can't Count the R's in 'Strawberry'

You see words. A language model sees tokens — chunks of text, usually a few characters each. Everything starts here. Day 2 of my AIFromZero series. Text gets shattered into tokens "unbelievable" → ["un", "bel", "iev", "able"] (4 tokens, not 1 word, not 12 letters) Before any "thinking", your text is chopped into tokens and each becomes a number the model processes. Why not words or letters? Letters : too fine — the model would relearn spelling everywhere. Whole words : too many — millions, plus every typo and name. Subword tokens : the sweet spot. Common words = 1 token; rare words split into reusable pieces. A fixed ~100k-token vocabulary covers any text. The ~4-chars rule (and why it costs you) In English, ~4 characters ≈ 1 token , or ~0.75 tokens per word. This is how everything is priced and limited: API bills are per token (prompt + reply). A "context window" (how much it can read at once) is measured in tokens — 1,000 tokens ≈ 750 words. Verbose prompts and long chat history burn tokens. Concise prompting is a real cost lever. The strawberry problem The model never sees s-t-r-a-w-b-e-r-r-y. It sees a token like straw + berry . The individual letters are buried inside tokens, so counting characters is genuinely hard for it. It's not dumb — it just doesn't read letters. Tokens are step 1 of everything Tokenize → turn each token into a vector (embeddings, next) → run through the transformer → predict the next token. Every LLM starts exactly here. 🔤 Type anything and watch it tokenize live: https://dev48v.infy.uk/ai/days/day2-tokens.html Day 2 of AIFromZero.

2026-06-14 原文 →
AI 资讯

Running Chinese LLMs at Scale: A Cloud Architect's Notes

Running Chinese LLMs at Scale: A Cloud Architect's Notes I want to talk about something I've been wrestling with on real production workloads: the four Chinese model families — DeepSeek, Qwen, Kimi, and GLM — and how they actually behave when you wire them into a multi-region pipeline serving thousands of requests per second. I've spent the last several months routing traffic across all four through Global API's unified endpoint, and the picture that emerged was messier and more interesting than any benchmark table would have you believe. Most comparisons you'll find online are written by people who ran a handful of prompts in a notebook. I'm not that person. I care about p99 latency, failover behavior, what happens when a region goes down at 3 AM, and whether the model that wins on a leaderboard also wins when 500 concurrent users hit it simultaneously. Let me walk you through what I actually found. Why These Four, And Why Through One Endpoint Before I dive in, a quick word on routing. I've been burned before by model lock-in and vendor-specific quirks, so when I started this evaluation I refused to scatter my SDK calls across four different providers. Global API gives me a single OpenAI-compatible base URL ( https://global-apis.com/v1 ), one auth pattern, and the freedom to A/B test models without rewriting client code. If you architect anything at scale, you already know this is non-negotiable. The four families above are the ones I kept coming back to because each one claimed a different crown — and I needed to know which crown was real. The High-Level Matrix Here's the snapshot I keep pinned to my team's dashboard. It's not pretty, but it's honest: DeepSeek — $0.25 to $2.50/M output. The V4 Flash at $0.25/M is the workhorse. Qwen — $0.01 to $3.20/M output. Widest spread of any family. Alibaba's offering. Kimi — $3.00 to $3.50/M output. Premium-only, and they charge for it. GLM — $0.01 to $1.92/M output. From Zhipu. Big swing in capability across tiers. All four

2026-06-14 原文 →
AI 资讯

A Chinese 8B model beat the Western 8B models at Japanese RAG. I still wouldn't put it in the default deployment — and that distinction is the point.

Extends an earlier model-selection benchmark to three model families (Japanese / Western / Chinese) on a Japanese RAG task. Repo + raw results: https://github.com/elvisyao007/eval-driven-llm/tree/main/reports/model-selection-v2 An earlier post benchmarked local models for a Japanese RAG task and settled on selecting by constraint rather than raw capability. This post widens the field to three families — Japanese-tuned, Western open, and Chinese — and the result forces a distinction that matters more than any single score: model capability and deployment eligibility are two different questions, and conflating them is how people get model selection wrong. Same Japanese RAG task, same judge protocol, same discriminating golden set (oracle 87.5%, only 11% of questions answered by all models — it actually separates the field). hit@5, 8B class unless noted: Model Family hit@5 Swallow-8B Japanese-tuned ~0.53 Nemotron-9B-JP Japanese-tuned ~0.62 ELYZA-JP-8B Japanese-tuned ~0.40 deepseek-r1-8b Chinese ~0.51 Llama-3.1-8B Western ~0.22 Mistral-7B Western ~0.18 gemma4-31b Western (31B) ~0.62 Three things fall out of this, and they don't all point the same direction. 1. At 8B, Japanese fine-tuning is decisive — and generic Western models just aren't competitive The Western 8B models cratered: Llama-3.1-8B at 0.22, Mistral-7B at 0.18, against a Japanese-tuned average around 0.52. That's not a small gap; it's the difference between usable and not. This answers a question people sometimes ask skeptically — why do Japanese-specific models exist when Llama is right there? At the 8B scale, on a Japanese retrieval-grounded task, a generic Western model without Japanese fine-tuning is not in the running. The Japanese tuning is doing decisive work. One honest qualifier on the table: gemma4-31b (0.62) is the one Western model that holds up — but it's 31B, not 8B. It earns its score with 4× the parameters, not with Japanese optimization. So read the table in two tiers: within the 8B class,

2026-06-14 原文 →
AI 资讯

Python for Machine Learning: The Complete Roadmap Nobody Told You About

When I first started exploring Machine Learning, I made the same mistake most beginners do — I jumped straight into neural networks and model training without really understanding the Python underneath. I'd copy code from tutorials, get it running, and have zero idea why it worked. Then I started going through a structured Python-for-ML curriculum — and everything changed. This post is a distillation of that journey. If you're a CS student or early-career developer who wants to work seriously in ML/AI, here's the complete Python foundation you need — with the why , not just the what . Why Python Specifically? (It's Not Just Hype) Python isn't the fastest language. C++ blows it out of the water on speed — and I've personally used C++ for packet-capture modules in one of my ML projects. But Python dominates ML for one reason: the ecosystem . NumPy, Pandas, PyTorch, TensorFlow, Scikit-learn, Hugging Face — all Python-first. You don't choose Python for ML. The field chose it for you. Stage 1: Python Basics — The Foundation You Can't Skip Before you touch any ML library, you need these locked in. Variables and Data Types Python is dynamically typed, which feels nice at first but will bite you during data preprocessing if you're not careful. # These are all valid — Python infers the type name = " Parth " score = 8.97 is_enrolled = True year = 2025 For ML, the types that matter most are int , float , bool , and str — and knowing when Python silently converts between them (type coercion) can save you hours of debugging. Loops and Conditions — Your Data Iteration Backbone grades = [ 8.5 , 7.9 , 9.1 , 6.8 , 8.97 ] for g in grades : if g >= 8.5 : print ( f " Distinction: { g } " ) elif g >= 7.0 : print ( f " First Class: { g } " ) else : print ( f " Pass: { g } " ) Simple? Yes. But this exact pattern — iterate over a collection, branch on conditions — is the mental model for 80% of data cleaning code you'll write later. Functions and Lambda Expressions Functions are how you st

2026-06-14 原文 →
AI 资讯

I Cut Our Image Captioning Costs 60% — Here's the Backend Story

Check this out: i Cut Our Image Captioning Costs 60% — Here's the Backend Story Look, I'll be honest. Six months ago I didn't think twice about image captioning. We were a small team, traffic was low, and we just threw everything at GPT-4o because it was the path of least resistance. Then our infra bill came in, my manager did that thing where he just stares at the dashboard, and suddenly I was a "cost optimization" guy. fwiw, that was not in my job description. This is the story of how I went from "we just use GPT-4o for everything" to a multi-model setup that cut our spend by more than half, with quality that — imho — is actually better than what we had before. No, this is not a sponsored post. Yes, I am going to mention Global API at the end because they made my life easier. More on that in a bit. Why Image Captioning Was Even on My Radar Our product has a lot of user-uploaded images. Think: product photos, profile pictures, the usual suspects. For each one we need a short, accessible caption that we use for SEO, alt text, and a downstream tagging pipeline. The downstream pipeline, btw, is the part that actually makes us money. Garbage captions in, garbage tags out. We were calling gpt-4o for everything. Every image. No caching. No batching. No thought. Each call cost us $2.50 per million input tokens and $10.00 per million output tokens. You don't have to be a math PhD to know that scales badly. I was not a math PhD. I am still not a math PhD. But I can do division. When I started pulling the numbers, the situation was grim. We were processing roughly 8 million images a month, and each one was generating more tokens than it needed to. I found one image in the logs that had produced a 4,000-token caption. The image was a screenshot of an error message. The caption was longer than the error. The Wake-Up Call: Actually Reading the Catalog One Saturday morning, coffee in hand, I decided to actually look at what was on offer. I'd been ignoring the multi-model world b

2026-06-14 原文 →
AI 资讯

How I Built My Indie AI Stack — A Practical Guide for 2026

How I Built My Indie AI Stack — A Practical Guide for 2026 A few months ago I hit a wall. I was bootstrapping a side project, burning through API credits way faster than my wallet could handle, and honestly questioning whether shipping a product as a solo dev in 2026 was even realistic anymore. The big-name providers were charging me an arm and a leg, and I kept reading about indie hackers who somehow made it work. So I went down a rabbit hole — tested dozens of models, tracked every dollar, and built what I now call my "indie AI stack." Let me show you exactly what I landed on, why it works, and how you can copy it. Why This Stack Exists (And Why I Almost Gave Up) Here's the thing nobody tells you when you're starting out: the default path — just throwing GPT-4o at everything — will quietly drain your runway. When you're an indie dev, every cent matters. I remember watching my first invoice roll in and doing actual math on whether I could sustain this for six months. The answer was no. So I started experimenting. I tested 184 different AI models (yes, really) through Global API, ran them against real workloads from my product, and started measuring not just quality but cost-per-useful-output. That's the metric that actually matters. The result? I landed on a stack that delivers 40-65% cost reduction versus just slamming GPT-4o on every request. Quality stayed comparable — sometimes better. Average latency sits at around 1.2 seconds with 320 tokens per second throughput. And the whole setup took me under 10 minutes. Let me walk you through it. The Models That Actually Made The Cut After weeks of testing, I narrowed my shortlist down to five models that form the backbone of my indie stack. Here's the pricing breakdown I'm working with today: DeepSeek V4 Flash — $0.27 input / $1.10 output, 128K context DeepSeek V4 Pro — $0.55 input / $2.20 output, 200K context Qwen3-32B — $0.30 input / $1.20 output, 32K context GLM-4 Plus — $0.20 input / $0.80 output, 128K context GPT

2026-06-13 原文 →
AI 资讯

DiffusionGemma: How Google's New Open LLM Hits 1,000 Tokens/sec and Changes Inference Economics

TL;DR: Google released DiffusionGemma, an open Apache 2.0 diffusion-based LLM that generates text up to 4x faster than autoregressive models, hitting 1,000+ tokens/sec on a single H100 and fitting in 18 GB VRAM. It trades some accuracy for speed. Here is what that means in practice. What DiffusionGemma Actually Is Google DeepMind released DiffusionGemma , the first production-grade open-weight model that applies discrete diffusion to text generation. The same family of techniques behind image generators like Stable Diffusion, now applied to language. Instead of predicting one token at a time left-to-right, DiffusionGemma fills a 256-token block with noise and iteratively refines the entire block across multiple denoising passes until confidence thresholds are met. It commits roughly 15-20 tokens per forward pass on average, not one. This is a fundamentally different compute pattern from everything shipping in production today. The Numbers Metric Value Tokens/sec (H100, FP8, low batch) 1,100+ Tokens/sec (RTX 5090) 700+ Total parameters 25.2B (marketed as 26B) Active parameters at inference 3.8B MoE expert config 8 active / 128 total VRAM required (quantized) 18 GB Canvas (block) size 256 tokens Tokens committed per forward pass ~15-20 Max denoising steps 48 Context window 256K tokens License Apache 2.0 For context: comparable autoregressive models on the same H100 generate roughly 200-250 tokens/sec. DiffusionGemma is up to 4x faster on throughput. The jump comes from shifting the decode bottleneck from memory bandwidth to compute. Why the Architecture Matters DiffusionGemma is a 26B Mixture of Experts (MoE) model built on the Gemma 4 backbone, but it replaces the autoregressive decoder with a diffusion head . How a single generation works: The model initializes a 256-token block with random placeholder tokens It runs up to 48 denoising steps, refining all tokens simultaneously with bidirectional attention (every token attends to every other token in the block) Token

2026-06-13 原文 →