SShortSingh.
Back to feed

ContextOS CLI Trims AI Coding Context to Only Relevant Files, Saving Tokens

0
·1 views

A developer has released ContextOS, an open-source local CLI tool designed to solve the problem of oversized codebases overwhelming AI coding assistants like Claude and Copilot. The tool scans a project repository and generates a compact context pack containing only the files most relevant to a given task, using five signals including keyword matching, import graph centrality, AST symbol overlap, git churn, and secret detection. In one example, it reduced context from roughly 54,000 tokens to under 7,000 — an 87% reduction — while automatically redacting credentials. ContextOS also supports Model Context Protocol (MCP), allowing AI agents to query the repo directly as a tool without using the CLI. The project is available on GitHub under the Apache-2.0 license, runs fully offline with no telemetry, and supports Python 3.11–3.13 on Linux and macOS.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

How Monorepos and Trunk-Based Development Can Eliminate Engineering Bottlenecks

Software teams in growing startups commonly lose 25 to 50 minutes per engineer daily due to redundant builds, bloated CI pipelines, and version drift across internal packages. A monorepo structure with a dedicated packages directory helps reduce code duplication by centralizing reusable UI components and backend modules as loosely coupled, parameterized units. Protecting sensitive business logic through CODEOWNERS files ensures that critical modules like tax calculators or compliance code are only modified by authorized teams. Trunk-based development removes the overhead of private registries and version management, allowing all teams to work against the latest shared codebase simultaneously. Lightweight documentation practices such as workspace READMEs, strict typing, and meaningful code comments are recommended over heavyweight wikis to keep knowledge discoverable within the repository itself.

0
ProgrammingDEV Community ·

How Compilers Learn to Compile Themselves: The Bootstrapping Explained

Bootstrapping in computer science refers to the process by which a compiler is made capable of compiling its own source code, solving a classic chicken-and-egg problem. Developers begin by writing a basic compiler in an existing language like C or Assembly, then use it to compile progressively improved versions of the new compiler. This iterative process continues until the compiler is fully self-hosting, meaning it is written entirely in the language it compiles. The technique traces its roots back to early computing, when programmers entered machine instructions directly in binary before higher-level languages existed. Self-hosting compilers offer key benefits including easier maintenance, better cross-platform portability, and reduced dependency on external low-level languages.

0
ProgrammingDEV Community ·

AWS, uv, and a Small-Model Research Finding Reshape Developer Tooling

AWS has revamped OpenSearch Serverless with stateless OCUs decoupled from storage, enabling true scale-to-zero behavior, 20x faster provisioning, and the removal of per-collection minimum capacity requirements. This makes OpenSearch a more viable option for low-traffic apps and internal tools that previously defaulted to alternatives like Algolia due to idle reservation costs. Separately, the Python package manager uv has introduced native vulnerability scanning via its lockfile graph, making security checks faster and more context-aware, along with optional pre-installation malware detection through an environment variable. Both the OpenSearch NextGen model and uv's audit features are currently in preview, meaning breaking API changes are expected before stable releases. Developers are advised to test these tools on non-critical projects now while avoiding reliance on them for production workflows until APIs stabilize.

0
ProgrammingDEV Community ·

2026 Guide Outlines the Chrome Extension Dev Setup Most Tutorials Skip

A developer guide published on DEV Community highlights the foundational setup steps that most Chrome extension tutorials overlook, focusing on environment configuration rather than jumping straight into code. The guide recommends installing Node.js via a version manager like nvm or fnm, since modern extension toolchains for TypeScript, bundling, and hot reload all depend on it. Developers are advised to configure VS Code with the @types/chrome package and key extensions such as ESLint and Prettier to enable proper API autocomplete and error detection. The guide also stresses creating a dedicated Chrome profile for development to avoid polluting a daily-use browser with experimental extensions. Finally, it explains that Manifest V3 lacks built-in hot reload and identifies three distinct debugging surfaces — service worker, popup, and content script — each requiring a different inspection approach.