@alpic-ai/tracks 0.17.1 → 0.18.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/dist/main.js +18 -4
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -475,7 +475,7 @@ const FailureKind = Schema.Literals([
|
|
|
475
475
|
"unexpected"
|
|
476
476
|
]).annotate({
|
|
477
477
|
identifier: "FailureKind",
|
|
478
|
-
description: "What kind of thing went wrong: the repository could not be checked out, the environment's setup command failed, the browser did not start, the sandbox disappeared, the agent's process was lost, the sandbox provider failed, the agent of a run
|
|
478
|
+
description: "What kind of thing went wrong: the repository could not be checked out, the environment's setup command failed, the browser did not start, the sandbox disappeared, the agent's process was lost, the sandbox provider failed, the agent stopped with an error on the last prompt of a one-shot run or of a run you ended, or something unexpected."
|
|
479
479
|
});
|
|
480
480
|
const runFields = {
|
|
481
481
|
id: RunId,
|
|
@@ -770,7 +770,7 @@ var RunsApi = class extends HttpApiGroup.make("runs").add(HttpApiEndpoint.post("
|
|
|
770
770
|
error: RunNotFound
|
|
771
771
|
}).annotateMerge(OpenApi.annotations({
|
|
772
772
|
summary: "End a run",
|
|
773
|
-
description: "Ends the run with `finished`
|
|
773
|
+
description: "Ends the run once its current prompt finishes, with `finished`, or `errored` if the agent stopped with an error on that prompt, then destroys its sandbox. Ending a run that has ended does nothing."
|
|
774
774
|
})), HttpApiEndpoint.post("cancel", "/runs/:id/cancel", {
|
|
775
775
|
params: { id: RunId },
|
|
776
776
|
success: Run.pipe(HttpApiSchema.status(202)),
|
|
@@ -916,6 +916,16 @@ const ExcludedVariant = Schema.Struct({
|
|
|
916
916
|
identifier: "ExcludedVariant",
|
|
917
917
|
description: "A combination of repository and agent tools not to run."
|
|
918
918
|
});
|
|
919
|
+
const Persona = Schema.Literals([
|
|
920
|
+
"none",
|
|
921
|
+
"default",
|
|
922
|
+
"developer",
|
|
923
|
+
"vibe_coder",
|
|
924
|
+
"product_manager"
|
|
925
|
+
]).annotate({
|
|
926
|
+
identifier: "Persona",
|
|
927
|
+
description: "Who answers the agent when it stops, up to 5 times a run, so each run is a conversation: `none` (no one, the agent gets the prompt alone), `default` (a plain user who tells it to go ahead), `developer` (a terse technical user who expects idiomatic, tested work), `vibe_coder` (a non-technical user happy with whatever works) or `product_manager` (a user focused on users and outcomes, who answers requirements and leaves technical choices to the agent). Its replies are written from the scenario's prompt, never from its evaluations, and are free. A conversation takes more time and money than one prompt: raise the time limit and budget. Defaults to `default` for a new experiment; omitted from an update, the experiment keeps its own."
|
|
928
|
+
});
|
|
919
929
|
const RunSettings = Schema.Struct({
|
|
920
930
|
repetitions: Schema.Int.check(Schema.isGreaterThanOrEqualTo(1)).annotate({ description: "Identical runs started for each scenario, variant and agent, to compare results beyond chance." }),
|
|
921
931
|
time_limit_seconds: Schema.Finite.check(Schema.isBetween({
|
|
@@ -928,6 +938,7 @@ const RunSettings = Schema.Struct({
|
|
|
928
938
|
exclusiveMinimum: true,
|
|
929
939
|
maximum: MAX_BUDGET_USD
|
|
930
940
|
})).annotate({ description: `Most each run may spend, in US dollars, above 0 and at most ${MAX_BUDGET_USD}.` }),
|
|
941
|
+
persona: Persona,
|
|
931
942
|
setup: script("Shell script run in each run's sandbox after checkout and before the prompt."),
|
|
932
943
|
teardown: script("Shell script run in each run's sandbox after the run ends."),
|
|
933
944
|
variables: Schema.Array(Schema.Struct({
|
|
@@ -959,7 +970,10 @@ const ScenarioInput = Scenario.mapFields(Struct.evolve({
|
|
|
959
970
|
input_files: (inputFiles) => inputFiles.pipe(Schema.withDecodingDefaultKey(Effect.succeed([]))),
|
|
960
971
|
evaluations: () => withUniqueIds(EvaluationInput, "evaluations")
|
|
961
972
|
})).annotate({ identifier: "ScenarioInput" });
|
|
962
|
-
const RunSettingsInput = RunSettings.mapFields(Struct.evolve({
|
|
973
|
+
const RunSettingsInput = RunSettings.mapFields(Struct.evolve({
|
|
974
|
+
persona: (persona) => Schema.optionalKey(persona),
|
|
975
|
+
variables: (variables) => variables.pipe(Schema.withDecodingDefaultKey(Effect.succeed([])))
|
|
976
|
+
})).annotate({ identifier: "RunSettingsInput" });
|
|
963
977
|
const unknownExclusions = (input) => input.excluded_variants.flatMap((excluded, index) => [...input.agent_tools.some((agentTools) => agentTools.id === excluded.agent_tools_id) ? [] : [{
|
|
964
978
|
path: [
|
|
965
979
|
"excluded_variants",
|
|
@@ -1362,7 +1376,7 @@ const isDatabaseVariable = (name) => DATABASE_ENV.some((databaseName) => databas
|
|
|
1362
1376
|
SERVICE_ENV.flatMap((name) => isSecret(name) && !isDatabaseVariable(name) ? [name] : []);
|
|
1363
1377
|
const readEnv = (...names) => Config.schema(Env.mapFields(Struct.pick(names)));
|
|
1364
1378
|
// package.json
|
|
1365
|
-
var version = "0.
|
|
1379
|
+
var version = "0.18.0";
|
|
1366
1380
|
// src/connections.ts
|
|
1367
1381
|
const encodeConnection = Schema.encodeEffect(Schema.fromJsonString(Connection, { space: 2 }));
|
|
1368
1382
|
const encodeConnections = Schema.encodeEffect(Schema.fromJsonString(List(Connection), { space: 2 }));
|