@posthog/agent 2.1.147 → 2.1.148
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent.js +2 -2
- package/dist/agent.js.map +1 -1
- package/dist/posthog-api.d.ts +1 -1
- package/dist/posthog-api.js +2 -2
- package/dist/posthog-api.js.map +1 -1
- package/dist/server/agent-server.js +3 -3
- package/dist/server/agent-server.js.map +1 -1
- package/dist/server/bin.cjs +3 -3
- package/dist/server/bin.cjs.map +1 -1
- package/package.json +3 -3
- package/src/server/agent-server.ts +1 -1
- package/src/utils/gateway.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@posthog/agent",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.148",
|
|
4
4
|
"repository": "https://github.com/PostHog/twig",
|
|
5
5
|
"description": "TypeScript agent framework wrapping Claude Agent SDK with Git-based task execution for PostHog",
|
|
6
6
|
"exports": {
|
|
@@ -74,8 +74,8 @@
|
|
|
74
74
|
"tsx": "^4.20.6",
|
|
75
75
|
"typescript": "^5.5.0",
|
|
76
76
|
"vitest": "^2.1.8",
|
|
77
|
-
"@
|
|
78
|
-
"@
|
|
77
|
+
"@posthog/shared": "1.0.0",
|
|
78
|
+
"@twig/git": "1.0.0"
|
|
79
79
|
},
|
|
80
80
|
"dependencies": {
|
|
81
81
|
"@agentclientprotocol/sdk": "^0.14.0",
|
|
@@ -754,7 +754,7 @@ Important:
|
|
|
754
754
|
private configureEnvironment(): void {
|
|
755
755
|
const { apiKey, apiUrl, projectId } = this.config;
|
|
756
756
|
const product =
|
|
757
|
-
this.config.mode === "background" ? "background_agents" : "
|
|
757
|
+
this.config.mode === "background" ? "background_agents" : "posthog_code";
|
|
758
758
|
const gatewayUrl =
|
|
759
759
|
process.env.LLM_GATEWAY_URL || getLlmGatewayUrl(apiUrl, product);
|
|
760
760
|
const openaiBaseUrl = gatewayUrl.endsWith("/v1")
|
package/src/utils/gateway.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export type GatewayProduct = "
|
|
1
|
+
export type GatewayProduct = "posthog_code" | "background_agents";
|
|
2
2
|
|
|
3
3
|
export function getLlmGatewayUrl(
|
|
4
4
|
posthogHost: string,
|
|
5
|
-
product: GatewayProduct = "
|
|
5
|
+
product: GatewayProduct = "posthog_code",
|
|
6
6
|
): string {
|
|
7
7
|
const url = new URL(posthogHost);
|
|
8
8
|
const hostname = url.hostname;
|