@salesforce/plugin-agent 1.9.2 → 1.11.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/README.md +151 -81
- package/lib/commands/agent/create-v2.js +10 -4
- package/lib/commands/agent/create-v2.js.map +1 -1
- package/lib/commands/agent/generate/spec-v2.js +1 -1
- package/lib/commands/agent/generate/spec-v2.js.map +1 -1
- package/lib/commands/agent/generate/{test-definition.d.ts → test-spec.d.ts} +1 -1
- package/lib/commands/agent/generate/{test-cases.js → test-spec.js} +50 -51
- package/lib/commands/agent/generate/test-spec.js.map +1 -0
- package/lib/commands/agent/test/create.d.ts +23 -0
- package/lib/commands/agent/test/create.js +95 -0
- package/lib/commands/agent/test/create.js.map +1 -0
- package/lib/commands/agent/test/list.d.ts +13 -0
- package/lib/commands/agent/test/list.js +36 -0
- package/lib/commands/agent/test/list.js.map +1 -0
- package/messages/agent.create-v2.md +17 -11
- package/messages/agent.generate.spec-v2.md +21 -13
- package/messages/agent.generate.test-spec.md +11 -0
- package/messages/agent.test.create.md +27 -0
- package/messages/agent.test.list.md +11 -0
- package/npm-shrinkwrap.json +210 -207
- package/oclif.lock +16 -14
- package/oclif.manifest.json +186 -69
- package/package.json +8 -4
- package/schemas/agent-test-create.json +19 -0
- package/schemas/agent-test-list.json +60 -0
- package/schemas/agent-test-results.json +14 -17
- package/lib/commands/agent/generate/test-cases.d.ts +0 -16
- package/lib/commands/agent/generate/test-cases.js.map +0 -1
- package/lib/commands/agent/generate/test-definition.js +0 -76
- package/lib/commands/agent/generate/test-definition.js.map +0 -1
- package/messages/agent.generate.test-cases.md +0 -11
- package/messages/agent.generate.test-definition.md +0 -13
package/README.md
CHANGED
|
@@ -65,10 +65,11 @@ sf plugins
|
|
|
65
65
|
- [`sf agent create-v2`](#sf-agent-create-v2)
|
|
66
66
|
- [`sf agent generate spec`](#sf-agent-generate-spec)
|
|
67
67
|
- [`sf agent generate spec-v2`](#sf-agent-generate-spec-v2)
|
|
68
|
-
- [`sf agent generate test-
|
|
69
|
-
- [`sf agent generate test-definition`](#sf-agent-generate-test-definition)
|
|
68
|
+
- [`sf agent generate test-spec`](#sf-agent-generate-test-spec)
|
|
70
69
|
- [`sf agent preview`](#sf-agent-preview)
|
|
71
70
|
- [`sf agent test cancel`](#sf-agent-test-cancel)
|
|
71
|
+
- [`sf agent test create`](#sf-agent-test-create)
|
|
72
|
+
- [`sf agent test list`](#sf-agent-test-list)
|
|
72
73
|
- [`sf agent test results`](#sf-agent-test-results)
|
|
73
74
|
- [`sf agent test resume`](#sf-agent-test-resume)
|
|
74
75
|
- [`sf agent test run`](#sf-agent-test-run)
|
|
@@ -113,11 +114,11 @@ EXAMPLES
|
|
|
113
114
|
$ sf agent create --name CustomerSupportAgent --spec ./config/agentSpec.json --target-org my-org
|
|
114
115
|
```
|
|
115
116
|
|
|
116
|
-
_See code: [src/commands/agent/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
117
|
+
_See code: [src/commands/agent/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/create.ts)_
|
|
117
118
|
|
|
118
119
|
## `sf agent create-v2`
|
|
119
120
|
|
|
120
|
-
Create an agent in your org
|
|
121
|
+
Create an agent in your org using a local agent spec file.
|
|
121
122
|
|
|
122
123
|
```
|
|
123
124
|
USAGE
|
|
@@ -128,43 +129,54 @@ USAGE
|
|
|
128
129
|
FLAGS
|
|
129
130
|
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
130
131
|
configuration variable is already set.
|
|
131
|
-
--agent-name=<value> Name
|
|
132
|
+
--agent-name=<value> Name (label) of the new agent.
|
|
132
133
|
--api-version=<value> Override the api version used for api requests made by this command
|
|
133
|
-
--enrich-logs=<option> Adds agent conversation data to event logs
|
|
134
|
+
--enrich-logs=<option> Adds agent conversation data to event logs so you can view all agent session activity in
|
|
135
|
+
one place.
|
|
134
136
|
<options: true|false>
|
|
135
137
|
--planner-id=<value> The GenAiPlanner ID to associate with the agent.
|
|
136
|
-
--preview Preview the agent without saving in your org.
|
|
138
|
+
--preview Preview the agent without saving it in your org.
|
|
137
139
|
--spec=<value> (required) Path to an agent spec file.
|
|
138
|
-
--tone=<option> Conversational style of agent
|
|
140
|
+
--tone=<option> Conversational style of the agent, such as how it expresses your brand personality in its
|
|
141
|
+
messages through word choice, punctuation, and sentence structure.
|
|
139
142
|
<options: formal|casual|neutral>
|
|
140
|
-
--user-id=<value>
|
|
143
|
+
--user-id=<value> ID of a user in your org that is assigned to your agent; determines what your agent can
|
|
144
|
+
access and do.
|
|
141
145
|
|
|
142
146
|
GLOBAL FLAGS
|
|
143
147
|
--flags-dir=<value> Import flag values from a directory.
|
|
144
148
|
--json Format output as json.
|
|
145
149
|
|
|
146
150
|
DESCRIPTION
|
|
147
|
-
Create an agent in your org
|
|
151
|
+
Create an agent in your org using a local agent spec file.
|
|
148
152
|
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
153
|
+
Before you run this command, you must first generate an agent spec file by running the "agent generate spec" CLI
|
|
154
|
+
command, which outputs a YAML file with the agent properties and list of AI-generated topics. Topics define the range
|
|
155
|
+
of jobs the agent can handle. Then specify the generated agent spec file to this command using the --spec flag, along
|
|
156
|
+
with the name (label) of the new agent using the --agent-name flag.
|
|
152
157
|
|
|
153
158
|
When this command finishes, your org contains the new agent, which you can then edit in the Agent Builder UI. The new
|
|
154
|
-
agent
|
|
155
|
-
|
|
159
|
+
agent's topics are the same as the ones listed in the agent spec file. The agent might also have some AI-generated
|
|
160
|
+
actions. This command also retrieves all the metadata files associated with the new agent to your local Salesforce DX
|
|
156
161
|
project.
|
|
157
162
|
|
|
163
|
+
Use the --preview flag to review what the agent looks like without actually saving it in your org. Rather, the command
|
|
164
|
+
creates a JSON file with all the agent details in the current directory.
|
|
165
|
+
|
|
158
166
|
To open the new agent in your org's Agent Builder UI, run this command: "sf org open agent --name
|
|
159
167
|
<api-name-of-your-agent>".
|
|
160
168
|
|
|
161
169
|
EXAMPLES
|
|
162
|
-
Create an agent called "
|
|
170
|
+
Create an agent called "ResortManager" in an org with alias "my-org" using the specified agent spec file:
|
|
171
|
+
|
|
172
|
+
$ sf agent create-v2 --agent-name ResortManager --spec specs/resortManagerAgent.yaml --target-org my-org
|
|
163
173
|
|
|
164
|
-
|
|
174
|
+
Preview the creation of an agent called "ResortManager" and use your default org:
|
|
175
|
+
|
|
176
|
+
$ sf agent create-v2 --agent-name ResortManager --spec specs/resortManagerAgent.yaml --preview
|
|
165
177
|
```
|
|
166
178
|
|
|
167
|
-
_See code: [src/commands/agent/create-v2.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
179
|
+
_See code: [src/commands/agent/create-v2.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/create-v2.ts)_
|
|
168
180
|
|
|
169
181
|
## `sf agent generate spec`
|
|
170
182
|
|
|
@@ -225,11 +237,11 @@ EXAMPLES
|
|
|
225
237
|
$ sf agent generate spec --output-dir specs --target-org my-org
|
|
226
238
|
```
|
|
227
239
|
|
|
228
|
-
_See code: [src/commands/agent/generate/spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
240
|
+
_See code: [src/commands/agent/generate/spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/generate/spec.ts)_
|
|
229
241
|
|
|
230
242
|
## `sf agent generate spec-v2`
|
|
231
243
|
|
|
232
|
-
Generate an agent spec, which is
|
|
244
|
+
Generate an agent spec, which is a YAML file that captures what an agent can do.
|
|
233
245
|
|
|
234
246
|
```
|
|
235
247
|
USAGE
|
|
@@ -246,98 +258,91 @@ FLAGS
|
|
|
246
258
|
--company-description=<value> Description of your company.
|
|
247
259
|
--company-name=<value> Name of your company.
|
|
248
260
|
--company-website=<value> Website URL of your company.
|
|
249
|
-
--grounding-context=<value> Context information
|
|
250
|
-
|
|
251
|
-
--
|
|
261
|
+
--grounding-context=<value> Context information and personalization that's added to your prompts when using a
|
|
262
|
+
custom prompt template.
|
|
263
|
+
--max-topics=<value> Maximum number of topics to generate in the agent spec; default is 10.
|
|
264
|
+
--output-file=<value> [default: config/agentSpec.yaml] Path for the generated YAML agent spec file; can
|
|
252
265
|
be an absolute or relative path.
|
|
253
|
-
--prompt-template=<value>
|
|
266
|
+
--prompt-template=<value> API name of a customized prompt template to use instead of the default prompt
|
|
267
|
+
template.
|
|
254
268
|
--role=<value> Role of the agent.
|
|
255
|
-
--spec=<value>
|
|
269
|
+
--spec=<value> Agent spec file, in YAML format, to use as input to the command.
|
|
256
270
|
|
|
257
271
|
GLOBAL FLAGS
|
|
258
272
|
--flags-dir=<value> Import flag values from a directory.
|
|
259
273
|
--json Format output as json.
|
|
260
274
|
|
|
261
275
|
DESCRIPTION
|
|
262
|
-
Generate an agent spec, which is
|
|
276
|
+
Generate an agent spec, which is a YAML file that captures what an agent can do.
|
|
263
277
|
|
|
264
|
-
|
|
265
|
-
|
|
278
|
+
Before you use Salesforce CLI to create an agent in your org, you must first generate an agent spec with this command.
|
|
279
|
+
An agent spec is a YAML-formatted file that contains information about the agent, such as its role and company
|
|
280
|
+
description, and then an AI-generated list of topics based on this information. Topics define the range of jobs your
|
|
281
|
+
agent can handle.
|
|
266
282
|
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
283
|
+
Use flags, such as --role and --company-description, to provide details about your company and the role that the agent
|
|
284
|
+
plays in your company. If you prefer, you can also be prompted for the information. Upon command execution, the large
|
|
285
|
+
language model (LLM) associated with your org uses the information you provided to generate a list of topics for the
|
|
286
|
+
agent. Because the LLM uses the company and role information to generate the topics, we recommend that you provide
|
|
287
|
+
accurate and specific details so the LLM generates the best and most relevant topics. Once generated, you can edit the
|
|
288
|
+
spec file; for example, you can remove topics that don't apply to your agent or change the description of a particular
|
|
289
|
+
topic.
|
|
274
290
|
|
|
275
|
-
|
|
276
|
-
--
|
|
291
|
+
You can iterate the spec generation process by using the --spec flag to pass an existing agent spec file to this
|
|
292
|
+
command, and then using the --role, --company-description, etc, flags to refine your agent properties. Iteratively
|
|
293
|
+
improving the description of your agent allows the LLM to generate progressively better topics.
|
|
277
294
|
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
company details:
|
|
281
|
-
|
|
282
|
-
$ sf agent generate spec-v2 --type customer --role "Assist users in navigating and managing bookings" \
|
|
283
|
-
--company-name "Coral Cloud" --company-description "Resort that manages guests and their reservations and \
|
|
284
|
-
experiences"
|
|
285
|
-
|
|
286
|
-
Create an agent spec by being prompted for role and company details interactively; write the generated file to the
|
|
287
|
-
"specs" directory and use the org with alias "my-org":
|
|
288
|
-
|
|
289
|
-
$ sf agent generate spec-v2 --output-dir specs --target-org my-org
|
|
290
|
-
```
|
|
291
|
-
|
|
292
|
-
_See code: [src/commands/agent/generate/spec-v2.ts](https://github.com/salesforcecli/plugin-agent/blob/1.9.2/src/commands/agent/generate/spec-v2.ts)_
|
|
295
|
+
You can also specify a custom prompt template that the agent uses, and ground the prompt template to add context and
|
|
296
|
+
personalization to the agent's prompts.
|
|
293
297
|
|
|
294
|
-
|
|
298
|
+
When your agent spec is ready, you then create the agent in your org by running the "agent create" CLI command and
|
|
299
|
+
specifying the spec with the --spec flag.
|
|
295
300
|
|
|
296
|
-
|
|
301
|
+
EXAMPLES
|
|
302
|
+
Generate an agent spec in the default location and use flags to specify the agent properties, such as its role and
|
|
303
|
+
your company details; use your default org:
|
|
297
304
|
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
305
|
+
$ sf agent generate spec-v2 --type customer --role "Field customer complaints and manage employee schedules." \
|
|
306
|
+
--company-name "Coral Cloud Resorts" --company-description "Provide customers with exceptional destination \
|
|
307
|
+
activities, unforgettable experiences, and reservation services."
|
|
301
308
|
|
|
302
|
-
|
|
303
|
-
|
|
309
|
+
Generate an agent spec by being prompted for the required agent properties and generate a maxiumum of 5 topics;
|
|
310
|
+
write the generated file to the "specs/resortManagerSpec.yaml" file and use the org with alias "my-org":
|
|
304
311
|
|
|
305
|
-
|
|
306
|
-
Interactively generate a new Set of AI Evaluation test cases.
|
|
312
|
+
$ sf agent generate spec-v2 --max-topics 5 --output-file specs/resortManagerAgent.yaml --target-org my-org
|
|
307
313
|
|
|
308
|
-
|
|
309
|
-
|
|
314
|
+
Specify an existing agent spec file called "specs/resortManagerAgent.yaml", and then overwrite it with a new version
|
|
315
|
+
that contains newly AI-generated topics based on the updated role information passed in with the --role flag:
|
|
310
316
|
|
|
311
|
-
|
|
312
|
-
|
|
317
|
+
$ sf agent generate spec-v2 --spec specs/resortManagerAgent.yaml --output-file specs/resortManagerAgent.yaml \
|
|
318
|
+
--role "Field customer complaints, manage employee schedules, and ensure all resort operations are running \
|
|
319
|
+
smoothly" --target-org my-org
|
|
313
320
|
```
|
|
314
321
|
|
|
315
|
-
_See code: [src/commands/agent/generate/
|
|
322
|
+
_See code: [src/commands/agent/generate/spec-v2.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/generate/spec-v2.ts)_
|
|
316
323
|
|
|
317
|
-
## `sf agent generate test-
|
|
324
|
+
## `sf agent generate test-spec`
|
|
318
325
|
|
|
319
|
-
Interactively generate a
|
|
326
|
+
Interactively generate a specification file for a AI evaluation test.
|
|
320
327
|
|
|
321
328
|
```
|
|
322
329
|
USAGE
|
|
323
|
-
$ sf agent generate test-
|
|
330
|
+
$ sf agent generate test-spec [--flags-dir <value>]
|
|
324
331
|
|
|
325
332
|
GLOBAL FLAGS
|
|
326
333
|
--flags-dir=<value> Import flag values from a directory.
|
|
327
334
|
|
|
328
335
|
DESCRIPTION
|
|
329
|
-
Interactively generate a
|
|
330
|
-
|
|
331
|
-
This command will prompt you for the necessary information to create a new AiEvaluationDefinition. The definition will
|
|
332
|
-
be saved to the `aiEvaluationDefinitions` directory in the project.
|
|
336
|
+
Interactively generate a specification file for a AI evaluation test.
|
|
333
337
|
|
|
334
|
-
|
|
338
|
+
This command will prompt you for the necessary information to create a new spec file (in yaml format). You can then
|
|
339
|
+
create a new AI evaluation using "sf agent test create --spec <spec-file>".
|
|
335
340
|
|
|
336
341
|
EXAMPLES
|
|
337
|
-
$ sf agent generate test-
|
|
342
|
+
$ sf agent generate test-spec
|
|
338
343
|
```
|
|
339
344
|
|
|
340
|
-
_See code: [src/commands/agent/generate/test-
|
|
345
|
+
_See code: [src/commands/agent/generate/test-spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/generate/test-spec.ts)_
|
|
341
346
|
|
|
342
347
|
## `sf agent preview`
|
|
343
348
|
|
|
@@ -372,7 +377,7 @@ FLAG DESCRIPTIONS
|
|
|
372
377
|
the API name of the agent? (TBD based on agents library)
|
|
373
378
|
```
|
|
374
379
|
|
|
375
|
-
_See code: [src/commands/agent/preview.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
380
|
+
_See code: [src/commands/agent/preview.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/preview.ts)_
|
|
376
381
|
|
|
377
382
|
## `sf agent test cancel`
|
|
378
383
|
|
|
@@ -409,7 +414,72 @@ EXAMPLES
|
|
|
409
414
|
$ sf agent test cancel --job-id 4KBfake0000003F4AQ --target-org my-org
|
|
410
415
|
```
|
|
411
416
|
|
|
412
|
-
_See code: [src/commands/agent/test/cancel.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
417
|
+
_See code: [src/commands/agent/test/cancel.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/cancel.ts)_
|
|
418
|
+
|
|
419
|
+
## `sf agent test create`
|
|
420
|
+
|
|
421
|
+
Summary of a command.
|
|
422
|
+
|
|
423
|
+
```
|
|
424
|
+
USAGE
|
|
425
|
+
$ sf agent test create -s <value> -o <value> [--json] [--flags-dir <value>] [--api-version <value>] [--preview] [-p]
|
|
426
|
+
|
|
427
|
+
FLAGS
|
|
428
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
429
|
+
configuration variable is already set.
|
|
430
|
+
-p, --no-prompt Don't prompt for confirmation when overwriting an existing test.
|
|
431
|
+
-s, --spec=<value> (required) Description of a flag.
|
|
432
|
+
--api-version=<value> Override the api version used for api requests made by this command
|
|
433
|
+
--preview Preview the test metadata without deploying to your org.
|
|
434
|
+
|
|
435
|
+
GLOBAL FLAGS
|
|
436
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
437
|
+
--json Format output as json.
|
|
438
|
+
|
|
439
|
+
DESCRIPTION
|
|
440
|
+
Summary of a command.
|
|
441
|
+
|
|
442
|
+
More information about a command. Don't repeat the summary.
|
|
443
|
+
|
|
444
|
+
EXAMPLES
|
|
445
|
+
$ sf agent test create
|
|
446
|
+
|
|
447
|
+
FLAG DESCRIPTIONS
|
|
448
|
+
-s, --spec=<value> Description of a flag.
|
|
449
|
+
|
|
450
|
+
More information about a flag. Don't repeat the summary.
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
_See code: [src/commands/agent/test/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/create.ts)_
|
|
454
|
+
|
|
455
|
+
## `sf agent test list`
|
|
456
|
+
|
|
457
|
+
List the available tests in the org.
|
|
458
|
+
|
|
459
|
+
```
|
|
460
|
+
USAGE
|
|
461
|
+
$ sf agent test list -o <value> [--json] [--flags-dir <value>] [--api-version <value>]
|
|
462
|
+
|
|
463
|
+
FLAGS
|
|
464
|
+
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
465
|
+
configuration variable is already set.
|
|
466
|
+
--api-version=<value> Override the api version used for api requests made by this command
|
|
467
|
+
|
|
468
|
+
GLOBAL FLAGS
|
|
469
|
+
--flags-dir=<value> Import flag values from a directory.
|
|
470
|
+
--json Format output as json.
|
|
471
|
+
|
|
472
|
+
DESCRIPTION
|
|
473
|
+
List the available tests in the org.
|
|
474
|
+
|
|
475
|
+
Run this command to get a list of tests that are available in the org. This command will return the test ID, name, and
|
|
476
|
+
created date of each test.
|
|
477
|
+
|
|
478
|
+
EXAMPLES
|
|
479
|
+
$ sf agent test list
|
|
480
|
+
```
|
|
481
|
+
|
|
482
|
+
_See code: [src/commands/agent/test/list.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/list.ts)_
|
|
413
483
|
|
|
414
484
|
## `sf agent test results`
|
|
415
485
|
|
|
@@ -465,7 +535,7 @@ FLAG DESCRIPTIONS
|
|
|
465
535
|
test results aren't written.
|
|
466
536
|
```
|
|
467
537
|
|
|
468
|
-
_See code: [src/commands/agent/test/results.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
538
|
+
_See code: [src/commands/agent/test/results.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/results.ts)_
|
|
469
539
|
|
|
470
540
|
## `sf agent test resume`
|
|
471
541
|
|
|
@@ -528,7 +598,7 @@ FLAG DESCRIPTIONS
|
|
|
528
598
|
test results aren't written.
|
|
529
599
|
```
|
|
530
600
|
|
|
531
|
-
_See code: [src/commands/agent/test/resume.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
601
|
+
_See code: [src/commands/agent/test/resume.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/resume.ts)_
|
|
532
602
|
|
|
533
603
|
## `sf agent test run`
|
|
534
604
|
|
|
@@ -591,6 +661,6 @@ FLAG DESCRIPTIONS
|
|
|
591
661
|
test results aren't written.
|
|
592
662
|
```
|
|
593
663
|
|
|
594
|
-
_See code: [src/commands/agent/test/run.ts](https://github.com/salesforcecli/plugin-agent/blob/1.
|
|
664
|
+
_See code: [src/commands/agent/test/run.ts](https://github.com/salesforcecli/plugin-agent/blob/1.11.0/src/commands/agent/test/run.ts)_
|
|
595
665
|
|
|
596
666
|
<!-- commandsstop -->
|
|
@@ -39,7 +39,7 @@ const FLAGGABLE_PROMPTS = {
|
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
return 'Please enter a valid User ID (005 prefix)';
|
|
42
|
-
}
|
|
42
|
+
},
|
|
43
43
|
},
|
|
44
44
|
'enrich-logs': {
|
|
45
45
|
message: messages.getMessage('flags.enrich-logs.summary'),
|
|
@@ -146,7 +146,7 @@ export default class AgentCreateV2 extends SfCommand {
|
|
|
146
146
|
companyName: inputSpec.companyName,
|
|
147
147
|
companyDescription: inputSpec.companyDescription,
|
|
148
148
|
preDefinedTopics: inputSpec.topics,
|
|
149
|
-
}
|
|
149
|
+
},
|
|
150
150
|
},
|
|
151
151
|
generationSettings: {},
|
|
152
152
|
};
|
|
@@ -192,8 +192,14 @@ export default class AgentCreateV2 extends SfCommand {
|
|
|
192
192
|
// The spec must define: agentType, role, companyName, companyDescription, and topics.
|
|
193
193
|
// Agent type must be 'customer' or 'internal'.
|
|
194
194
|
const validateSpec = (spec) => {
|
|
195
|
-
const requiredSpecValues = [
|
|
196
|
-
|
|
195
|
+
const requiredSpecValues = [
|
|
196
|
+
'agentType',
|
|
197
|
+
'role',
|
|
198
|
+
'companyName',
|
|
199
|
+
'companyDescription',
|
|
200
|
+
'topics',
|
|
201
|
+
];
|
|
202
|
+
const missingFlags = requiredSpecValues.filter((f) => !spec[f]);
|
|
197
203
|
if (missingFlags.length) {
|
|
198
204
|
throw messages.createError('error.missingRequiredFlags', [missingFlags.join(', ')]);
|
|
199
205
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-v2.js","sourceRoot":"","sources":["../../../src/commands/agent/create-v2.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACtD,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;A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AM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;IAChE,IAAI,YAAY,CAAC,MAAM,EAAE,CAAC;QACxB,MAAM,QAAQ,CAAC,WAAW,CAAC,4BAA4B,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACtF,CAAC;IAED,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;AAC1C,CAAC,CAAC"}
|
|
@@ -10,7 +10,7 @@ import { SfCommand, Flags } from '@salesforce/sf-plugins-core';
|
|
|
10
10
|
import { Messages } from '@salesforce/core';
|
|
11
11
|
import YAML from 'yaml';
|
|
12
12
|
import { Agent } from '@salesforce/agents';
|
|
13
|
-
import { FLAGGABLE_SPEC_PROMPTS, makeFlags, promptForFlag, validateAgentType, validateMaxTopics } from '../../../flags.js';
|
|
13
|
+
import { FLAGGABLE_SPEC_PROMPTS, makeFlags, promptForFlag, validateAgentType, validateMaxTopics, } from '../../../flags.js';
|
|
14
14
|
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
15
15
|
const messages = Messages.loadMessages('@salesforce/plugin-agent', 'agent.generate.spec-v2');
|
|
16
16
|
export default class AgentCreateSpecV2 extends SfCommand {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spec-v2.js","sourceRoot":"","sources":["../../../../src/commands/agent/generate/spec-v2.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACjE,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,IAAI,MAAM,M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AC,KAAK,CAAC,aAAa,CAAC,EAAE,SAAS,CAAC,CAAC;QAEtE,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,CAAC;QAEpB,IAAI,CAAC,GAAG,CAAC,uBAAuB,cAAc,EAAE,CAAC,CAAC;QAElD,OAAO,EAAE,GAAG,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,cAAc,EAAE,EAAE,GAAG,SAAS,EAAE,CAAC;IAC5E,CAAC;;AAGH,MAAM,aAAa,GAAG,CAAC,UAAkB,EAAE,SAAyB,EAAU,EAAE;IAC9E,8CAA8C;IAC9C,MAAM,cAAc,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAC3C,SAAS,CAAC,OAAO,CAAC,cAAc,CAAC,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IAExD,gDAAgD;IAChD,aAAa,CAAC,cAAc,EAAE,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,CAAC;IAEzD,OAAO,cAAc,CAAC;AACxB,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
2
|
-
export default class
|
|
2
|
+
export default class AgentGenerateTestSpec extends SfCommand<void> {
|
|
3
3
|
static readonly summary: string;
|
|
4
4
|
static readonly description: string;
|
|
5
5
|
static readonly examples: string[];
|