跳到主要内容
知仓学习社ZHICANG

context-mode

Mandatory routing rules for Antigravity CLI. Invoke when exploring a codebase, reading files for analysis, listing context-mode tools, searching, pa…

不碰外部(只输出文字)无严重或高危命中mksglu/context-mode

它会碰到什么

扫了多少1 个文本文件,3 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

context-mode for Antigravity CLI

context-mode MCP tools are available in agy as context-mode/<tool>.

Use these tools directly. Do not inspect cached schema files under

~/.gemini/antigravity-cli/mcp/context-mode/*.json, and do not run

ctx_execute just to discover tool names or schemas.

If agy uses the generic MCP wrapper, call call_mcp_tool with:

  • ServerName: "context-mode"
  • ToolName: one of the tool names below
  • Arguments: the JSON arguments for that tool

Tool List

  • context-mode/ctx_execute: run JavaScript, TypeScript, Python, shell, or

other code in a sandbox. Print only the final answer.

  • context-mode/ctx_execute_file: read one file into FILE_CONTENT inside the

sandbox and run code over it. This is the context-mode file-read surface.

  • context-mode/ctx_batch_execute: run multiple repository commands in one

batch, index large output, and answer follow-up queries.

  • context-mode/ctx_index: store a file, directory, or content in the local

FTS5 knowledge base for later search.

  • context-mode/ctx_search: search indexed content and captured session

memory. Batch related questions in queries.

  • context-mode/ctx_fetch_and_index: fetch web content, store it, then query

with ctx_search.

  • context-mode/ctx_stats: show context savings and current-session stats.
  • context-mode/ctx_doctor: diagnose context-mode runtime and hook health.
  • context-mode/ctx_upgrade: provide upgrade or repair guidance.
  • context-mode/ctx_purge: purge stored context-mode knowledge after

confirmation.

  • context-mode/ctx_insight: launch or report the Insight analytics app.

When the user asks "what context-mode tools are available", answer from this

list. Do not list ~/.gemini/antigravity-cli/mcp/context-mode and do not read

the JSON schema files.

File Reading

There is no separate ctx_read tool. Use context-mode/ctx_execute_file for

file reads that analyze, summarize, extract, count, filter, or compare.

Native Read / view_file is only right when editing needs exact bytes in the

conversation, or when the user explicitly asks to view a small known range.

Use JavaScript by default for lightweight file analysis:

{
  "path": "README.md",
  "language": "javascript",
  "code": "const lines = FILE_CONTENT.split(/\\r?\\n/); console.log(lines.slice(0, 20).join('\\n'));"
}

Never print FILE_CONTENT wholesale unless the user explicitly asks for a full

file dump. Print selected lines, counts, matches, summaries, or structured

results.

Codebase Exploration

For repository exploration, prefer one context-mode/ctx_batch_execute call

instead of many native ListDir, Read, Grep, or shell calls.

For one-off computed answers, use context-mode/ctx_execute.

For one-file analysis, use context-mode/ctx_execute_file.

For durable recall across follow-up questions, use context-mode/ctx_index

with a descriptive source, then context-mode/ctx_search.

Return concise derived answers. Do not paste raw command dumps, full files,

large search results, cached schemas, or raw HTML into the conversation.

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

它属于哪个仓库

星标★ 23,197
本站分层T1
该仓技能数11
原文件路径configs/antigravity-cli/skills/context-mode/SKILL.md

同一个仓库里的其他技能

看这个仓库的全部 11 个技能

同名技能的其他版本

有 3 个不同仓库或目录里都有叫 context-mode 的技能。它们内容并不相同,别混用: