rapida-partner 6.1.0 → 7.0.0
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/package.json
CHANGED
|
@@ -62,21 +62,21 @@ export interface IAiAgentConfig {
|
|
|
62
62
|
};
|
|
63
63
|
|
|
64
64
|
businessContext: {
|
|
65
|
-
//
|
|
66
|
-
//
|
|
67
|
-
//
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
//
|
|
71
|
-
//
|
|
72
|
-
//
|
|
73
|
-
//
|
|
74
|
-
//
|
|
75
|
-
// project
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
65
|
+
// Backend in ANOTHER Rapida project (e.g. a separate ERP). Without it the
|
|
66
|
+
// agent talks to this project's own backend (backend[] and modules).
|
|
67
|
+
// With it, the agent calls only the target backend:
|
|
68
|
+
// - definitionFile: ALREADY COMPILED rapidaObject.json of the target
|
|
69
|
+
// project (not the .ts source), relative to the directory of this
|
|
70
|
+
// agent's rapidaObject.json. Contracts, fixed-tool endpoints and the
|
|
71
|
+
// history endpoint are resolved against it only.
|
|
72
|
+
// - baseUrl: the target backend URL (with or without /api/v1), written to
|
|
73
|
+
// BOT_API_BASE_URL.
|
|
74
|
+
// The bot user (botCredentials) must exist on the target backend: this
|
|
75
|
+
// project's own backend does not create it when targetBackend is set.
|
|
76
|
+
targetBackend?: {
|
|
77
|
+
definitionFile: string;
|
|
78
|
+
baseUrl: string;
|
|
79
|
+
};
|
|
80
80
|
|
|
81
81
|
// exposedContracts only covers *additional* domain actions. The agent
|
|
82
82
|
// ships fixed tools according to `capabilities` (identity → /people,
|
|
@@ -95,7 +95,7 @@ export interface IAiAgentConfig {
|
|
|
95
95
|
//
|
|
96
96
|
// Besides the fixed tools, the agent itself stores and reads the
|
|
97
97
|
// conversation history at /whatsapp-chat-histories: some module of the
|
|
98
|
-
// project (or of
|
|
98
|
+
// project (or of targetBackend) must expose that endpoint —
|
|
99
99
|
// usually whatsappModule from rapida-projects. Code generation fails
|
|
100
100
|
// without it.
|
|
101
101
|
//
|
|
@@ -31,6 +31,8 @@ export interface IProject {
|
|
|
31
31
|
// "referralCommerce": vitrine sem venda própria; cada produto leva por link de
|
|
32
32
|
// afiliado para o anúncio na fonte de origem (IBackend.referralSources), com
|
|
33
33
|
// a curadoria de IProject.referralCuration. Requer suporte no gerador.
|
|
34
|
+
// "aiAgent": sinônimo de "backoffice" (mesmo painel). O agente de IA não
|
|
35
|
+
// depende do skeleton: é gerado sempre que aiAgentConfig existe.
|
|
34
36
|
skeleton:
|
|
35
37
|
| "backoffice"
|
|
36
38
|
| "ecommerce"
|
|
@@ -96,6 +98,9 @@ export interface IProject {
|
|
|
96
98
|
styles?: IStyle[];
|
|
97
99
|
flowChart?: IFlowChart;
|
|
98
100
|
dashboard?: IComponent[];
|
|
101
|
+
// Agente de IA (Kunlatalk) do projeto. Com ele, o gerador cria o agente em
|
|
102
|
+
// qualquer skeleton (ex.: um backoffice ou uma loja com atendente), além do
|
|
103
|
+
// frontend e do backend.
|
|
99
104
|
aiAgentConfig?: IAiAgentConfig;
|
|
100
105
|
notifications?: INotification[];
|
|
101
106
|
repositories?: IProjectRepositories;
|
|
@@ -55,12 +55,15 @@
|
|
|
55
55
|
"businessContext": {
|
|
56
56
|
"type": "object",
|
|
57
57
|
"properties": {
|
|
58
|
-
"
|
|
59
|
-
"type": "
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
58
|
+
"targetBackend": {
|
|
59
|
+
"type": "object",
|
|
60
|
+
"description": "Backend in another Rapida project: compiled rapidaObject.json (relative to this agent's rapidaObject.json) and its URL.",
|
|
61
|
+
"properties": {
|
|
62
|
+
"definitionFile": { "type": "string", "minLength": 1 },
|
|
63
|
+
"baseUrl": { "type": "string", "minLength": 1 }
|
|
64
|
+
},
|
|
65
|
+
"required": ["definitionFile", "baseUrl"],
|
|
66
|
+
"additionalProperties": false
|
|
64
67
|
},
|
|
65
68
|
"exposedContracts": {
|
|
66
69
|
"type": "array",
|