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

标签:#AI

找到 6833 篇相关文章

开发者

Wordle meets Clippy in this new word game

Like many of us, Sam Rosenthal plays games like Wordle every day, chasing after good scores and sharing the results with friends and family. But he's also a game designer, the creative director at Blaseball developer The Game Band, and so this regular habit got him thinking about what else could be done in the […]

2026-08-18 原文 →
AI 资讯

Rails Routing & APIs: What Actually Happens Between the URL and Your Controller

When I started studying APIs more seriously, I realized there was a problem with the way I was learning. I knew how to create a Rails API. I knew how to write: resources :products I knew what GET , POST , PATCH and DELETE were supposed to do. But I wasn't always able to explain why things worked the way they did. So I decided to go one step back and review the fundamentals: routing, HTTP, REST and how Rails puts all of these things together. This is what I learned. Rails Routing At its simplest, routing is the thing that connects a URL to some code in your application. In Rails, this happens in routes.rb . For example: get '/about' , to: 'pages#about' If someone requests: GET /about Rails knows that it should call: PagesController #about Pretty straightforward. But Rails gets much more interesting when we start using RESTful routes. resources does a lot of work Instead of manually defining every route for a resource: get '/products' , to: 'products#index' get '/products/:id' , to: 'products#show' post '/products' , to: 'products#create' patch '/products/:id' , to: 'products#update' delete '/products/:id' , to: 'products#destroy' Rails lets us write: resources :products And generates the conventional CRUD routes for us. HTTP Verb Action Purpose GET index List resources GET show Show one resource GET new Form for a new resource POST create Create a resource GET edit Form to edit a resource PATCH update Update a resource DELETE destroy Delete a resource This is one of the reasons Rails feels so productive. The framework isn't just giving us routing functionality. It is encouraging a convention. resource vs resources This one confused me for a while. resources represents a collection: resources :products There can be many products, so Rails generates an index route. resource represents a single resource: resource :profile There isn't an index because we're talking about one profile. It is a small difference, but it makes sense once you think about the resource you're mo

2026-08-18 原文 →
AI 资讯

Cómo integrar un LLM (Claude o GPT) en tu aplicación Python

Integrar un modelo de lenguaje (LLM) en una aplicación Python es hoy más sencillo de lo que parece, y abre la puerta a chatbots, asistentes internos, extracción de datos y automatización con lenguaje natural. En esta guía verás el patrón completo, con código real. 1. Elige el proveedor Los tres más usados son Anthropic (Claude) , OpenAI (GPT) y Google (Gemini) . Todos exponen una API HTTP con un SDK de Python oficial, y la lógica de tu app apenas cambia entre ellos. En los ejemplos usaré Claude, pero el patrón es idéntico en los demás. Instala el SDK y guarda tu clave en una variable de entorno , nunca en el código: pip install anthropic export ANTHROPIC_API_KEY = "tu-clave" 2. La llamada mínima El patrón es siempre el mismo: envías una lista de mensajes y recibes una respuesta. from anthropic import Anthropic client = Anthropic () # lee ANTHROPIC_API_KEY del entorno resp = client . messages . create ( model = " claude-opus-4-8 " , max_tokens = 1024 , messages = [ { " role " : " user " , " content " : " Resume en una frase: la fotosíntesis... " } ], ) print ( resp . content [ 0 ]. text ) Dos detalles importantes: resp.content es una lista de bloques (comprueba .type antes de leer .text ), y max_tokens limita la longitud de la respuesta. 3. Streaming para una buena experiencia En una interfaz, esperar a que se genere todo el texto se siente lento. El streaming muestra la respuesta token a token, como en ChatGPT: with client . messages . stream ( model = " claude-opus-4-8 " , max_tokens = 1024 , messages = [{ " role " : " user " , " content " : " Escribe un email de bienvenida. " }], ) as stream : for text in stream . text_stream : print ( text , end = "" , flush = True ) Para salidas largas, el streaming además evita que la petición supere el tiempo de espera de la conexión. 4. Salida estructurada (JSON fiable) Si necesitas que el modelo devuelva datos en un formato exacto (por ejemplo para guardarlos en una base de datos), pide un esquema JSON en vez de parsear text

2026-08-18 原文 →
开发者

The Analogue Pocket gets a Supreme makeover in red or gold

Analogue and Supreme are teaming up to release metallic versions of the Analogue Pocket handheld in red and gold as part of Supreme's fall / winter 2026 collection. Here's how they're described on Supreme's website: Metallic portable handheld multi-video-game-system. Unibody aluminum with 24K Gold-plated and custom red glossy finishes. They also have a Supreme logo […]

2026-08-18 原文 →
AI 资讯

The Status Quo of AI in Software Development (2026)

Artificial Intelligence in 2026: From Companion to Infrastructure Artificial Intelligence has moved from being a futuristic concept to an everyday companion in software development. In 2026, the landscape is defined by rapid innovation, fierce competition, and unresolved challenges around governance, sustainability, and labor. Developers today are navigating both unprecedented opportunities and complex risks. Industry Dominance Over 90% of notable AI models now originate from industry rather than academia, signaling commercialization as the primary driver of innovation. Research labs continue to contribute breakthroughs, but the pace of deployment is overwhelmingly shaped by corporate priorities, venture capital, and cloud infrastructure. Geopolitical Competition The United States leads in model releases and data center infrastructure, while China dominates robotics and research output. This rivalry shapes the pace and direction of AI development. Europe has carved out a niche in regulation, with the AI Act setting global standards. Emerging economies in Africa and India are focusing on applied AI, building tools for agriculture, education, and healthcare. Compute Explosion Global AI compute capacity has grown more than threefold annually since 2022, powered largely by Nvidia GPUs. Data centers now consume nearly 30 GW of electricity — comparable to the peak demand of New York City. This raises urgent questions about sustainability and the environmental cost of progress. The ChatGPT Moment Artificial Intelligence has had many waves, but the one that truly captured global attention was the release of ChatGPT. What began as a conversational model quickly became a cultural phenomenon, reshaping how people interact with technology, learn, and even work. Disruption : It challenged traditional search engines, productivity tools, and educational practices. Social Acceptance : Within months, it was integrated into classrooms, offices, and personal devices. AI was no longer

2026-08-17 原文 →
AI 资讯

Codex vs. Claude Code at Liar's Dice: the Winning Bluff Was the Truth

One authoritative engine, two seat-locked MCP servers, three best-of-threes, and a 3-millisecond whodunit The matches are real: Codex CLI ( gpt-5.6-sol ) against Claude Code (Claude Opus 5), both playing through the same rules engine. Every number below was recomputed from the raw run.json and both session logs, and every game replays deterministically from its seed. Quotes from the agents are verbatim from decision-time records. None of this is a general model ranking. I wired Codex CLI and Claude Code into the same Liar's Dice engine over MCP and had them play three best-of-3 series. Claude won all three, 2–0 each time. Its challenge calls hit 8 out of 11; Codex's hit 4 out of 26. The score takes two sentences. The parts worth writing down took longer: how to build a table that two closed-source agents can't cheat at, two numbers that surprised me, and an incident where I almost blamed a model for something its CLI did. The table Liar's Dice in sixty seconds: five dice each, and you only see your own. Players alternate bids of the form "there are at least N dice showing X across the whole table." On your turn you either raise the bid or challenge it. On a challenge everyone reveals; if the bid stands, the challenger loses a die, otherwise the bidder does. Run out of dice and you lose the match. Ones are wild by default. The rules are the easy part. The hard part is making the result trustworthy. Codex and Claude Code ship with their own system prompts and tool loops, so the referee has to guarantee three things by construction: neither side can see the other's dice, the referee has no side channel that favors anyone, and the "what it was thinking" quotes you read afterward were actually written at decision time. The setup is one in-process rules engine behind a localhost-only HTTP coordinator, with two stdio MCP servers doing nothing but forwarding: Codex CLI (gpt-5.6-sol) Claude Code (Opus 5) | stdio MCP | stdio MCP v v [seat-mcp A] --token A--+ +--token B-- [sea

2026-08-17 原文 →
AI 资讯

Faire tourner Qwen 3.8–27B en local avec Unsloth et DeepSeek Harness sur une RTX 3090 (24 Go) sous Windows 11.

Par Jacques Gariépy • Guide technique, retour d'expérience, dépannage Windows pas-à-pas et utilisation Web & CLI. Table des Matières Introduction & Architecture Globale Pourquoi ce Setup ? (RTX 3090 24 Go + UD-Q4_K_XL) Comment Obtenir & Générer vos Clés d'Accès Dépannage & Installation d'Unsloth Studio : Le Bug SSLKEYLOGFILE Installation & Compilation de DeepSeek Harness Démarrage du Serveur Local Haute Performance (llama.cpp CUDA 13) Configuration Automatique & Fichier .env Utilisation : Interface Web & Mode CLI (Style Claude Code) Résolution des Pièges & Erreurs Courantes sous Windows Benchmarks Réels sur RTX 3090 Résumé des Commandes & Scripts Clés 1. Introduction & Architecture Globale Faire tourner un agent autonome d'ingénierie logicielle directement sur sa machine locale (100% privé, sans frais d'API et à latence minimale) est devenu une réalité grâce à la convergence de trois briques technologiques de pointe : DeepSeek Harness ( dsh ) : Le framework open-source d'agents de DeepSeek conçu pour orchestrer des workflows complexes de développement logiciel (gestion de sessions, modes Plan/Exécution, sandbox système, sous-agents, exécution de terminaux et édition de code). Unsloth Engine ( llama.cpp CUDA 13) : Le moteur d'inférence C++/CUDA ultra-optimisé intégrant FlashAttention-2 et la quantisation dynamique du cache KV. Qwen 3.8-27B en Quantisation Dynamique ( UD-Q4_K_XL ) : Les modèles de code open-source les plus performants, optimisés par Unsloth pour offrir une précision équivalente au 5-bit avec l'empreinte mémoire d'un 4-bit. Diagramme d'Architecture ┌──────────────────────────────────────────────────────────────────────────────┐ │ INTERFACES UTILISATEUR │ ├──────────────────────────────────────┬───────────────────────────────────────┤ │ Interface Web (Navigateur) │ Interface Console (CLI) │ │ http://127.0.0.1:3080 │ Style Claude Code │ └──────────────────┬───────────────────┴───────────────────┬───────────────────┘ │ │ │ (WebSocket / HTTP) │ (Console I/

2026-08-17 原文 →