Files
prompt-optimizer/packages/core/package.json
T
linshen 4967164ded feat(core): 升级Anthropic适配器使用官方SDK
主要变更:
- 添加@anthropic-ai/sdk依赖
- 重构AnthropicAdapter使用官方SDK替代自定义HTTP实现
- 支持真正的SSE流式响应(不再是模拟)
- 支持Extended Thinking功能
- 支持工具调用的流式响应
- 优化错误处理和连接配置
- 移除不再需要的timeout参数(SDK内部处理)
- 删除service.ts.backup.txt备份文件
2025-10-09 00:22:37 +08:00

44 lines
1.1 KiB
JSON

{
"name": "@prompt-optimizer/core",
"version": "0.0.0",
"private": true,
"type": "module",
"main": "./dist/index.js",
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.js",
"require": "./dist/index.cjs"
}
},
"scripts": {
"build": "tsup src/index.ts --format cjs,esm --dts",
"dev": "tsup src/index.ts --format cjs,esm --dts --watch",
"test": "vitest run",
"test:watch": "vitest",
"test:coverage": "vitest run --coverage",
"test:unit": "vitest run tests/unit",
"test:integration": "vitest run tests/integration"
},
"devDependencies": {
"@types/node": "^20.11.0",
"dotenv": "^16.4.7",
"tsup": "^8.0.2",
"typescript": "^5.3.3",
"vitest": "^3.0.2"
},
"dependencies": {
"@anthropic-ai/sdk": "^0.65.0",
"@google/genai": "^1.0.0",
"@types/mustache": "^4.2.5",
"dexie": "^4.0.11",
"diff": "^8.0.2",
"mustache": "^4.2.0",
"openai": "^4.83.0",
"uuid": "^11.0.5",
"zod": "^3.22.4"
}
}