 adminandClaude
|
d2263b16c7
|
feat: 配置统一到 ~/.x/xtype/config.json,去掉 env/xop 注入
**影响**
- 配置从三处散落(~/.xtype-engine ~/ssw.ini + 运行时 env 注入)收成一个
~/.x/xtype/config.json:engine + llm{key,base-url,model} +
xunfei{appid,api-secret,api-key}。手改这一个文件即可切引擎 / 换凭据。
- 凭据从「运行时经 xop run --secret 注入 env」改为「明文存 config.json」
(目录 0700 / 文件 0600)。启动方式不再影响行为:open / 双击 / 命令行
读同一份配置,不再依赖 xop→open→LaunchServices 这条会被截断的 env 链。
- 旧路径 ~/.xtype-engine ~/ssw.ini 一律忽略,不迁移。
**改动**
- src/xtype.swift: 删 loadINI/normINIKey 与两处 ProcessInfo.environment 读取;
新增 XTypeConfig/parseConfig/ensureConfig(JSON 解析 + 首启写模板);
LLMConfig.load() 与 XunfeiEngine 凭据改读 config.json。
- src/build.sh: 删全部 xop run --secret 块,改普通 open;python3 只改
engine 字段(OrderedDict 保序,不动凭据);首启建目录 0700 / 配置 0600;
模式名非法直接报错退出。
- src/migrate-vault-to-config.sh: 一次性把 xop vault 凭据搬进 config.json,
用户手跑(明文不进 agent 上下文),幂等只补空缺。
- AGENTS.md 红线 5/6 重写(凭据只存 config.json、不再走 env 注入);
docs/xtype/README.md 引擎选择章节重写;docs/xtype/GOTCHAS.md §11 改写成
「凭据别走 env 注入,读文件」的教训。
Co-Authored-By: Claude <[email protected]>
|
2026-10-22 19:03:01 +08:00 |
|
 adminandClaude Code
|
63b41c9750
|
rename: voicetype → xtype (bundle id, paths, xop vault refs)
- bundle: com.xs.voicetype → com.xs.xtype;CFBundleName/Executable → XType
- 文件: src/voicetype.swift → src/xtype.swift;docs/voicetype/ → docs/xtype/
- 路径: /Applications/VoiceType.app → /Applications/XType.app;/tmp/voicetype.{log,build}
- 配置: ~/.voicetype-engine → ~/.xtype-engine
- 凭据 vault: xf_vt_{APPID,APISecret,APIKey} → xf_xt_*
- 文档: AGENTS.md / README.md / GOTCHAS.md 全量替换
- git remote: x/voicetype → x/xtype
影响 TCC:bundle id 变了,用户首次装需重新授三件套(麦/语音/辅助)。
用户操作:已 killall VoiceType + 删旧 .app + 迁 vault + remote set-url。
Co-Authored-By: Claude Code <[email protected]>
|
2026-10-07 11:01:09 +08:00 |
|
 adminandClaude Opus 5.5
|
b380eaf252
|
voicetype: Apple 端侧 + LLM 异步精修,可选 xunfei/dual
新增 apple-llm 引擎(默认):Apple SFSpeechRecognizer → 贴原文 → LLM (~1s,
thinking=disabled) → 退格覆盖精修版。LLM 走 ~/ssw.ini [llm-api],无配置
静默回退 Apple 原文。
- 删 localClean(中文无空格,正则误伤'好啊'等正常词)
- pickEngine() 默认 apple-llm
- LLMCleaner 自动带 thinking: {type: 'disabled'} (GLM 7s+ → ~1s)
- build.sh 新增 apple / apple-llm 模式,默认 apple-llm
- README + AGENTS.md 同步更新
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
|
2026-10-02 19:23:47 +08:00 |
|