SShortSingh.

Programming

0
ProgrammingDEV Community ·

How to Build a PDF-Based Support Triage System Using Embeddings and Reranking

A technical guide outlines a three-stage architecture for B2B support triage that splits PDF retrieval, reranking, and answer generation into distinct steps. The approach recommends embedding search to find semantically related manual pages, followed by a reranking pass to improve evidence quality before a summary is generated. The final output must cite specific page identifiers and assign a support queue only when the retrieved pages justify that decision, returning a needs-review flag otherwise. Each stage should carry independent timeouts so that failures can be isolated rather than absorbed by a single end-to-end limit. The guide advises shipping the rerank-then-summarize path as the practical default, reserving pure embedding search as a low-latency fallback and deterministic rules only for stable, high-consequence queues.

0
ProgrammingDEV Community ·

Four Common RAG Retrieval Failures and How Logging Each One Fixes Them

A developer building Retrieval-Augmented Generation (RAG) pipelines found that most errors blamed on the language model were actually caused by flawed retrieval, a realization that only became clear after adding detailed logging. Four distinct failure types emerged: missing answers in the knowledge base, semantically similar but contextually wrong chunks, model hallucination due to weak system prompts, and malformed chunks produced by token-count-based splitting. Hybrid search combining vector and BM25 retrieval proved more effective than switching embedding models for resolving keyword-sensitive mismatches, while cross-encoders offered a complementary reranking approach. Strict system prompts requiring the model to cite source passages and admit ignorance addressed cases where retrieval was correct but the model still extrapolated. The author concludes that logging chunk scores and sizes from the start is more valuable than any model swap, as most RAG problems originate in the retrieval and chunking stages rather than the LLM itself.

0
ProgrammingDEV Community ·

Developer Builds Experimental Smart Scooter Platform With AI and Privacy-Focused Payments

Independent developer Daniel Ioni has launched Urban Lab, an experimental project aimed at combining smart electric scooters, AI services, open-source software, and privacy-focused payments. A key component under development is a 2-of-3 multisig escrow system built on Monero, designed to reduce the trust required between customers and service providers. The backend, called I-ECO-01, is a Node.js and Express REST API that manages escrow states, participant authorization, and transaction tracking. The system currently runs on Monero Stagenet using simulated data and is not presented as a production-ready financial service. Additional components in progress include automated GitHub bounties, AI and robot integrations, real-time monitoring, and experimental MYZ-to-XMR conversion logic.

0
ProgrammingDEV Community ·

Developer fixes AI character inconsistency in auto-generated videos using prompt injection and visual QA

A developer building fully automated explainer videos discovered that their local image-generation AI depicted the same historical subject as a completely different person in every scene. The root cause was that each scene's image prompt was written independently, causing the AI to reimagine the character's appearance and historical setting from scratch each time. To fix consistency, the developer created a reusable 'character card' defining the subject's appearance and historical constraints, which was automatically injected into every scene's prompt before generation. However, negative instructions like 'don't draw a dome' proved largely ineffective, so a second AI was added as a visual checkpoint to inspect the actual output pixels for anachronisms, fake text, and character inconsistencies. Scenes that failed the automated visual check were regenerated with a new random seed until they passed, successfully eliminating the remaining errors.

0
ProgrammingDEV Community ·

Open Discovery Challenge Tests AI-Designed Malaria Drug Candidates With 6-Axis Scoring

VIDRAFT and FINAL-Bench have launched the Open Discovery Challenge, a public leaderboard evaluating AI-generated drug candidates targeting PfDHODH, a key enzyme in the malaria parasite. The initiative addresses a growing gap in AI drug discovery: while generative models can propose thousands of molecules daily, reliably verifying their potency, selectivity, safety, and synthesizability remains unsolved. Submissions are scored across six axes — whole-cell activity, target binding, selectivity, ADMET profile, novelty, and synthesis feasibility — with detailed methodology published on Hugging Face. During scorer validation, the team identified 14 defects, including toxicity thresholds that incorrectly rejected all three approved antimalarials and a binding-efficiency metric that over-rewarded small, weak molecules like caffeine. The challenge highlights that building a fair, scientifically rigorous automated judge for AI-designed molecules is as hard as the molecule generation itself.

0
ProgrammingDEV Community ·

How AI Coding Agents Can Silently Expose Your API Keys and Secrets

AI coding agents like Claude Code access source files, config files, and environment variables, then relay summaries of that content to third-party APIs, creating serious secret-exposure risks. Three main leak vectors exist: context exfiltration, where the agent reads .env files and includes values in prompts; tool output echo, where secrets appear in captured stdout; and prompt injection, where malicious instructions trick the agent into sending credentials externally. Common mitigations such as secret managers and .env hiding tools still leave credentials vulnerable once a command runs. A developer has released an open-source CLI tool called 'trustless' that addresses this by injecting credentials at the process and transport layer rather than exposing them to the agent's context window. The core principle is that agents should receive capabilities, not credentials, and all outbound requests should be scanned to confirm no secrets have leaked.

0
ProgrammingDEV Community ·

CAP Theorem Explained: Why Distributed Systems Must Choose Between Consistency and Availability

The CAP theorem states that a distributed system can guarantee only two of three properties — Consistency, Availability, and Partition Tolerance — simultaneously. Since network partitions are unavoidable in real-world distributed systems, engineers must choose between CP (consistency over availability) or AP (availability over consistency). CP systems, such as HBase, Zookeeper, and MongoDB, refuse to return potentially stale data during a partition, making them suitable for banking, inventory, and leader election use cases. AP systems, such as Cassandra, DynamoDB, and CouchDB, continue serving requests even with stale data, which is acceptable for social media feeds, DNS, and product catalogs. The PACELC model extends CAP by also accounting for the latency-versus-consistency trade-off that exists even when no partition is occurring.

0
ProgrammingDEV Community ·

SIM Swap Fraud Can Hijack Your Phone Number Without Touching Your Device

SIM swap fraud allows attackers to seize a victim's phone number by impersonating them to their mobile carrier using personal data sourced from breaches, social media, or social engineering. Once the carrier transfers the number to an attacker-controlled SIM, all calls and texts — including bank verification codes — are rerouted to the fraudster. The FBI's Internet Crime Complaint Center has monitored and formally warned about this scheme since 2018, noting that reported losses likely undercount the true damage, as downstream financial theft is often logged under separate fraud categories. Victims typically receive no advance warning, with the first sign usually being an unexplained loss of cell service. The FBI recommends setting a carrier account PIN, avoiding public disclosure of financial details, and replacing SMS-based authentication with an authenticator app or physical security key.

0
ProgrammingDEV Community ·

Developer Ditches AI Classifier for Simple Rules in Tattoo Lettering Tool

A developer rebuilding a name tattoo tool initially considered using an AI language model to classify user text inputs such as initials, name pairs, and dates. After mapping out the actual classification cases needed, they found the problem was too narrow and well-defined to justify an AI model call. Instead, they wrote a small deterministic function using straightforward conditional rules to identify input structure and reorder lettering style recommendations accordingly. The rule-based approach eliminated inference costs, network latency, and unpredictable outputs, while making edge cases easy to reproduce and debug. The product still uses AI for generating custom lettering compositions, but structured input classification proved simple enough to handle with plain code logic.

0
ProgrammingDEV Community ·

How to Build Cost-Safe AI Feature Flags with Incident Rollback in Node.js

Engineering teams running AI experiments on B2B SaaS platforms can manage cost and risk by routing experiment traffic through locally cached feature flags evaluated by each Node.js worker, avoiding live API calls on every request. A small control plane owns flag state with a monotonically increasing revision number, allowing workers to reject stale updates and operators to confirm when changes have propagated. Cost and log events must carry the flag revision and tenant cohort context so that rolling back a flag stops new experiment work without erasing the data needed to evaluate outcomes. Rollback should be treated as a formal state transition with an audit record, including the actor, reason, and a conflict check to prevent operators from accidentally overwriting each other's changes. Keeping the kill switch narrowly scoped and separate from tenant segmentation ensures it remains operable under incident pressure rather than becoming a second, complex routing system.

0
ProgrammingDEV Community ·

Developer shares lessons from building their first GitHub profile README

A beginner developer documented their experience creating a GitHub profile README for the first time, using an Alura article as a reference. The process involved repeated trial and error, including mistakes such as entering their username in incorrect places within the code. They also learned to integrate GitHub Readme Stats via GHStats to display activity metrics and make the profile more complete. Despite the project's apparent simplicity, it marked their first real hands-on exploration of GitHub. The author described the experience as a foundational step in their technology learning journey.

0
ProgrammingDEV Community ·

Agency Agents lets Claude Code and Codex auto-assign AI expert roles for dev tasks

Agency Agents is an open-source project that provides over 230 pre-configured AI expert role profiles — such as Frontend Developer, UI Designer, and DevOps Automator — compatible with tools like Claude Code, Codex, Cursor, and GitHub Copilot. Instead of manually writing lengthy role-setting prompts each time, developers can install specific agent profiles and invoke them directly during their workflow. A tutorial published on DEV Community walks through installing Agency Agents on Windows and Mac, and guides users in setting up a custom Router Skill that automatically selects the most appropriate agent based on the complexity of the task described. The Router Skill is designed to distinguish between simple edits that need no specialist and complex tasks that warrant delegating to a domain expert. Configuration files for both Claude Code and Codex are available on GitHub, along with optional global rules to make the routing behavior more proactive.

0
ProgrammingDEV Community ·

Developer Releases Lightweight macOS Terminal Cleaner as Single Bash Script

A developer known as ombak has published an open-source macOS cache and system-file cleaning tool on GitHub. The utility is built as a single Bash script, requiring no external dependencies to run. It is fully compatible with the native macOS Bash environment, supporting version 3.2 and above. The tool is designed to be used directly from the Terminal, offering a lightweight alternative to GUI-based cleaning applications. The project is publicly available on GitHub under the username ombak.

0
ProgrammingDEV Community ·

SEBI Algo Trading Rules Now Live: 2FA and Audit Trails Mandatory from April 2026

India's markets regulator SEBI brought new algorithmic trading rules into effect on April 1, 2026, requiring brokers to enforce two-factor authentication for all algo orders and maintain detailed audit trails of every automated trading decision. The regulations draw a clear line between retail traders who build their own strategies and brokers who are responsible for the execution infrastructure. Audit trail requirements mean every algo order must be logged with its inputs, timestamp, and outcome, enabling post-trade reconstruction of any errant strategy. The rules are part of SEBI's broader FY26 agenda aimed at making the costs and risks of uninformed or uncontrolled trading more transparent and traceable. Retail algo traders are advised to confirm their broker supports the new authentication flow and to maintain independent logs alongside those kept by their broker.

0
ProgrammingDEV Community ·

Engineer Adapts Industrial IoT Platform to Monitor Dog Health in Weekend Demo

A developer at an industrial IoT company built a dog health monitoring demo called PawTrack by repurposing DGIOT, their open-source platform used across 928 gateways in oil fields and maritime operations. The system uses a simulated smart collar to stream a dog's heart rate, body temperature, activity level, and battery status every two seconds via MQTT. A key feature is the DLAS ontology engine, which applies breed-specific health reasoning — for example, flagging activity drops in Golden Retrievers as higher risk due to hip dysplasia susceptibility. Digital twin technology, already used to manage remote industrial sensors during outages, keeps the system stable when the collar loses connectivity. The project, built in a single afternoon, was submitted as an entry to Dev.to's Dog Days Challenge, with the underlying platform available on GitHub under an Apache 2.0 license.

0
ProgrammingDEV Community ·

Tutorial: LSTM and TSFresh Pipeline Built to Predict Hypoglycemia 30 Minutes Early

A technical tutorial published on DEV Community outlines how to build a machine learning pipeline for real-time Continuous Glucose Monitoring (CGM) analytics. The system combines LSTM neural networks and TSFresh feature extraction to predict hypoglycemia risk up to 30 minutes before it occurs. It uses InfluxDB for time-series data storage and TensorFlow or PyTorch as the deep learning backend. The pipeline processes high-frequency glucose readings from devices like Dexcom or Abbott Libre, extracting statistical features such as velocity and acceleration of glucose curves. The goal is to reduce alarm fatigue and enable closed-loop alerts or automated insulin adjustments based on anomaly scores.

0
ProgrammingDEV Community ·

How to Route Audio Transcription When ASR Models Are Unavailable in 2026

When a speech-to-text API returns a 404, 501, or available=false response, developers should treat it as a capability signal and immediately route audio to a configured external provider rather than retrying. For marketplace platforms processing supplier invoice audio, transcription is just the first step — the real requirement is an auditable chain linking audio attachments to extracted invoice fields, tied to a specific tenant, region, and provider. A stable operation ID should be created at ingestion and carried through every stage, while a separate attempt ID changes on each network call to enable exactly-once posting semantics without assuming reliable HTTP delivery. Tenant-level usage tracking is essential for month-end reconciliation, as a shared API key with an unlabelled total is insufficient to attribute transcription charges accurately. Developers are advised to check the model catalog before building upload or retry logic, and to handle data retention and deletion obligations for audio, transcripts, and extracted fields as distinct policy decisions guided by legal and compliance teams.

0
ProgrammingDEV Community ·

How a Metric Data Dictionary Makes Cybersecurity Dashboards Reproducible and Trustworthy

Cybersecurity dashboards often appear precise but fail when two analysts cannot reproduce the same number from the same data, typically because metric definitions are incomplete or scattered. The root cause is an undefined metric contract — missing scope, formula, denominator, source, and exception rules — rather than a flawed charting tool. NIST recommends a structured measurement program that documents scope, numeric formulas, targets, data sources, responsible parties, and reporting formats for each metric. A practical data dictionary consolidates these elements into a single reviewable record per metric, covering fields such as grain, numerator, denominator, validation tests, and exception policies. Security program managers and GRC leads are advised to assign each metric a stable ID and complete all definition fields before the metric enters any recurring report.

0
ProgrammingHacker News ·

Magnitude 7.7 Earthquake Strikes Near Ende, Indonesia

A powerful 7.7 magnitude earthquake struck approximately 68 kilometres north-northwest of Ende, a city located on Flores Island in Indonesia. The seismic event was recorded and reported by the United States Geological Survey (USGS). Indonesia sits within the Pacific Ring of Fire, making it one of the most seismically active regions in the world. Authorities and monitoring agencies were expected to assess the potential for tsunamis or significant damage following a quake of this magnitude.

0
ProgrammingDEV Community ·

Mixedbread AI Launches Toast 1 Embedding Model to Rival OpenAI at Lower Cost

Mixedbread AI has released Toast 1, an open-weight text embedding model that outperforms OpenAI's text-embedding-3-large on the MTEB benchmark with a score of 68.4 versus 67.9. The model supports over 50 languages and offers variable output dimensions, including Matryoshka embeddings that allow vector truncation while retaining most semantic information. Mixedbread attributed the model's performance to high-quality training data curation and transformer architecture improvements rather than sheer data volume. OpenAI's competing model costs $0.13 per million tokens, while Toast 1 can be self-hosted on a consumer GPU with 8GB VRAM, potentially reducing costs to a fraction of that figure. The model is aimed at developers building RAG systems, semantic search, and document classification applications at scale.

← NewerPage 89 of 1301Older →