chat

chat is a skill for Claude Code, Codex from tonydzi/second-brain-starter-kit. It costs 87 tokens per session (927 once invoked), scanned A, original, MIT.

A local lookup tool for finding a Telegram group, channel, or chat by name and returning its Telegram ID and link from an index.

In plain words
What is it for?
Use it to find chats or direct messages, retrieve their identifiers and links, or check which groups you share with a person or company.
Why use it?
It avoids slowly scanning the live Telegram dialog list and can still match spelling variations, transliterations, typos, and keyboard-layout errors.

Skill for Claude CodeCodex

Part of the second-brain-skills plugin — 57 skills shipped together

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/tonydzi/second-brain-starter-kit/chat
Any agent
npx skills add tonydzi/second-brain-starter-kit --skill chat
Clone the repo
git clone --depth 1 https://github.com/tonydzi/second-brain-starter-kit

Made for: Claude Code, Codex.

Or install second-brain-skills, the plugin that ships this one along with the rest of its 57 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for chat

README.md
[![agentmods](https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/chat.svg)](https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/chat)
Your own site
<a href="https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/chat"><img src="https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/chat.svg" alt="Measured on agentmods" height="20"></a>
Per session 87 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 927 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found 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.00087 $0.00927
Opus 5 $0.00044 $0.00464
Sonnet 5 $0.00017 $0.00185
Haiku 4.5 $0.00009 $0.00093

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

Security

Grade A, and why

chat 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 4d 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.

skills/chat/SKILL.md · 71 lines

How it starts

The opening of the file, as written. The whole thing — 71 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/chat — instant Telegram chat lookup

Anton's pain: "find chat X" used to mean 20–60 min crawling the live dialog list. The chat's telegram_id + link already live in chats.db (built from the CRM tg_entities dump — the same extraction the CRM's mtproto-api does). Look it up, get the id, then operate the chat directly via the Telegram MCP.

Rule (always)

When you need to act on "some chat by name", FIRST query the local index — never crawl the live dialog list blind. Memory: [[telegram-chat-index]].

Lookup — find_chat.py

cd $IMPORTS_ROOT/dialogs
PYTHONUTF8=1 python find_chat.py <query words>      # chats first, then people
PYTHONUTF8=1 python find_chat.py <query> --all      # include user DMs
PYTHONUTF8=1 python find_chat.py <query> --limit 80

Prints [TYPE] telegram_id name t.me-link (+members). Matching reuses ..\namesearch\name_norm.py so wrong-layout (dbrnjh) / translit / typos still hit. ⚠️ ALWAYS PYTHONUTF8=1 (else cp1252 crash). The ??? in console = ASCII echo only; the DB stores proper UTF-8 — read it programmatically when you need the real title.

"Common groups with a person / company" — common_groups.py

PYTHONUTF8=1 python common_groups.py @handle [--account corp_acct]
PYTHONUTF8=1 python common_groups.py "Firstname Lastname"
PYTHONUTF8=1 python common_groups.py <telegram_id>

Lists groups where one of OUR accounts sits alongside that person (ours/theirs + which account + link). COVERAGE: rosters are full for small/curated groups, partial for big public ones → for an authoritative per-person answer use the live MCP get_common_chats(user, account).

Visual (Anton works by eye)

_Dashboards\Telegram-Groups.html — all chats, filter by account / ours-vs-theirs / topic / value, search, per-group sub-classification.

Freshness

chats.db backbone = CRM dump (refreshed by the telegram-chat-index-refresh routine that appends live list_chats from Anton's accounts via refresh_chats.py). If a brand-new chat is missing, run that refresh or fall back to live search_dialogs.

Read the full file on GitHub · 71 lines

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. 4d ago First seen · 71 lines · 87 tokens per session scan A 6931af573df1

Subscribe to this mod's changes

chat is a skill published in the GitHub repository tonydzi/second-brain-starter-kit (5 stars, last pushed 4d ago), licensed MIT. It adds 87 tokens to every session and 927 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

wiki-ingest

Ingest supplied source material into an Obsidian vault with provenance and claim tracking: pasted text, files staged in the selected vault's inbox or .raw archive, or explicitly approved URLs. Use for a single source or bounded batch, not for saving an assistant answer. Triggers: ingest, ingest this file, ingest this…

AgriciDaniel/claude-obsidian · 88 tokens

autoresearch

Run a bounded, source-grounded research loop, draft a cited dossier, and optionally propose a separately reviewed canonical vault merge. Use when the user wants autonomous or deep research that may access the public web. Triggers: /autoresearch, autoresearch, research this topic, deep dive into, investigate, find…

AgriciDaniel/claude-obsidian · 80 tokens

canvas

Create, inspect, and update Obsidian JSON Canvas boards with text, file, link, group, and edge nodes. Use for canvas status, canvas lists, visual maps, zones, spatial layouts, adding vault notes or media to a .canvas file, and requests such as create canvas, add to canvas, or put this on the canvas.

AgriciDaniel/claude-obsidian · 72 tokens

wiki-retrieve

Build and query a vault-local contextual BM25 retrieval index with optional multilingual Nomic cosine reranking; use for retrieve, hybrid retrieval, BM25, rerank, contextual retrieval, chunk search, vault search, semantic search, find relevant passages, or retrieval diagnostics. Derived caches stay under .vault-meta…

AgriciDaniel/claude-obsidian · 81 tokens

wiki

Initialize, adopt, and route work for a separate Obsidian knowledge vault through the portable claude-obsidian core. Use for vault setup, scaffolding, workspace selection, cross-project configuration, or choosing the correct wiki sub-skill. Triggers: /wiki, set up wiki, scaffold vault, create knowledge base, adopt…

AgriciDaniel/claude-obsidian · 84 tokens

defuddle

Plan and, with explicit network consent, use an optional external Defuddle cleaner to extract article-like HTTPS pages as Markdown. Use for defuddle, clean this URL, strip page clutter, readable Markdown from a web page, or preparing a web source for later wiki ingestion.

AgriciDaniel/claude-obsidian · 57 tokens