Skip to content

Commit e6c7788

Browse files
committed
Chat plugin
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
1 parent 08efcc9 commit e6c7788

26 files changed

+2815
-3
lines changed

integrations/appkit-agent/package.json

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,16 @@
1616
"types": "./dist/index.d.cts",
1717
"default": "./dist/index.cjs"
1818
}
19+
},
20+
"./chat": {
21+
"import": {
22+
"types": "./dist/chat/index.d.mts",
23+
"default": "./dist/chat/index.mjs"
24+
},
25+
"require": {
26+
"types": "./dist/chat/index.d.cts",
27+
"default": "./dist/chat/index.cjs"
28+
}
1929
}
2030
},
2131
"files": [
@@ -36,15 +46,16 @@
3646
"format:check": "prettier --check 'src/**/*.ts'"
3747
},
3848
"engines": {
39-
"node": ">=18.0.0"
49+
"node": ">=20.0.0"
4050
},
4151
"peerDependencies": {
4252
"@databricks/appkit": ">=0.21.0",
4353
"@databricks/langchainjs": ">=0.1.0",
4454
"@langchain/core": ">=1.0.0",
4555
"@langchain/langgraph": ">=1.0.0",
4656
"@langchain/mcp-adapters": ">=1.0.0",
47-
"express": ">=4.0.0"
57+
"express": ">=4.0.0",
58+
"pg": ">=8.0.0"
4859
},
4960
"peerDependenciesMeta": {
5061
"@databricks/langchainjs": {
@@ -58,16 +69,23 @@
5869
},
5970
"@langchain/mcp-adapters": {
6071
"optional": true
72+
},
73+
"pg": {
74+
"optional": true
6175
}
6276
},
6377
"dependencies": {
78+
"@databricks/ai-sdk-provider": "^0.5.1",
79+
"ai": "^6.0.70",
80+
"drizzle-orm": "^0.38.0",
6481
"zod": "^4.3.5"
6582
},
6683
"devDependencies": {
6784
"@databricks/appkit": "^0.21.0",
6885
"@langchain/core": "^1.1.8",
6986
"@types/express": "^4.17.25",
7087
"@types/node": "^22.0.0",
88+
"@types/pg": "^8.16.0",
7189
"prettier": "^3.0.0",
7290
"tsdown": "^0.9.0",
7391
"typescript": "^5.4.0",

integrations/appkit-agent/pnpm-lock.yaml

Lines changed: 136 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

integrations/appkit-agent/src/agent-plugin/agent.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,7 @@ export class AgentPlugin extends Plugin<IAgentConfig> {
217217
injectRoutes(router: express.Router) {
218218
const handler = createInvokeHandler(() => this.getAgentImpl());
219219
router.post("/", handler);
220+
router.post("/responses", handler);
220221
this.registerEndpoint("invoke", `/api/${this.name}`);
221222
}
222223

@@ -233,6 +234,8 @@ export class AgentPlugin extends Plugin<IAgentConfig> {
233234

234235
exports() {
235236
return {
237+
endpointPath: `/api/${this.name}`,
238+
236239
invoke: async (
237240
messages: { role: string; content: string }[],
238241
): Promise<string> => {

0 commit comments

Comments
 (0)