mksglu/context-mode

Source
GitHub
First trending
Category
Agents
GitHub stars
28,827
Main language
TypeScript
Website
context-mode.com (opens in a new tab)

This page introduces an external open-source repository. It is not an HDATF product.

mksglu/context-mode

What it does

Context Mode is an MCP server and hook plugin for developers who use AI coding agents, and it keeps large tool output out of the model's context window and restores the working state after a conversation is compacted. Of its 11 MCP tools, ctx_execute, ctx_batch_execute and ctx_execute_file run code in 12 languages in a separate subprocess and pass only the printed result into context. The ctx_index, ctx_search and ctx_fetch_and_index tools store Markdown and fetched web pages in a SQLite FTS5 index and return only the matching passages ranked by BM25. Hooks redirect curl, wget and web fetch calls to these tools and record file edits, git operations, errors and user decisions in a per-project SQLite database, and the README says that starting a new session without --continue deletes the previous session data. After compaction they inject a resume snapshot with per-category summaries and search calls, and the code at the pinned commit ignores the 2 KB limit that the README states. It needs Node.js 22.5 or later or Bun, Claude Code installs it as a plugin from its marketplace, and other clients take MCP server and hook entries in their config files or use a client-specific plugin. An MCP-only install gives the tools without automatic routing, and session continuity is full on Claude Code and others, partial on Cursor, Codex CLI and Kiro, and absent on the Antigravity IDE and Zed. The README states that nothing leaves the machine and that there is no telemetry, but the server checks the npm registry for the latest version at startup and ctx_insight opens the Insight dashboard on context-mode.com. The hooks/platform-bridge.mjs file, which the README does not describe, posts every session event to the configured Insight server whenever platform.json holds an API key and a server address, after masking some secret patterns, email addresses and home folder paths. The ctx_execute_file tool is confined to the project folder, but the README says ctx_execute and ctx_batch_execute run arbitrary code with the process's own file access and asks users to keep host-level sandboxing on. The user's permission deny rules also apply inside the sandbox tools, and ctx_fetch_and_index allows local and private network addresses unless CTX_FETCH_STRICT=1 is set. The LICENSE file is the Elastic License 2.0 (ELv2), which allows use, modification and redistribution but forbids offering the software to third parties as a hosted or managed service and removing license notices.

License

Custom license Custom or non-standard license. Read the license file before any reuse.

More in this category

  • T-Auto/dsh-ops
    dsh-ops is a third-party plugin for DeepSeek Harness (DSH) that gives AI agents on Windows their own bash and PowerShell 7 plus Rust file tools so they spend fewer tokens and less time on repeated PowerShell errors. Version 0.3.0 supports only Windows x64, targets DSH 0.2.0-rc.2 and needs Node.js 22.19 or later on the 22 line or version 24 and later, and it installs from the DSH plugin marketplace or with an npx command. The shell component, on by default, publishes ops_bash and makes the host pwsh tool use the bundled PowerShell 7 while leaving the system default terminal and PATH unchanged. The file component, also on by default, runs the file tools in a separate Rust worker and offers a dry run and atomic replacement for edits. Of the two components that are off by default, the background component handles long jobs only in danger-full-access sessions, and the PTC component adds ops_batch only in PTC-only sessions, in which tools are called through an SDK from code. The ops_batch tool runs copy, move and remove operations with SHA-256 checks, a per-item state written before each effect and resume after interruption, and its audit records are plain local records under the .dsh-ops folder that the workspace owner can alter. In the DSH read-only and workspace-write modes, arbitrary Bash and PTC code runs inside OS confinement with no unconfined fallback, but the Windows host reports this confinement as partial. The danger-full-access mode skips this confinement by design, and the plugin backs up the original permissions of workspace root folders owned by the current user and then adds WRITE_OWNER on that folder only. The bundled bash and PowerShell 7 arrive as optional npm packages of 161.2 MB and 107.6 MB packed, and if a registry mirror lacks them the install still ends with exit code 0 and no warning. The 97 percent and 65 percent token reductions in the README come from the author's own benchmark, while the PTC design document states that no fixed saving and no real model-turn benchmark is claimed. The LICENSE file puts the plugin under MIT and FastCtx under Apache-2.0, the bundled shells keep their GPL (Git for Windows) and MIT (PowerShell) terms, and PROVENANCE.md says the GPL source delivery has not been reviewed. The docs record that live installation on each DSH version has not been attested and that on 2026-10-08 an earlier version made every new DSH session fail through a tool registration conflict, which the current design avoids by registering only its own tools.
  • rociiu/talorys
    Talorys is a personal AI assistant that one owner deploys into their own Cloudflare account, bringing chat, memory, tasks, notes, projects and reminders together in one browser app, and the repository describes version 0.1.4. There is no signup, the owner password is hashed locally with PBKDF2-SHA256 and stored as a Cloudflare secret, and the public pages.dev address is protected by that password, a SameSite=Strict session cookie and login lockouts. Requests go from a Cloudflare Pages app with a React screen to a private Worker without a public URL, one Durable Object built on the Cloudflare Agents SDK keeps conversations, memories, tasks, notes, projects, automations, settings and usage in SQLite, and the owner can download a backup file that leaves out sessions and credentials. The input is text typed into the chat, and the reply streams back as Markdown from Workers AI, by default @cf/zai-org/glm-4.7-flash, while the screen shows which tools are being called. Memories are facts and preferences the owner can view, edit and delete, at most 8 go into each turn with full-text matches first and up to 4 recent preferences filling the rest, and semantic recall with @cf/baai/bge-m3 is off by default and has a default cap of 500 embeddings a day when turned on. Tasks, notes and projects can be edited on screen or from chat, and a chat request to delete a task, note or memory becomes a proposal that runs only after the owner presses Approve in the app. Automations include one-time and recurring reminders, a task digest of due and overdue tasks made without AI, and AI prompt runs limited to read-only tools and 200-word answers, repeating daily, on chosen weekdays, monthly or every 15 minutes to 31 days on Durable Object alarms, and results arrive in the in-app notification center, with no push or email delivery found in the code that was read. Default limits are 1,024 output tokens, 6 tool calls and 6,000 context tokens per turn with older history summarized, plus 200 AI requests and 6 scheduled AI runs a day, each adjustable up to a set ceiling, and tasks, notes, memories and reminders keep working after the AI quota runs out. Deployment runs npx create-talorys@latest on Node.js 22 or later with Cloudflare's browser login or an API token holding Workers Scripts Edit, Cloudflare Pages Edit, Workers AI Read and Account Settings Read, and data stays in the owner's account without telemetry while Cloudflare processes chat messages and the memories in prompts for Workers AI inference. The README says the design fits the Workers Free plan under quotas that Cloudflare sets and can change, and at the time of writing Cloudflare gives 10,000 Workers AI Neurons a day, so on the free plan chat stops after that until the 00:00 UTC reset, while a paid plan has a $5 monthly minimum and bills extra Neurons at $0.011 per 1,000.
  • onehumanbeing/esp32-iphone-agent
    ESP32 iPhone Agent is an MIT-licensed project made of a Python server and Arduino firmware that lets an AI vision model operate a real iPhone without a Mac, Xcode, a developer account, an app on the phone or a jailbreak. It is for developers and hobbyists who want to automate an iPhone through the same paths a person uses, the screen and a pointer, and the README asks users to automate only devices and accounts they own or are allowed to use and to follow each app's terms. The phone mirrors its screen over AirPlay to UxPlay on a macOS or Linux computer, where GStreamer turns it into JPEG frames, and an ESP32-S3 board plugged into the phone's USB port appears as a standard USB mouse and keyboard. With iOS AssistiveTouch (an accessibility setting that shows an on-screen pointer) turned on, a click becomes a tap and a drag a swipe, and the board carries out only simple one-line commands such as click and type received over 2.4 GHz Wi-Fi. All decisions are made by a FastAPI server on the computer, and in that code the web API and the board port listen on every network interface by default without a login, with commands sent as plain text over TCP. A user types a goal into the web page on port 8890, a planner model writes a plan of up to 6 steps, and an actor model returns up to 6 actions such as tap and swipe in coordinates from 0 to 1000 for each new screenshot. Because the pointer moves relatively, the server calibrates it by wiggling it and finding it on the mirrored screen, checks after each action whether the screen changed and tells the model, and re-plans when the same action repeats without effect. A run ends at 40 steps or after 3 errors in a row, and the web page shows a step wall with the screenshot behind each decision and its action drawn on top, plus an emergency stop that the Esc key also triggers. Setup needs an ESP32-S3 board flashed with the firmware (the tested board is the Seeed XIAO ESP32S3 at about 7 dollars), a USB-C iPhone or a Lightning iPhone with a camera adapter, and Python 3.10 or later. The model can be any OpenAI-compatible chat API that accepts images, with separate models possible for the planner and the actor, and since every call carries the current screenshot, with a cloud API whatever the phone screen shows goes to that provider. Development and timing used a local model on two NVIDIA DGX Sparks (about 1.3 seconds per action and 2 seconds per plan), and the bundled serve folder holds an experimental server whose full agent run is still untested. The README lists its limits: iOS keeps passcode entry, Apple Pay and DRM video out of mirroring so the agent cannot see them, mirroring stops when the phone locks, typing is ASCII only, and landscape apps remain unsupported.
  • FeiZhuLulu/DeepSeek-Bot
    DeepSeek-Bot (DS Bot) is a bot plugin installed into DeepSeek Harness (DSH) that adds the ability to create several bots with their own names and roles, talk with them, and hand work to them as a group. It is aimed at DSH users who want to split work among several AI bots, and the repository states that it is an independent community project separate from official DeepSeek products. Each bot is a DSH session with its own name, role, instructions and model, the bots exchange messages through the message_bot, create_bot, update_bot and ask_user tools, and a default bot called Chief manages the others. In group chats the admin bot answers by default, a mention passes the turn to another bot or a PASS marker skips a turn, and each member keeps a hidden session per group. Instead of DSH's conversation compaction, a bot writes a checkpoint through a separate call to a small model when context usage reaches 0.8. Memory is split into per-bot and team scopes and managed through the remember, forget and recall tools and a review after every turn, with limits such as 300 characters per entry and 4,000 characters for MEMORY.md, and content that looks like a secret is rejected. Web search tries the provider set in the profile, then search through the model route, then public Bing and DuckDuckGo result pages, and the bot browser in Desktop reads pages as Markdown in a read-only view separated per bot, skipping password and card fields. request_secret is described as passing a value received through a user input card only as a shell variable and keeping it out of state.json and logs, but only exact copies are masked, so encoded or split values can leak, file mode 600 has no effect on Windows, and values are sent in clear text on a page opened over http. Installation is done through Add plugin in the Plugins menu of DSH Desktop (Windows, macOS), or by assembling a configuration bundle in DSH Web with Node.js 22.19 or later and pnpm, and installing DSH and connecting the plugin are separate steps. The documentation says this is an early v0.1 release whose features, tools and storage format may change and that it was tested with dsh 0.2.1-alpha.1 on Linux, data is stored by default under .dsh/bot in the user folder, and the usage screen shows tokens only, without cost.
  • docker/docker-agent
    docker-agent is an AI agent runtime from Docker that defines agents in a YAML file and runs them with the docker agent command. The YAML lists the model, instructions, toolsets, sub-agents, fallback models, an iteration limit and skills. Tools are attached as MCP servers through the Docker MCP Gateway, local stdio or remote HTTP, alongside built-in tools such as think, todo and memory. Memory is kept in a SQLite file in the user's home folder, and RAG supports search that mixes BM25 with embeddings, plus reranking. Models come from external providers such as OpenAI, Anthropic, Gemini and Bedrock or from local models in Docker Model Runner, and the user sets the API keys. It installs as a plugin bundled with Docker Desktop 4.63 or later, or through Homebrew and release binaries. By default it asks the user before running tools with side effects, and permission rules can be applied in deny, allow, ask order. The --yolo option approves every tool automatically, sandboxed runs need Docker Sandboxes installed separately, and the working folder is mounted with write access. It also hands work to CLIs on the PATH such as claude and codex, serves a REST API with a session database, shares agents through OCI registries and evaluates by replaying saved sessions. Telemetry is on by default, and the documentation says not to assume the collected data is free of secrets or personal information.

Only repositories in the ranked Trendshift lists are included, and the lists are used only to find candidates. We do not copy their ranks. Descriptions, licenses and star counts come from each GitHub repository. The notes are our own reading. We have not tested these projects, and a place on a trending list does not prove quality.

View on GitHub (opens in a new tab)