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

今日精选

HOT

最新资讯

共 32868 篇
第 1273/1644 页
AI 资讯 Dev.to

Build Your RAG System Right the First Time: 6 Decisions That Make or Break It

After debugging 20+ broken RAG systems, I've identified the 6 decisions that determine whether yours works. Here's how to get each one right. The RAG Developer's Trap Every RAG developer falls into the same trap: you build the basic pipeline, it sort of works, and then you spend weeks tweaking prompt templates — while the real problem sits untouched in your indexing pipeline. The 80/20 rule: 80% of RAG problems come from indexing, not generation. But 80% of debugging effort goes into generation. Let's fix that. Decision 1: Embedding Model — The Single Biggest Lever The mistake: Using all-MiniLM-L6-v2 for Chinese documents because it's the default in every tutorial. Why it's wrong: It's English-trained. Drop it on Chinese text and it loses 30-50% of semantic fidelity. Language Use This Chinese BAAI/bge-large-zh-v1.5 (1024-dim) Chinese + English BAAI/bge-m3 (multilingual + sparse) English text-embedding-3-large Code jina-embeddings-v3 or voyage-code-3 Non-negotiable: Indexing model and query model must be byte-for-byte identical. Switch models = rebuild entire index. Impact: +15-40% Recall@10 for Chinese RAG. Decision 2: Chunk Size — Not a Magic Number Physics: Too small (< 100 tokens) = semantic fragmentation. Too large (> 1000 tokens) = noise injection. Document Type Sweet Spot Overlap FAQ / Short-form 128-256 20 Technical docs 512 50 Long-form articles 768-1024 100 Code Function boundaries 0 The method matters more than the size. Use recursive splitting, not fixed-length: from langchain.text_splitter import RecursiveCharacterTextSplitter splitter = RecursiveCharacterTextSplitter ( chunk_size = 512 , chunk_overlap = 50 , separators = [ " \n\n " , " \n " , " . " , " " , "" ] ) Impact: +5-15% Recall@10. Decision 3: Index Type — HNSW vs IVF Scale Use Why < 1M vectors HNSW Recall > 0.95 1-5M, RAM tight IVF + PQ 75% memory savings > 5M IVF + PQ + Sharding Horizontal scale Key nuance: HNSW has high insertion cost. Streaming docs → IVF may be better even at small scale. Im

马国锦 2026-06-11 11:36 10 原文
AI 资讯 Dev.to

Set Up Your Own ChatGPT: Ollama + Open WebUI for Data That Never

Set Up Your Own ChatGPT: Ollama + Open WebUI for Data That Never Leaves Home As artificial intelligence models rapidly integrate into our lives, privacy concerns are growing in parallel. Especially for companies or individuals working with sensitive data, sending information to cloud-based services can pose a serious risk. At this point, setting up your own local Large Language Model (LLM) infrastructure offers a great solution. In this guide, I will explain step-by-step how to set up your own chat interface using tools like Ollama and Open WebUI, ensuring your data never leaves your system. This approach allows you to both reduce costs and maximize your data security. This setup is particularly important for those like me, with a background in enterprise software development, who believe that data flows should always follow the most secure path. In the past, working on a production ERP, transferring supply chain data to external systems without anonymization could lead to serious security vulnerabilities. This is where local LLM solutions come into play. Why You Should Set Up Your Own Local LLM While cloud-based LLM services are incredibly convenient, they come with some fundamental drawbacks. Most importantly, every piece of data you input is potentially sent to the service provider's servers. This can be unacceptable, especially when dealing with financial data, patient information, trade secrets, or sensitive code in your personal projects. By setting up your own local LLM, you eliminate these risks. In recent months, while working on my side project, a financial calculator, I felt the need to use an LLM for complex financial analyses. However, the details of these analyses could not be leaked externally. This situation led me to search for a solution where I could keep my data under my own control. Ollama and Open WebUI emerged as the most practical and powerful duo in my search. ℹ️ Data Privacy and Control A local LLM solution gives you full control over where

Mustafa ERBAY 2026-06-11 11:35 9 原文
AI 资讯 Reddit r/artificial

While scrolling though social media I have been observing AI-generated content for the past few months. Here's what I've noticed.

Once you start noticing them, they're everywhere. And the algorithm makes it worse, the more you engage, the more it feeds you... Perfect lighting in every single photo. That glow on the face in every other pic or video it doesn't matter what the background or lighting is. Follows 3 people but has 40k followers. Generic bio that could apply to literally anyone. Comments that are just emojis or "love this!" The creepy part is how consistent the patterns are across platforms. Same pose angles. Same aesthetic. Same engagement ratio that makes no sense for a real person. I built a small community tool where people can flag and vote on suspicious profiles. Not trying to be the judge, just crowdsourcing the pattern recognition. I feel humans are really good at spotting these when you give them the right frame and observation. Anyone else been noticing more of these lately? Curious what other people pick up on this. submitted by /u/Brilliant-Nerve-8972 [link] [留言]

/u/Brilliant-Nerve-8972 2026-06-11 11:33 6 原文
AI 资讯 Dev.to

I automated my Gumroad product screenshots with Playwright

I automated my Gumroad product screenshots with Playwright I recently started packaging a few small frontend projects as digital products, and one surprisingly annoying part was preparing product screenshots. Manual screenshots quickly became messy: different browser sizes inconsistent cropping blurry images mobile screenshots were easy to get wrong Gumroad needed a square thumbnail every update meant taking screenshots again So I built a small local screenshot workflow with Next.js and Playwright. The workflow captures: desktop screenshots mobile screenshots square thumbnail images consistent PNG outputs route status checks basic console error reporting basic horizontal overflow checks The basic command flow is: npm run build npm run start npm run screenshots The script reads a simple config file, opens the configured local routes, captures each screenshot with consistent viewport settings, and exports the images into a predictable folder. For example: screenshots/gumroad/ landing.png dashboard.png template-preview.png mobile-preview.png thumbnail.png I found this especially useful when preparing Gumroad product galleries, because I could regenerate all product images after every UI change instead of taking screenshots manually. This is not a hosted screenshot service. It is just a local source-code workflow for people who want to generate product screenshots from their own Next.js pages. I packaged the workflow as a small Gumroad product here: https://remix410.gumroad.com/l/screenshot-automation-kit Curious how other developers handle product screenshots. Do you take them manually, use Playwright/Puppeteer, or use a design tool workflow?

Hiralasa 2026-06-11 11:32 10 原文
AI 资讯 Dev.to

How to Use Primitive Types in TypeScript: string, number, and boolean

TLDR TypeScript has 7 primitive types: string , number , boolean , null , undefined , bigint , and symbol . You use them to tell TypeScript what kind of value a variable holds. You write them in lowercase. TypeScript can often figure out the type for you. But knowing how each one works is key to writing safe and clear code. What Are Primitive Types? Primitive types are the simplest building blocks in TypeScript. Every piece of data in your program starts with one. They hold a single value. They are not objects. You cannot add methods or properties to them directly. TypeScript has 7 primitive types in total: Type What It Holds string Text like names, messages, or IDs number Any number: integers, decimals, negatives boolean Only true or false null An intentional empty value undefined A value that was never assigned bigint Very large whole numbers symbol A unique identifier value This article covers all 7. You will use string , number , and boolean the most in everyday TypeScript code. How to Use the string Type A string holds text. Use it for names, messages, emails, URLs, and any other text data. Basic string annotation let firstName : string = " Alice " ; let greeting : string = " Hello, world! " ; let empty : string = "" ; Three ways to write strings TypeScript supports the same three string styles as JavaScript: let single : string = ' Single quotes work fine ' ; let double : string = " Double quotes work too " ; let template : string = `Template literals with ${ firstName } ` ; Template literals (backticks) let you insert values inside a string with ${} . TypeScript checks the types of those inserted values too. let age : number = 30 ; let message : string = `I am ${ age } years old` ; // TypeScript checks that 'age' is compatible here What TypeScript catches with strings let name : string = " Alice " ; name = 42 ; // Error: Type 'number' is not assignable to type 'string'. name = true ; // Error: Type 'boolean' is not assignable to type 'string'. Once a variable

Krunal Kanojiya 2026-06-11 11:29 7 原文
AI 资讯 Dev.to

I Processed 2.4 Billion Tokens Across 52 AI Models for $0.52. Here's the Full Breakdown.

I run a production multi-agent AI system on a single M1 Mac in Jamaica. 6 autonomous agents. 26 cron workflows. 5-layer persistent memory. All containerized, all running 24/7. I checked my OpenRouter dashboard last week and realized something: I'd processed 2.4 billion tokens across 52 different AI models and spent a total of $0.52 . That's not a typo. Here's exactly where that money went and what it means. The Numbers Metric Value Total Requests 26,600+ Tokens Processed 2.4 Billion Models Used 52 Total Cost $0.52 Cost per Token $0.00000021 Tokens per Dollar 4.6 Million For context: GPT-4 Turbo costs about $0.00001 per token at scale. I'm running at roughly 50x below that rate. Where the $0.52 Actually Went Here's the breakdown by model: Model Requests Tokens Cost openrouter/owl-alpha 1,334 251.2M $0.00 nvidia/nemotron-3-super-120b 32 1.8M $0.00 google/gemma-4-31b-it 47 1.8M $0.00 openai/gpt-5 1 2.8K $0.03 google/gemini-3.1-pro-preview 1 3.2K $0.04 anthropic/claude-opus-4 1 2.0K $0.13 qwen/qwen3.5-plus 1 6.3K $0.01 z-ai/glm-5-turbo 1 3.0K $0.01 moonshotai/kimi-k2.5 2 4.1K $0.01 google/gemini-2.5-flash 2 5.5K $0.01 +42 other models ~125 ~8.5M ~$0.28 99.6% of my requests cost exactly $0.00. They ran on free-tier models or local inference. The $0.52 comes from a handful of premium model calls: Claude Opus, GPT-5, Gemini Pro. These are reserved for specific high-quality tasks — not everyday inference. What This Would Cost on Cloud Approach Hardware Monthly Cost Annual Cost My setup (M1 Mac) M1 Mac 16GB, local + free tier ~$0.09 ~$1.04 OpenRouter Paid Tier API-only, no local $15-30 $180-360 AWS (g4dn.xlarge + API) 1x T4 GPU, on-demand $350-500 $4,200-6,000 AWS (g5.xlarge + API) 1x A10G GPU, on-demand $700-1,000 $8,400-12,000 A $1,200 laptop replaces $500-1,000/month in cloud bills. The break-even point is about 2 weeks. How the Architecture Works The key insight: not every task needs a $20/month model . My system routes tasks intelligently: Local inference (free): Ollama

Alex Bogle 2026-06-11 11:22 13 原文
开源项目 Dev.to

Unofficial Delinea Secret Server Cross‑Tenant Migration Tool (GUI + Automation) — Sharing with the community

I’m a PAM engineer and recently had to handle a few cross‑tenant migrations in Delinea Secret Server. As many of you know, there’s no built‑in way to migrate secrets, folders, roles, or permissions between tenants (cloud ↔ cloud, on‑prem ↔ on‑prem, hybrid, etc.). To avoid doing everything manually, I built an unofficial PowerShell‑based tool to automate the process. Not a vendor, not selling anything — just sharing something I built because it solved a real problem for me. What it does: Full Windows GUI Export → validate → import → reconcile Folder/role/permission mapping Integrity checks Supports cloud, on‑prem, and hybrid Auto‑update logic for long‑term use If anyone else here works with Secret Server and has had to deal with tenant splits, mergers, rebuilds, or cloud migrations, this might save you some time. Github Link: https://github.com/vijayamohanreddy/delinea-secrets-server-migration-tool-unofficial Linkedin Article: https://www.linkedin.com/pulse/introducing-delinea-secret-server-crosstenant-tool-vijaya-reddy-vj--wy47c/?trackingId=vJ3%2F9%2Fw3RLSKlm%2F1kXig1Q%3D%3D Affiliation disclosure: I built this myself for my own work. Not affiliated with Delinea, not a vendor, not selling anything. Happy to answer questions or hear suggestions from others who’ve had to do Secret Server migrations.

vijaya reddy 2026-06-11 11:22 12 原文
AI 资讯 Reddit r/webdev

Confused about whether to hire a web/app dev for this or use AI

I have an idea for an app but it requires payment to be done by escrow. I have absolutely no idea what I am doing, but I'm 20 so I just want to try a shot at this business Idea. I have build one or two websites with claude before, and it's alright. But when it comes to these issues, especially regarding payments in the thousands, I don't know if I should use AI for it. On the one hand, I don't have the money to hire a dev so I'd have to find investors which is extemely hard to, again, since I don't know what I'm doing, but on the other, I don't want to risk messing it up such that the payment doesn't go through because of a fault and someone who worked for hours wouldn't get the money he deserved and thus I'll be held legally. I could use some advice from those who've had experience in this field. P.S - Please suggest if you have other ideas I can use rather than escrow for payments submitted by /u/PeaceInLoneliness [link] [留言]

/u/PeaceInLoneliness 2026-06-11 11:12 6 原文
AI 资讯 Product Hunt

LYQN AI

AI support that learns your business and hands off to humans Discussion | Link

2026-06-11 11:08 5 原文
AI 资讯 Reddit r/MachineLearning

ICMI 2026 Reviews [D]

Did anyone else submit to ACM ICMI 2026? The reviews were recently released, and this is my first time submitting to ICMI, so I'm not very familiar with the acceptance patterns. I submitted a long paper and received the following overall ratings: 4 (Probably Accept), 3 (Borderline), 4 (Probably Accept) The reviewer with the highest stated expertise recommended acceptance, while the borderline reviewer had some concerns about soundness but still considered it a nice contribution. For those who have submitted to or reviewed for ICMI before, how would you interpret these scores? Is a 4/3/4 generally considered competitive after rebuttal, or is it still a long shot? Would appreciate any insights from past authors or reviewers. submitted by /u/kanishq95 [link] [留言]

/u/kanishq95 2026-06-11 10:54 7 原文
AI 资讯 Reddit r/webdev

Newbie questions

Sorry for my dumb questions and bad English hope this is the right place to post to understand my concerns. I'm a new college student in computer programming but my degree is a just a 2 years studying for introducing courses, I've been studying all types of "Introduction to C++" "Introduction to computers" and those types of courses including the one for web development which caught my attention so much more than the rest and I feel it suits me more especially there is a back/front end and full stack which the person will do while studying, while other courses didn't get my attention, anyways, I've been thinking to study web development full stack by myself online or using books, and do some types of projects to self learn more because school barely cover a little, while looking around I always see that AI will take over this field of IT, and people talking about AI coding apps like "Cursor" which will make all of this really helpless, everytime I check I get different opinions and no real answers, I try to study online on YouTube or Udemy and each creator covers a different types with no clear path of this field, I just want to know if there is a specific way, like a source or a books or anything up-to-date about this field and how I can do it, so I thought this is the only place where I can ask people about it. Sorry for the long post and apologize my English. submitted by /u/Imaginary-Fox-7696 [link] [留言]

/u/Imaginary-Fox-7696 2026-06-11 10:03 5 原文