btca-cli

A command-line research tool that searches source code and documentation from Git repositories, local folders, and npm packages. It answers questions using those selected sources as context.

In plain words
What is it for?
Use it to add and manage searchable resources, check configured resources, and ask questions about specific libraries or frameworks, including questions that combine several resources.
Why use it?
It reduces uncertainty when library behaviour or APIs may have changed, because answers are grounded in the relevant source material instead of memory alone.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/davis7dotsh/better-context/btca-cli
Any agent
npx skills add davis7dotsh/better-context --skill btca-cli
Clone the repo
git clone --depth 1 https://github.com/davis7dotsh/better-context

Made for: Claude Code, Codex.

Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 512 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00070 $0.00512
Opus 5 $0.00035 $0.00256
Sonnet 5 $0.00014 $0.00102
Haiku 4.5 $0.00007 $0.00051

Measured 2d ago against content hash de15feb1114a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

btca-cli scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

100% identical to btca-cli — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/btca-cli/SKILL.md · 65 lines

What it actually says

btca CLI

btca is a source-first research CLI. It hydrates resources (git, local, npm) into searchable context, then answers questions grounded in those sources. Use configured resources for ongoing work, or one-off anonymous resources directly in btca ask.

Full CLI reference: https://docs.btca.dev/guides/cli-reference

Add resources:

# Git resource
btca add -n svelte-dev https://github.com/sveltejs/svelte.dev

# Local directory
btca add -n my-docs -t local /absolute/path/to/docs

# npm package
btca add npm:@types/[email protected] -n node-types -t npm

Verify resources:

btca resources

Ask a question:

btca ask -r svelte-dev -q "How do I define remote functions?"

Common Tasks

  • Ask with multiple resources:
btca ask -r react -r typescript -q "How do I type useState?"
  • Ask with anonymous one-off resources (not saved to config):
# One-off git repo
btca ask -r https://github.com/sveltejs/svelte -q "Where is the implementation of writable stores?"

# One-off npm package
btca ask -r npm:[email protected] -q "How is useTransition exported?"

Config Overview

  • Config lives in btca.config.jsonc (project) and ~/.config/btca/btca.config.jsonc (global).
  • Project config overrides global and controls provider/model and resources.

Troubleshooting

  • "No resources configured": add resources with btca add ... and re-run btca resources.
  • "Provider not connected": run btca connect and follow the prompts.
  • "Unknown resource": use btca resources for configured names, or pass a valid HTTPS git URL / npm:<package> as an anonymous one-off in btca ask.
Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 65 lines · 70 tokens per session scan A de15feb1114a

Subscribe to this mod's changes

btca-cli is a skill published in the GitHub repository davis7dotsh/better-context (1,157 stars, last pushed 4mo ago), licensed MIT. It adds 70 tokens to every session and 512 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to btca-cli, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

openapi-glossary

Use consistent OpenAPI terminology and definitions when writing documentation, educational material, and tooling guidance.

scalar/scalar · 24 tokens

scalar-docs

Skill for writing and updating scalar.config.json — Scalar Docs configuration reference for users and LLMs.

scalar/scalar · 24 tokens

vue-components

Build Vue 3 components with TypeScript and Tailwind using clean structure, composable logic, accessibility, and maintainable patterns.

scalar/scalar · 29 tokens

toolset-design

Design and validate new MCP toolsets, tools, and tool changes. Use when planning a new toolset, adding tools to an existing toolset, reviewing a toolset PR, or deciding whether a new tool is warranted. Covers the full lifecycle: eval-first validation, tool design methodology, consolidation patterns, and review…

containers/kubernetes-mcp-server · 69 tokens

mindos

Operate a MindOS knowledge base: update notes, search, organize files, execute SOPs/workflows, retrospective, append CSV, cross-agent handoff, route unstructured input to the right files, distill experience, sync related docs. Use when the task targets files inside the user's MindOS KB (mindRoot). NOT for editing app…

GeminiLight/MindOS · 157 tokens

plugin-core-builtin-migration

将 MindOS 渲染器插件从“可选插件”升级为“完全内置能力(core builtin)”的通用流程。 当用户要求“把某插件改成内置/核心”“插件不应可关闭”“插件主程序化”或需要将旧入口迁移到 新主流程并保留兼容迁移能力时触发。.

GeminiLight/MindOS · 86 tokens