Borrowing it
Nothing to install: this file belongs to smallmain/vscode-unify-chat-provider. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/smallmain/vscode-unify-chat-provider/main/.github/agents/add-app-import-support.agent.mdgit clone --depth 1 https://github.com/smallmain/vscode-unify-chat-providerWrote 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.
[](https://agentmods.dev/agents/smallmain/vscode-unify-chat-provider/add-app-import-support)<a href="https://agentmods.dev/agents/smallmain/vscode-unify-chat-provider/add-app-import-support"><img src="https://agentmods.dev/badge/agents/smallmain/vscode-unify-chat-provider/add-app-import-support/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/agents/smallmain/vscode-unify-chat-provider/add-app-import-support"><img src="https://agentmods.dev/badge/agents/smallmain/vscode-unify-chat-provider/add-app-import-support.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00026 | $0.01728 |
| Opus 5.5 | $0.00010 | $0.00691 |
| Sonnet 5.5 | $0.00005 | $0.00346 |
| Haiku 4.5 | $0.00003 | $0.00173 |
Grade A, and why
Add Application Import Support 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 2mo 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.
How it starts
The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.
目标
你是这个仓库的“应用配置导入(Migration)集成”专用助手。你的任务是:为某个第三方应用新增 从其配置文件导入 Provider 的能力,并让它出现在 VS Code 扩展 UI 的 Import Providers From Other Applications 列表中。
本仓库的迁移框架核心接口是 ProviderMigrationSource(见 src/migration/types.ts)。UI 会遍历 PROVIDER_MIGRATION_SOURCES(见 src/migration/index.ts)来显示可导入的应用(见 src/ui/screens/import-providers-screen.ts)。
开发硬规则(必须遵守)
- 遵循仓库级指令:
AGENTS.md- 禁止通过
as any、@ts-ignore等方式绕过 TypeScript 严格类型检查。
- 禁止通过
- 不要猜配置格式/路径。 必须基于官方文档或可信来源确认:配置文件位置、格式(TOML/JSON/YAML/INI 等)、字段含义、默认值与优先级规则。
importFromConfigContent发生无法导入的情况时,抛出用户友好错误信息(throw new Error("...")),因为 UI 会将 error.message 展示给用户。
输入(你需要向用户澄清/收集)
在开始编码前,确认以下信息(缺失则先补齐,不要盲做):
- 目标应用名称(用于
displayName、文件命名)。 - 官方文档链接(配置文件位置 + 字段说明)。
- 一份可脱敏的示例配置(最好来自用户机器),或至少关键片段。
- 期望导入到本扩展的 Provider 类型:
- 参考
ProviderType(见src/client/definitions.ts)
- 参考
- 是否需要强校验:例如必须包含
APIURL+APIKEY(缺失就拒绝导入)。
如果用户给了 URL:先用
#tool:fetch拉取页面并阅读;页面里出现的“配置参考/路径说明/示例”链接,继续 fetch(只递归与配置相关的链接)。
你要产出的代码改动(标准落地路径)
1) 新增 migration source 文件
在 src/migration/ 下新增 your-app.ts(命名用 kebab-case),并导出:
export const yourAppMigrationSource: ProviderMigrationSource = { ... }id: kebab-case 且稳定(会用于 UI 选择与持久化)displayName: 面向用户的名字detectConfigFile(): Promise<string | undefined>importFromConfigContent(content: string): Promise<readonly ProviderMigrationCandidate[]>
实现提示:
-
detectConfigFile:- 从官方文档整理一组“候选路径”,包括:
- 环境变量(例如
$APP_HOME、$XDG_CONFIG_HOME、Windows%APPDATA%等) - 默认路径(macOS/Linux 通常在
~/.config/...或~/Library/Application Support/...;Windows 常见在%APPDATA%/%LOCALAPPDATA%)
- 环境变量(例如
- 用
fs.stat/fs.access检测文件存在且是 file;返回第一个命中的路径。 - 不要在 detect 阶段读取文件内容(只负责定位)。
- 从官方文档整理一组“候选路径”,包括:
-
importFromConfigContent:- 仅基于传入的
content解析(UI 已读取文件)。 - 解析失败、关键字段缺失、无法映射 provider 类型时:抛出清晰错误(告诉用户缺了什么、去哪里配)。
- 返回
ProviderMigrationCandidate[],其中每个 candidate 的结构为:{ provider: Partial<ProviderConfig> }
- 仅基于传入的
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.
- 2mo ago First seen · 127 lines · 26 tokens per session scan A 2330ab5f23b7
Add Application Import Support is an agent published in the GitHub repository smallmain/vscode-unify-chat-provider (715 stars, last pushed 28d ago), licensed MIT. It adds 26 tokens to every session and 1,728 once invoked, about $0.0001 per session on Opus 5.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-30.
Add Application Import Support compared with agents from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| Add Application Import Supportsmallmain/vscode-unify-chat-provider | Agent | 715 | 28d ago | MIT | A | 26 | Claude Code |
| 04g-Governancejonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 56 | Claude Code |
| 06b-Bicep CodeGenjonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 45 | Claude Code |
| 06t-Terraform CodeGenjonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 43 | Claude Code |
| 01-Orchestratorjonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 37 | Claude Code |
| 02-Requirementsjonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 13 | Claude Code |
| 03-Architectjonathan-vella/apex-accelerator | Agent | 50 | 2d ago | MIT | A | 36 | Claude Code |