headless-bot

Creates and configures headless LingTai bot projects with Telegram MCP wiring.

692|60|Updated Mar 15, 2026
One-click install
npx skills add https://github.com/Lingtai-AI/lingtai --skill headless-bot
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: headless-bot
Source: https://github.com/Lingtai-AI/lingtai/tree/main/tui/internal/preset/skills/swiss-knife/reference/headless-bot
Command: npx skills add https://github.com/Lingtai-AI/lingtai --skill headless-bot

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Setting up a LingTai-backed chat bot normally requires stepping through the interactive TUI and manually wiring addons, MCP servers, secrets, and preset policies. This Skill automates that bootstrap so a bot project can be created and verified entirely headlessly, without leaking tokens into shell history or config files.

Core Features & Use Cases

  • Automated Telegram Bot Provisioning: Runs lingtai-tui spawn, writes the Telegram sidecar secret with mode 0600, registers the telegram addon and MCP server in init.json, and triggers a refresh.
  • Preset Policy by Reference: Copies only the manifest.preset policy block from an existing agent's init.json instead of duplicating preset JSON files, avoiding stale configuration.
  • Security-First Handling: Reads the bot token from the environment rather than argv, redacts token-like values in output, and enforces allowlists and restrictive file permissions.
  • Use Case: You want a Telegram-facing LingTai agent that mirrors your orchestrator's model presets. Run the helper with the project directory, preset, agent name, and allowed user IDs, then verify with getMe and a /start message.

Quick Start

Ask the agent to create a headless Telegram bot project in a new directory using the minimax preset, with your Telegram user ID allowlisted and the preset policy inherited from an existing agent's init.json.

Frequently Asked Questions about headless-bot

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a LingTai Telegram bot without the TUI?

Run the bundled create_telegram_bot_project.py helper with --project-dir, --preset, --agent-name, and --allowed-users. It calls lingtai-tui spawn, writes the Telegram secret file, patches init.json with the addon and MCP entries, and touches .refresh to reload the agent.

How do I pass the Telegram bot token securely?

Export TELEGRAM_BOT_TOKEN in the environment, for example with read -rsp, instead of passing it as a command-line argument. The helper deliberately refuses argv tokens because shell history and process monitors can capture them, and it redacts token-like strings in output.

Can the new bot reuse an existing agent's preset configuration?

Yes, pass --preset-policy-from pointing to the source agent's init.json. The helper copies only the manifest.preset policy block referencing saved or template presets, rather than duplicating preset JSON files into the new project.

Does the helper support chat platforms other than Telegram?

Currently the bundled helper only implements the Telegram MCP case. The reference is designed to be channel-agnostic, so future helpers for other chat surfaces should live under this same generic reference rather than new top-level skills.

Why is my Telegram bot not responding after setup?

Check lingtai-tui list for duplicate or dead agents, confirm the Telegram listener appears in the agent log, and verify getMe succeeds with the token. If refresh is insufficient, relaunch or CPR the agent instead of starting a second copy.