anpord 0.1.11 → 0.1.13

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.
Files changed (58) hide show
  1. package/README.md +56 -78
  2. package/dist/bin.cjs +211 -204
  3. package/dist/bin.mjs +211 -204
  4. package/dist/cli-runtime.cjs +2 -2
  5. package/dist/cli-runtime.d.cts +1 -1
  6. package/dist/cli-runtime.d.mts +1 -1
  7. package/dist/cli-runtime.mjs +2 -2
  8. package/dist/client-BfdjFtlV.mjs +305 -0
  9. package/dist/{client-C9m0uLCz.d.cts → client-BgRs8JvW.d.mts} +2150 -174
  10. package/dist/{client-TFCLuMv8.d.mts → client-BirFO3jz.d.cts} +2150 -174
  11. package/dist/client-C-P2I00z.cjs +346 -0
  12. package/dist/{compiler-DXlpU_In.mjs → compiler-D96wI7UP.mjs} +108 -75
  13. package/dist/{compiler-Ap8DM-JU.cjs → compiler-uwb1pkdK.cjs} +116 -83
  14. package/dist/config.cjs +1 -1
  15. package/dist/config.d.cts +1 -1
  16. package/dist/config.d.mts +1 -1
  17. package/dist/config.mjs +1 -1
  18. package/dist/{errors-C9bQUcA3.mjs → errors-B0YknR5V.mjs} +3 -19
  19. package/dist/{errors-Boum34f5.cjs → errors-BX1wry8K.cjs} +3 -19
  20. package/dist/{errors-BK3f7Rdr.d.cts → errors-aGrd21jy.d.cts} +0 -3
  21. package/dist/{errors-BK3f7Rdr.d.mts → errors-aGrd21jy.d.mts} +0 -3
  22. package/dist/eval-judges-BkmiVLLq.cjs +59 -0
  23. package/dist/eval-judges-CwTvTq7N.mjs +42 -0
  24. package/dist/eval-judges-DPPUftbh.d.cts +48 -0
  25. package/dist/eval-judges-DPPUftbh.d.mts +48 -0
  26. package/dist/eval-validations-BRdoZrTQ.mjs +113 -0
  27. package/dist/eval-validations-_MlnQ_uv.cjs +148 -0
  28. package/dist/eval.cjs +1 -1
  29. package/dist/eval.d.cts +60 -6
  30. package/dist/eval.d.mts +60 -6
  31. package/dist/eval.mjs +1 -1
  32. package/dist/evals-B6aT3xgH.d.cts +1364 -0
  33. package/dist/evals-B6aT3xgH.d.mts +1364 -0
  34. package/dist/evals-Dcc_x6jW.mjs +582 -0
  35. package/dist/evals-DouMsrsM.cjs +737 -0
  36. package/dist/index.cjs +23 -99
  37. package/dist/index.d.cts +138 -34
  38. package/dist/index.d.mts +138 -34
  39. package/dist/index.mjs +23 -99
  40. package/dist/source.d.cts +1 -1
  41. package/dist/source.d.mts +1 -1
  42. package/dist/{types-oaMF6-E1.d.mts → types-Codjaq-o.d.mts} +146 -45
  43. package/dist/{types-H9L450Iu.d.cts → types-ISsteq95.d.cts} +146 -45
  44. package/dist/validator-runtime.cjs +238 -0
  45. package/dist/validator-runtime.d.cts +9 -0
  46. package/dist/validator-runtime.d.mts +9 -0
  47. package/dist/validator-runtime.mjs +237 -0
  48. package/dist/validators.cjs +10 -0
  49. package/dist/validators.d.cts +8 -0
  50. package/dist/validators.d.mts +8 -0
  51. package/dist/validators.mjs +9 -0
  52. package/package.json +11 -1
  53. package/dist/client-5K3dMI5Q.mjs +0 -849
  54. package/dist/client-Ci0woWLW.cjs +0 -890
  55. package/dist/evals-BEgEmfiO.d.cts +0 -603
  56. package/dist/evals-BEgEmfiO.d.mts +0 -603
  57. package/dist/harness-profile-BMjsN460.mjs +0 -43
  58. package/dist/harness-profile-CDQpPLPd.cjs +0 -78
@@ -1,78 +0,0 @@
1
- let effect = require("effect");
2
- //#region ../schema/src/domain/harness-profile.ts
3
- const PROFILE_LIMITS = {
4
- fileChars: 96e3,
5
- files: 256,
6
- totalChars: 2e6
7
- };
8
- const ProfileName = effect.Schema.String.pipe(effect.Schema.pattern(/^[a-z0-9][a-z0-9-]{0,63}$/), effect.Schema.annotations({
9
- description: "Lowercase letters, digits and hyphens, at most 64 characters, starting with a letter or digit.",
10
- identifier: "ProfileName"
11
- }));
12
- const ProfilePath = effect.Schema.String.pipe(effect.Schema.pattern(/^(home|workspace)(?:\/(?!\.\.?(?:\/|$))[^/\0]+)+$/), effect.Schema.maxLength(512), effect.Schema.annotations({
13
- description: "A relative path under home/ or workspace/, without a .. segment.",
14
- identifier: "ProfilePath"
15
- }));
16
- const EnvName = effect.Schema.String.pipe(effect.Schema.pattern(/^[A-Z_][A-Z0-9_]*$/), effect.Schema.annotations({
17
- description: "An environment variable name.",
18
- identifier: "EnvName"
19
- }));
20
- const ProfileFiles = effect.Schema.Record({
21
- key: ProfilePath,
22
- value: effect.Schema.String.pipe(effect.Schema.maxLength(PROFILE_LIMITS.fileChars))
23
- }).pipe(effect.Schema.filter((files) => Object.keys(files).length <= PROFILE_LIMITS.files, { message: () => `A profile holds at most ${PROFILE_LIMITS.files} files.` }), effect.Schema.filter((files) => Object.values(files).reduce((sum, content) => sum + content.length, 0) <= PROFILE_LIMITS.totalChars, { message: () => `A profile's files hold at most ${PROFILE_LIMITS.totalChars} characters in total.` }));
24
- const HarnessProfile = effect.Schema.Struct({
25
- env: effect.Schema.optional(effect.Schema.Record({
26
- key: EnvName,
27
- value: effect.Schema.String
28
- })),
29
- files: ProfileFiles,
30
- install: effect.Schema.optional(effect.Schema.String),
31
- name: ProfileName,
32
- run: effect.Schema.optional(effect.Schema.String),
33
- systemPrompt: effect.Schema.optional(effect.Schema.String)
34
- }).annotations({
35
- description: "Configuration layered on a harness: files written under the sandbox home and workspace, a system prompt, environment, an install command run before the harness, and for the command harness the run command.",
36
- identifier: "HarnessProfile"
37
- });
38
- /** The one rule the wire schema cannot express in JSON Schema, so every tool
39
- * description repeats it. */
40
- const profileFitsHarness = (task) => task.harness === "command" ? task.profile?.run !== void 0 : task.profile?.run === void 0;
41
- const PROFILE_HARNESS_RULE = "The command harness needs a profile with a run command; other harnesses take no run. Any harness may take an install command.";
42
- //#endregion
43
- Object.defineProperty(exports, "EnvName", {
44
- enumerable: true,
45
- get: function() {
46
- return EnvName;
47
- }
48
- });
49
- Object.defineProperty(exports, "HarnessProfile", {
50
- enumerable: true,
51
- get: function() {
52
- return HarnessProfile;
53
- }
54
- });
55
- Object.defineProperty(exports, "PROFILE_HARNESS_RULE", {
56
- enumerable: true,
57
- get: function() {
58
- return PROFILE_HARNESS_RULE;
59
- }
60
- });
61
- Object.defineProperty(exports, "PROFILE_LIMITS", {
62
- enumerable: true,
63
- get: function() {
64
- return PROFILE_LIMITS;
65
- }
66
- });
67
- Object.defineProperty(exports, "ProfilePath", {
68
- enumerable: true,
69
- get: function() {
70
- return ProfilePath;
71
- }
72
- });
73
- Object.defineProperty(exports, "profileFitsHarness", {
74
- enumerable: true,
75
- get: function() {
76
- return profileFitsHarness;
77
- }
78
- });