Skip to main content

Sema

Sema

PyPI version Python versions VS Code Marketplace Platform: macOS | Linux License: MIT

Love Cursor? You'll love Sema.

Sema is a VS Code extension, an agentic assistant, and a semantic indexer — a Cursor-style chat that already knows your codebase, except you pick the provider and the model, and you can switch mid-conversation.

  • The indexer gives every provider real semantic search. Through the extension, all providers use it; and Claude Code and Codex can use it directly in their official apps or CLIs — over MCP, no sema extension needed (see docs). Either way they stop burning tokens hunting for files.
  • The extension gives you one chat panel with eight engines — Claude Code, Codex, Open Code, Anthropic, OpenAI, DeepSeek, OpenRouter, Together AI.
  • Agent permission controls let Claude Code and Codex pause protected actions for an inline Allow/Reject decision in the Sema chat, or use their clearly marked bypass mode in a trusted sandbox. Each provider keeps its own permission choice.
  • DevOps guard lets your AI provider run real infra commands — kubectl, Terraform, AWS CLI, Helm — safely. Every command is classified (safe / needs-approval / prohibited) and secret-redacted before it runs, never after; mutating actions are held until you explicitly approve them, and irreversible ones are refused outright, no exceptions (see docs).

Sema uses your existing Claude Code and Codex subscription — no extra API key, no re-login. Or bring your own key for any API provider.

Use both, or either one alone.

Experimental · macOS and Linux · Requires Python 3.11+ · Nothing leaves your machine. Disclaimer

Install

1. Install the CLI (bootstraps uv + Python if needed):

curl -fsSL https://raw.githubusercontent.com/masihmoloodian/sema/main/install.sh | sh

2. Install the extension from the VS Code Marketplace (or search "sema" in the Extensions view). Want to build it yourself? See the docs.

3. Index and register. Open your project, then use the extension's Manage panel to build the index and register your AI CLIs in a click — or do it from the CLI:

cd your-project
sema index .     # build the local semantic index
sema setup       # register with every detected client: Claude Code, Codex, opencode, Grok Build, Cursor

Keep the local coding-agent CLIs current so newly released models and effort levels are available:

sema update --check              # show installed Claude/Codex/opencode versions
sema update                      # run every installed agent's official updater
sema update --provider codex     # update one agent only (repeatable)

The extension exposes the same workflow under Manage → Update agent CLIs…. Reload VS Code after an update so its model picker reflects the installed CLI.

Want just the extension or just the index? Both work standalone. Plus manual installs, requirements, and troubleshooting — for more details see the Installation guide.

4. Or skip the editor entirelysema chat is a full coding agent in your terminal, with the same modes, providers, and tools as the extension:

uv sync --extra chat      # or: pip install 'sema-mcp[chat]'
sema chat                 # interactive TUI
sema chat --print "where is auth handled?"   # one-shot, for scripts

Sessions are shared with the VS Code extension, so a conversation started in the editor resumes in the terminal and back. Terminal app guide →

📦 sema-mcp on PyPI · 🧩 Extension on the VS Code Marketplace

Why

Cursor is great — it's also a subscription and a walled garden. Claude Code and Codex are great too, but they lock you to one model per session, and they start every session cold: burn tokens just navigating before they answer anything.

Sema indexes your code once, locally. Your assistant searches it instead — typically 4–11× fewer tokens per question. And check_reuse() tells it whether a helper already exists before it writes a fourth one.

4–11× fewer tokens per question
98% reuse-vs-build accuracy (50-example eval)
~150 tokens per search — signatures, not whole files
0 code that leaves your machine

Why sema exists, in full → · Benchmarks →

Documentation

Start here: Installation · sema for VS Code · CLI reference

Installation Platforms, requirements, install paths, from source
sema for VS Code The extension — chat, agent, search, reuse
Claude Code · Codex · opencode · Grok Build · Cursor · VS Code workspace Register sema with your assistant
Multiple projects Serve many repos from one registration
CLI reference Every sema command
MCP tools The tools your AI assistant calls
DevOps guard Analyze-first gate for kubectl/Terraform/AWS CLI/Helm — safe/needs-approval/prohibited tiers, secret redaction
Supported languages AST-aware vs text-aware indexing
Configuration Config file, env vars, .gitignore
Managing sema Update, remove, and when to re-index
Troubleshooting Fixes for common issues
Why sema · Benchmarks · FAQ · Roadmap Background and details
Architecture · Contributing How it works, how to extend it

License

MIT — see LICENSE. Copyright (c) 2026 Masih Moloodian.

Masih Moloodian · masihmoloodian@gmail.com · Issues

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sema_mcp-0.10.0.tar.gz (121.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sema_mcp-0.10.0-py3-none-any.whl (149.2 kB view details)

Uploaded Python 3

File details

Details for the file sema_mcp-0.10.0.tar.gz.

File metadata

  • Download URL: sema_mcp-0.10.0.tar.gz
  • Upload date:
  • Size: 121.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sema_mcp-0.10.0.tar.gz
Algorithm Hash digest
SHA256 afd6a84f89733a3c6cc0979e506210f82a7060e93318af30ad882daa3d27c39b
MD5 0336ac319a5cf92f37be722cc5d527ba
BLAKE2b-256 ff163d58928dc1434b2bf25f2a502b3f4c3ae735511f57c0c79f1b153ac8c19b

See more details on using hashes here.

File details

Details for the file sema_mcp-0.10.0-py3-none-any.whl.

File metadata

  • Download URL: sema_mcp-0.10.0-py3-none-any.whl
  • Upload date:
  • Size: 149.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sema_mcp-0.10.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b1fb176674824a31e8409ba3283a2ac5464005ddb9294e0886aebd089cf06c22
MD5 bc0d773de3d347e228daf8e57d47d1e0
BLAKE2b-256 58cff17c00d49daaae74df5fe5450882deec5f05606bba1ccf8a8ce2f698f61c

See more details on using hashes here.

Release history Release notifications | RSS feed

0.11.0

2 files

This release

0.10.0 This release

2 files

0.9.0

2 files

0.8.0

2 files

0.7.0

2 files

0.6.0

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.0

2 files

0.1.2

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page