@formthefog/stratus 2026.2.24 → 2026.3.19

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 (75) hide show
  1. package/.github/sentinel/action.yml +100 -0
  2. package/.github/sentinel/dist/codebase.d.ts +3 -0
  3. package/.github/sentinel/dist/codebase.d.ts.map +1 -0
  4. package/.github/sentinel/dist/context.d.ts +6 -0
  5. package/.github/sentinel/dist/context.d.ts.map +1 -0
  6. package/.github/sentinel/dist/fixer.d.ts +6 -0
  7. package/.github/sentinel/dist/fixer.d.ts.map +1 -0
  8. package/.github/sentinel/dist/index.d.ts +1 -0
  9. package/.github/sentinel/dist/index.d.ts.map +1 -0
  10. package/.github/sentinel/dist/index.js +68808 -0
  11. package/.github/sentinel/dist/index.js.map +1 -0
  12. package/.github/sentinel/dist/licenses.txt +1152 -0
  13. package/.github/sentinel/dist/models/anthropic.d.ts +26 -0
  14. package/.github/sentinel/dist/models/anthropic.d.ts.map +1 -0
  15. package/.github/sentinel/dist/models/openai.d.ts +26 -0
  16. package/.github/sentinel/dist/models/openai.d.ts.map +1 -0
  17. package/.github/sentinel/dist/models/openrouter.d.ts +31 -0
  18. package/.github/sentinel/dist/models/openrouter.d.ts.map +1 -0
  19. package/.github/sentinel/dist/models/types.d.ts +37 -0
  20. package/.github/sentinel/dist/models/types.d.ts.map +1 -0
  21. package/.github/sentinel/dist/orchestrator.d.ts +3 -0
  22. package/.github/sentinel/dist/orchestrator.d.ts.map +1 -0
  23. package/.github/sentinel/dist/policy.d.ts +15 -0
  24. package/.github/sentinel/dist/policy.d.ts.map +1 -0
  25. package/.github/sentinel/dist/reporter.d.ts +8 -0
  26. package/.github/sentinel/dist/reporter.d.ts.map +1 -0
  27. package/.github/sentinel/dist/responder.d.ts +6 -0
  28. package/.github/sentinel/dist/responder.d.ts.map +1 -0
  29. package/.github/sentinel/dist/router.d.ts +2 -0
  30. package/.github/sentinel/dist/router.d.ts.map +1 -0
  31. package/.github/sentinel/dist/schemas/config.d.ts +195 -0
  32. package/.github/sentinel/dist/schemas/config.d.ts.map +1 -0
  33. package/.github/sentinel/dist/schemas/fix.d.ts +130 -0
  34. package/.github/sentinel/dist/schemas/fix.d.ts.map +1 -0
  35. package/.github/sentinel/dist/schemas/review.d.ts +275 -0
  36. package/.github/sentinel/dist/schemas/review.d.ts.map +1 -0
  37. package/.github/sentinel/dist/sourcemap-register.js +1 -0
  38. package/.github/sentinel/dist/subway.d.ts +31 -0
  39. package/.github/sentinel/dist/subway.d.ts.map +1 -0
  40. package/.github/sentinel/dist/types.d.ts +210 -0
  41. package/.github/sentinel/dist/types.d.ts.map +1 -0
  42. package/.github/sentinel/package-lock.json +2389 -0
  43. package/.github/sentinel/package.json +29 -0
  44. package/.github/sentinel/src/codebase.ts +265 -0
  45. package/.github/sentinel/src/context.ts +182 -0
  46. package/.github/sentinel/src/fixer.ts +353 -0
  47. package/.github/sentinel/src/index.ts +263 -0
  48. package/.github/sentinel/src/models/anthropic.ts +244 -0
  49. package/.github/sentinel/src/models/openai.ts +242 -0
  50. package/.github/sentinel/src/models/openrouter.ts +319 -0
  51. package/.github/sentinel/src/models/types.ts +35 -0
  52. package/.github/sentinel/src/orchestrator.ts +287 -0
  53. package/.github/sentinel/src/policy.ts +133 -0
  54. package/.github/sentinel/src/reporter.ts +666 -0
  55. package/.github/sentinel/src/responder.ts +156 -0
  56. package/.github/sentinel/src/router.ts +308 -0
  57. package/.github/sentinel/src/schemas/config.ts +84 -0
  58. package/.github/sentinel/src/schemas/fix.ts +44 -0
  59. package/.github/sentinel/src/schemas/review.ts +73 -0
  60. package/.github/sentinel/src/subway.ts +250 -0
  61. package/.github/sentinel/src/types.ts +234 -0
  62. package/.github/sentinel/tsconfig.json +19 -0
  63. package/.github/sentinel.yml +34 -0
  64. package/.github/workflows/sentinel.yml +55 -0
  65. package/README.md +88 -102
  66. package/SECURITY.md +21 -10
  67. package/TROUBLESHOOTING.md +2 -2
  68. package/index.ts +219 -109
  69. package/openclaw.plugin.json +50 -26
  70. package/package.json +1 -1
  71. package/skills/stratus-info/SKILL.md +70 -10
  72. package/src/client.ts +78 -18
  73. package/src/config.ts +29 -8
  74. package/src/setup.ts +53 -61
  75. package/src/types.ts +11 -0
@@ -0,0 +1,26 @@
1
+ import type { ModelClient, ReviewRequest, CritiqueRequest, CritiqueResponseRequest } from "./types";
2
+ import type { ModelReview, CritiqueOutput, CritiqueResponse, TokenUsage } from "../types";
3
+ export declare class AnthropicClient implements ModelClient {
4
+ name: "anthropic";
5
+ private client;
6
+ private model;
7
+ constructor(apiKey: string, model: string);
8
+ review(req: ReviewRequest): Promise<{
9
+ review: ModelReview;
10
+ usage: TokenUsage;
11
+ }>;
12
+ critique(req: CritiqueRequest): Promise<{
13
+ critique: CritiqueOutput;
14
+ usage: TokenUsage;
15
+ }>;
16
+ respondToCritique(req: CritiqueResponseRequest): Promise<{
17
+ response: CritiqueResponse;
18
+ usage: TokenUsage;
19
+ }>;
20
+ chat(system: string, user: string): Promise<{
21
+ text: string;
22
+ usage: TokenUsage;
23
+ }>;
24
+ private call;
25
+ }
26
+ //# sourceMappingURL=anthropic.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"anthropic.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/models/anthropic.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,eAAe,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAA;AACnG,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,EAAiB,UAAU,EAAE,MAAM,UAAU,CAAA;AA4DxG,qBAAa,eAAgB,YAAW,WAAW;IACjD,IAAI,EAAG,WAAW,CAAS;IAC3B,OAAO,CAAC,MAAM,CAAW;IACzB,OAAO,CAAC,KAAK,CAAQ;gBAET,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;IAKnC,MAAM,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC;QAAE,MAAM,EAAE,WAAW,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAe/E,QAAQ,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,cAAc,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAqBxF,iBAAiB,CAAC,GAAG,EAAE,uBAAuB,GAAG,OAAO,CAAC;QAC7D,QAAQ,EAAE,gBAAgB,CAAA;QAC1B,KAAK,EAAE,UAAU,CAAA;KAClB,CAAC;IAoCI,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;YAIxE,IAAI;CAyCnB"}
@@ -0,0 +1,26 @@
1
+ import type { ModelClient, ReviewRequest, CritiqueRequest, CritiqueResponseRequest } from "./types";
2
+ import type { ModelReview, CritiqueOutput, CritiqueResponse, TokenUsage } from "../types";
3
+ export declare class OpenAIClient implements ModelClient {
4
+ name: "openai";
5
+ private client;
6
+ private model;
7
+ constructor(apiKey: string, model: string);
8
+ review(req: ReviewRequest): Promise<{
9
+ review: ModelReview;
10
+ usage: TokenUsage;
11
+ }>;
12
+ critique(req: CritiqueRequest): Promise<{
13
+ critique: CritiqueOutput;
14
+ usage: TokenUsage;
15
+ }>;
16
+ respondToCritique(req: CritiqueResponseRequest): Promise<{
17
+ response: CritiqueResponse;
18
+ usage: TokenUsage;
19
+ }>;
20
+ chat(system: string, user: string): Promise<{
21
+ text: string;
22
+ usage: import("../types").TokenUsage;
23
+ }>;
24
+ private call;
25
+ }
26
+ //# sourceMappingURL=openai.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"openai.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/models/openai.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,eAAe,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAA;AACnG,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,EAAiB,UAAU,EAAE,MAAM,UAAU,CAAA;AA2DxG,qBAAa,YAAa,YAAW,WAAW;IAC9C,IAAI,EAAG,QAAQ,CAAS;IACxB,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,KAAK,CAAQ;gBAET,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;IAKnC,MAAM,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC;QAAE,MAAM,EAAE,WAAW,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAe/E,QAAQ,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,cAAc,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAqBxF,iBAAiB,CAAC,GAAG,EAAE,uBAAuB,GAAG,OAAO,CAAC;QAC7D,QAAQ,EAAE,gBAAgB,CAAA;QAC1B,KAAK,EAAE,UAAU,CAAA;KAClB,CAAC;IAmCI,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,OAAO,UAAU,EAAE,UAAU,CAAA;KAAE,CAAC;YAI3F,IAAI;CAyCnB"}
@@ -0,0 +1,31 @@
1
+ import type { ModelClient, ReviewRequest, CritiqueRequest, CritiqueResponseRequest } from "./types";
2
+ import type { ModelReview, CritiqueOutput, CritiqueResponse, TokenUsage } from "../types";
3
+ type ClientRole = "anthropic" | "openai";
4
+ export declare class OpenRouterClient implements ModelClient {
5
+ name: ClientRole;
6
+ private client;
7
+ private model;
8
+ private role;
9
+ constructor(apiKey: string, model: string, role: ClientRole);
10
+ private get reviewSystem();
11
+ private get critiqueSystem();
12
+ review(req: ReviewRequest): Promise<{
13
+ review: ModelReview;
14
+ usage: TokenUsage;
15
+ }>;
16
+ critique(req: CritiqueRequest): Promise<{
17
+ critique: CritiqueOutput;
18
+ usage: TokenUsage;
19
+ }>;
20
+ respondToCritique(req: CritiqueResponseRequest): Promise<{
21
+ response: CritiqueResponse;
22
+ usage: TokenUsage;
23
+ }>;
24
+ chat(system: string, user: string): Promise<{
25
+ text: string;
26
+ usage: TokenUsage;
27
+ }>;
28
+ private call;
29
+ }
30
+ export {};
31
+ //# sourceMappingURL=openrouter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"openrouter.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/models/openrouter.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,aAAa,EAAE,eAAe,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAA;AACnG,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,EAAiB,UAAU,EAAE,MAAM,UAAU,CAAA;AAoHxG,KAAK,UAAU,GAAG,WAAW,GAAG,QAAQ,CAAA;AAExC,qBAAa,gBAAiB,YAAW,WAAW;IAClD,IAAI,EAAE,UAAU,CAAA;IAChB,OAAO,CAAC,MAAM,CAAQ;IACtB,OAAO,CAAC,KAAK,CAAQ;IACrB,OAAO,CAAC,IAAI,CAAY;gBAEZ,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU;IAc3D,OAAO,KAAK,YAAY,GAEvB;IAED,OAAO,KAAK,cAAc,GAEzB;IAEK,MAAM,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC;QAAE,MAAM,EAAE,WAAW,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAe/E,QAAQ,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,cAAc,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;IAqBxF,iBAAiB,CAAC,GAAG,EAAE,uBAAuB,GAAG,OAAO,CAAC;QAC7D,QAAQ,EAAE,gBAAgB,CAAA;QAC1B,KAAK,EAAE,UAAU,CAAA;KAClB,CAAC;IAmCI,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC;YAIxE,IAAI;CAyCnB"}
@@ -0,0 +1,37 @@
1
+ import type { ModelReview, CritiqueOutput, CritiqueResponse, ReviewContext, TokenUsage } from "../types";
2
+ export interface ReviewRequest {
3
+ context: ReviewContext;
4
+ systemPrompt: string;
5
+ userPrompt: string;
6
+ }
7
+ export interface CritiqueRequest {
8
+ context: ReviewContext;
9
+ otherModelReview: ModelReview;
10
+ systemPrompt: string;
11
+ }
12
+ export interface CritiqueResponseRequest {
13
+ context: ReviewContext;
14
+ critique: CritiqueOutput;
15
+ originalReview: ModelReview;
16
+ systemPrompt: string;
17
+ }
18
+ export interface ModelClient {
19
+ name: "anthropic" | "openai";
20
+ review(req: ReviewRequest): Promise<{
21
+ review: ModelReview;
22
+ usage: TokenUsage;
23
+ }>;
24
+ critique(req: CritiqueRequest): Promise<{
25
+ critique: CritiqueOutput;
26
+ usage: TokenUsage;
27
+ }>;
28
+ respondToCritique(req: CritiqueResponseRequest): Promise<{
29
+ response: CritiqueResponse;
30
+ usage: TokenUsage;
31
+ }>;
32
+ chat(system: string, user: string): Promise<{
33
+ text: string;
34
+ usage: TokenUsage;
35
+ }>;
36
+ }
37
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/models/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAExG,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,aAAa,CAAA;IACtB,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,MAAM,CAAA;CACnB;AAED,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,aAAa,CAAA;IACtB,gBAAgB,EAAE,WAAW,CAAA;IAC7B,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,MAAM,WAAW,uBAAuB;IACtC,OAAO,EAAE,aAAa,CAAA;IACtB,QAAQ,EAAE,cAAc,CAAA;IACxB,cAAc,EAAE,WAAW,CAAA;IAC3B,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,WAAW,GAAG,QAAQ,CAAA;IAE5B,MAAM,CAAC,GAAG,EAAE,aAAa,GAAG,OAAO,CAAC;QAAE,MAAM,EAAE,WAAW,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC,CAAA;IAE/E,QAAQ,CAAC,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC;QAAE,QAAQ,EAAE,cAAc,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC,CAAA;IAExF,iBAAiB,CAAC,GAAG,EAAE,uBAAuB,GAAG,OAAO,CAAC;QACvD,QAAQ,EAAE,gBAAgB,CAAA;QAC1B,KAAK,EAAE,UAAU,CAAA;KAClB,CAAC,CAAA;IAEF,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAE,CAAC,CAAA;CACjF"}
@@ -0,0 +1,3 @@
1
+ import type { ModelClient } from "./models/types";
2
+ import type { ReviewContext, FinalDecision } from "./types";
3
+ export declare function orchestrateReview(ctx: ReviewContext, anthropic: ModelClient | null, openai: ModelClient | null): Promise<FinalDecision>;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/orchestrator.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EACV,aAAa,EAGb,aAAa,EAKd,MAAM,SAAS,CAAA;AAShB,wBAAsB,iBAAiB,CACrC,GAAG,EAAE,aAAa,EAClB,SAAS,EAAE,WAAW,GAAG,IAAI,EAC7B,MAAM,EAAE,WAAW,GAAG,IAAI,GACzB,OAAO,CAAC,aAAa,CAAC,CAwIxB"}
@@ -0,0 +1,15 @@
1
+ import * as github from "@actions/github";
2
+ import type { RepoPolicies } from "./types";
3
+ type Octokit = ReturnType<typeof github.getOctokit>;
4
+ export declare function loadPolicies(octokit: Octokit, configPath: string, modeOverride?: string): Promise<RepoPolicies>;
5
+ export declare function evaluateTrust(ctx: {
6
+ actor: string;
7
+ isFork: boolean;
8
+ policies: RepoPolicies;
9
+ }): {
10
+ trusted: boolean;
11
+ canMutate: boolean;
12
+ reason: string;
13
+ };
14
+ export declare function isRestrictedPath(filePath: string, patterns: string[]): boolean;
15
+ export {};
@@ -0,0 +1 @@
1
+ {"version":3,"file":"","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/policy.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,MAAM,iBAAiB,CAAA;AAIzC,OAAO,KAAK,EAAE,YAAY,EAAwC,MAAM,SAAS,CAAA;AAEjF,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,MAAM,CAAC,UAAU,CAAC,CAAA;AAEnD,wBAAsB,YAAY,CAChC,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,MAAM,EAClB,YAAY,CAAC,EAAE,MAAM,GACpB,OAAO,CAAC,YAAY,CAAC,CA6CvB;AAED,wBAAgB,aAAa,CAAC,GAAG,EAAE;IACjC,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,OAAO,CAAA;IACf,QAAQ,EAAE,YAAY,CAAA;CACvB,GAAG;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,SAAS,EAAE,OAAO,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAU3D;AAED,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,GAAG,OAAO,CAK9E"}
@@ -0,0 +1,8 @@
1
+ import * as github from "@actions/github";
2
+ import type { FinalDecision, FixResult, FixMode } from "./types";
3
+ type Octokit = ReturnType<typeof github.getOctokit>;
4
+ export declare function reportReview(octokit: Octokit, decision: FinalDecision, prNumber: number, summaryOnClean?: boolean): Promise<void>;
5
+ export declare function reportIssueTriage(octokit: Octokit, issueNumber: number, classification: string, summary: string): Promise<void>;
6
+ export declare function reportFixResult(octokit: Octokit, issueNumber: number, result: FixResult, mode: FixMode): Promise<void>;
7
+ export declare function reportFailure(octokit: Octokit, prOrIssueNumber: number, error: string): Promise<void>;
8
+ export {};
@@ -0,0 +1 @@
1
+ {"version":3,"file":"","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/reporter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,MAAM,iBAAiB,CAAA;AACzC,OAAO,KAAK,EAAE,aAAa,EAA4D,SAAS,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AAE1H,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,MAAM,CAAC,UAAU,CAAC,CAAA;AAyCnD,wBAAsB,YAAY,CAChC,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,aAAa,EACvB,QAAQ,EAAE,MAAM,EAChB,cAAc,UAAQ,GACrB,OAAO,CAAC,IAAI,CAAC,CA2Bf;AAED,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,OAAO,EAChB,WAAW,EAAE,MAAM,EACnB,cAAc,EAAE,MAAM,EACtB,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,IAAI,CAAC,CAef;AAED,wBAAsB,eAAe,CACnC,OAAO,EAAE,OAAO,EAChB,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,SAAS,EACjB,IAAI,EAAE,OAAO,GACZ,OAAO,CAAC,IAAI,CAAC,CAmFf;AAED,wBAAsB,aAAa,CACjC,OAAO,EAAE,OAAO,EAChB,eAAe,EAAE,MAAM,EACvB,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,IAAI,CAAC,CAkBf"}
@@ -0,0 +1,6 @@
1
+ import * as github from "@actions/github";
2
+ import type { ModelClient } from "./models/types";
3
+ import type { ReviewContext, ResponseContext } from "./types";
4
+ type Octokit = ReturnType<typeof github.getOctokit>;
5
+ export declare function handleResponse(ctx: ReviewContext, responseContext: ResponseContext, model: ModelClient, octokit: Octokit): Promise<void>;
6
+ export {};
@@ -0,0 +1 @@
1
+ {"version":3,"file":"","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/responder.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,MAAM,iBAAiB,CAAA;AACzC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAE7D,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,MAAM,CAAC,UAAU,CAAC,CAAA;AAcnD,wBAAsB,cAAc,CAClC,GAAG,EAAE,aAAa,EAClB,eAAe,EAAE,eAAe,EAChC,KAAK,EAAE,WAAW,EAClB,OAAO,EAAE,OAAO,GACf,OAAO,CAAC,IAAI,CAAC,CA6Cf"}
@@ -0,0 +1,2 @@
1
+ import type { RoutedEvent, RepoPolicies } from "./types";
2
+ export declare function routeEvent(policies: RepoPolicies): RoutedEvent;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/router.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAuC,WAAW,EAAiB,YAAY,EAAmB,MAAM,SAAS,CAAA;AAM7H,wBAAgB,UAAU,CAAC,QAAQ,EAAE,YAAY,GAAG,WAAW,CAmD9D"}
@@ -0,0 +1,195 @@
1
+ import { z } from "zod";
2
+ export declare const SentinelConfigSchema: z.ZodObject<{
3
+ mode: z.ZodDefault<z.ZodEnum<["review", "review_and_suggest", "review_and_patch", "issue_triage", "issue_fix", "manual_only"]>>;
4
+ models: z.ZodDefault<z.ZodObject<{
5
+ anthropic: z.ZodDefault<z.ZodObject<{
6
+ enabled: z.ZodDefault<z.ZodBoolean>;
7
+ model: z.ZodDefault<z.ZodString>;
8
+ }, "strip", z.ZodTypeAny, {
9
+ enabled: boolean;
10
+ model: string;
11
+ }, {
12
+ enabled?: boolean | undefined;
13
+ model?: string | undefined;
14
+ }>>;
15
+ openai: z.ZodDefault<z.ZodObject<{
16
+ enabled: z.ZodDefault<z.ZodBoolean>;
17
+ model: z.ZodDefault<z.ZodString>;
18
+ }, "strip", z.ZodTypeAny, {
19
+ enabled: boolean;
20
+ model: string;
21
+ }, {
22
+ enabled?: boolean | undefined;
23
+ model?: string | undefined;
24
+ }>>;
25
+ }, "strip", z.ZodTypeAny, {
26
+ anthropic: {
27
+ enabled: boolean;
28
+ model: string;
29
+ };
30
+ openai: {
31
+ enabled: boolean;
32
+ model: string;
33
+ };
34
+ }, {
35
+ anthropic?: {
36
+ enabled?: boolean | undefined;
37
+ model?: string | undefined;
38
+ } | undefined;
39
+ openai?: {
40
+ enabled?: boolean | undefined;
41
+ model?: string | undefined;
42
+ } | undefined;
43
+ }>>;
44
+ trigger: z.ZodDefault<z.ZodObject<{
45
+ require_label: z.ZodDefault<z.ZodString>;
46
+ respond_to_mentions: z.ZodDefault<z.ZodBoolean>;
47
+ respond_to_replies: z.ZodDefault<z.ZodBoolean>;
48
+ bot_name: z.ZodDefault<z.ZodString>;
49
+ }, "strip", z.ZodTypeAny, {
50
+ require_label: string;
51
+ respond_to_mentions: boolean;
52
+ respond_to_replies: boolean;
53
+ bot_name: string;
54
+ }, {
55
+ require_label?: string | undefined;
56
+ respond_to_mentions?: boolean | undefined;
57
+ respond_to_replies?: boolean | undefined;
58
+ bot_name?: string | undefined;
59
+ }>>;
60
+ review: z.ZodDefault<z.ZodObject<{
61
+ max_files: z.ZodDefault<z.ZodNumber>;
62
+ max_patch_chars: z.ZodDefault<z.ZodNumber>;
63
+ comment_style: z.ZodDefault<z.ZodEnum<["concise", "comprehensive"]>>;
64
+ inline_comments: z.ZodDefault<z.ZodBoolean>;
65
+ severity_threshold: z.ZodDefault<z.ZodEnum<["low", "medium", "high", "critical"]>>;
66
+ summary_on_clean: z.ZodDefault<z.ZodBoolean>;
67
+ }, "strip", z.ZodTypeAny, {
68
+ max_files: number;
69
+ max_patch_chars: number;
70
+ comment_style: "concise" | "comprehensive";
71
+ inline_comments: boolean;
72
+ severity_threshold: "low" | "medium" | "high" | "critical";
73
+ summary_on_clean: boolean;
74
+ }, {
75
+ max_files?: number | undefined;
76
+ max_patch_chars?: number | undefined;
77
+ comment_style?: "concise" | "comprehensive" | undefined;
78
+ inline_comments?: boolean | undefined;
79
+ severity_threshold?: "low" | "medium" | "high" | "critical" | undefined;
80
+ summary_on_clean?: boolean | undefined;
81
+ }>>;
82
+ fix: z.ZodDefault<z.ZodObject<{
83
+ mode: z.ZodDefault<z.ZodEnum<["propose_only", "propose_and_pr", "yolo"]>>;
84
+ confidence_threshold: z.ZodDefault<z.ZodNumber>;
85
+ max_retry_count: z.ZodDefault<z.ZodNumber>;
86
+ create_draft_pr: z.ZodDefault<z.ZodBoolean>;
87
+ }, "strip", z.ZodTypeAny, {
88
+ mode: "propose_only" | "propose_and_pr" | "yolo";
89
+ confidence_threshold: number;
90
+ max_retry_count: number;
91
+ create_draft_pr: boolean;
92
+ }, {
93
+ mode?: "propose_only" | "propose_and_pr" | "yolo" | undefined;
94
+ confidence_threshold?: number | undefined;
95
+ max_retry_count?: number | undefined;
96
+ create_draft_pr?: boolean | undefined;
97
+ }>>;
98
+ security: z.ZodDefault<z.ZodObject<{
99
+ restricted_paths: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
100
+ block_fork_mutation: z.ZodDefault<z.ZodBoolean>;
101
+ }, "strip", z.ZodTypeAny, {
102
+ restricted_paths: string[];
103
+ block_fork_mutation: boolean;
104
+ }, {
105
+ restricted_paths?: string[] | undefined;
106
+ block_fork_mutation?: boolean | undefined;
107
+ }>>;
108
+ validation: z.ZodDefault<z.ZodObject<{
109
+ commands: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
110
+ }, "strip", z.ZodTypeAny, {
111
+ commands: string[];
112
+ }, {
113
+ commands?: string[] | undefined;
114
+ }>>;
115
+ }, "strip", z.ZodTypeAny, {
116
+ mode: "issue_triage" | "issue_fix" | "review" | "review_and_suggest" | "review_and_patch" | "manual_only";
117
+ fix: {
118
+ mode: "propose_only" | "propose_and_pr" | "yolo";
119
+ confidence_threshold: number;
120
+ max_retry_count: number;
121
+ create_draft_pr: boolean;
122
+ };
123
+ review: {
124
+ max_files: number;
125
+ max_patch_chars: number;
126
+ comment_style: "concise" | "comprehensive";
127
+ inline_comments: boolean;
128
+ severity_threshold: "low" | "medium" | "high" | "critical";
129
+ summary_on_clean: boolean;
130
+ };
131
+ validation: {
132
+ commands: string[];
133
+ };
134
+ models: {
135
+ anthropic: {
136
+ enabled: boolean;
137
+ model: string;
138
+ };
139
+ openai: {
140
+ enabled: boolean;
141
+ model: string;
142
+ };
143
+ };
144
+ trigger: {
145
+ require_label: string;
146
+ respond_to_mentions: boolean;
147
+ respond_to_replies: boolean;
148
+ bot_name: string;
149
+ };
150
+ security: {
151
+ restricted_paths: string[];
152
+ block_fork_mutation: boolean;
153
+ };
154
+ }, {
155
+ mode?: "issue_triage" | "issue_fix" | "review" | "review_and_suggest" | "review_and_patch" | "manual_only" | undefined;
156
+ fix?: {
157
+ mode?: "propose_only" | "propose_and_pr" | "yolo" | undefined;
158
+ confidence_threshold?: number | undefined;
159
+ max_retry_count?: number | undefined;
160
+ create_draft_pr?: boolean | undefined;
161
+ } | undefined;
162
+ review?: {
163
+ max_files?: number | undefined;
164
+ max_patch_chars?: number | undefined;
165
+ comment_style?: "concise" | "comprehensive" | undefined;
166
+ inline_comments?: boolean | undefined;
167
+ severity_threshold?: "low" | "medium" | "high" | "critical" | undefined;
168
+ summary_on_clean?: boolean | undefined;
169
+ } | undefined;
170
+ validation?: {
171
+ commands?: string[] | undefined;
172
+ } | undefined;
173
+ models?: {
174
+ anthropic?: {
175
+ enabled?: boolean | undefined;
176
+ model?: string | undefined;
177
+ } | undefined;
178
+ openai?: {
179
+ enabled?: boolean | undefined;
180
+ model?: string | undefined;
181
+ } | undefined;
182
+ } | undefined;
183
+ trigger?: {
184
+ require_label?: string | undefined;
185
+ respond_to_mentions?: boolean | undefined;
186
+ respond_to_replies?: boolean | undefined;
187
+ bot_name?: string | undefined;
188
+ } | undefined;
189
+ security?: {
190
+ restricted_paths?: string[] | undefined;
191
+ block_fork_mutation?: boolean | undefined;
192
+ } | undefined;
193
+ }>;
194
+ export type SentinelConfig = z.infer<typeof SentinelConfigSchema>;
195
+ //# sourceMappingURL=config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/schemas/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+E/B,CAAA;AAEF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAA"}
@@ -0,0 +1,130 @@
1
+ import { z } from "zod";
2
+ export declare const FileChangeSchema: z.ZodObject<{
3
+ path: z.ZodString;
4
+ action: z.ZodEnum<["modify", "create", "delete"]>;
5
+ changes: z.ZodOptional<z.ZodArray<z.ZodObject<{
6
+ search: z.ZodString;
7
+ replace: z.ZodString;
8
+ }, "strip", z.ZodTypeAny, {
9
+ replace: string;
10
+ search: string;
11
+ }, {
12
+ replace: string;
13
+ search: string;
14
+ }>, "many">>;
15
+ content: z.ZodOptional<z.ZodString>;
16
+ explanation: z.ZodString;
17
+ }, "strip", z.ZodTypeAny, {
18
+ path: string;
19
+ action: "modify" | "create" | "delete";
20
+ explanation: string;
21
+ content?: string | undefined;
22
+ changes?: {
23
+ replace: string;
24
+ search: string;
25
+ }[] | undefined;
26
+ }, {
27
+ path: string;
28
+ action: "modify" | "create" | "delete";
29
+ explanation: string;
30
+ content?: string | undefined;
31
+ changes?: {
32
+ replace: string;
33
+ search: string;
34
+ }[] | undefined;
35
+ }>;
36
+ export declare const FixPlanSchema: z.ZodObject<{
37
+ analysis: z.ZodString;
38
+ fixable: z.ZodBoolean;
39
+ confidence: z.ZodNumber;
40
+ files: z.ZodArray<z.ZodObject<{
41
+ path: z.ZodString;
42
+ action: z.ZodEnum<["modify", "create", "delete"]>;
43
+ changes: z.ZodOptional<z.ZodArray<z.ZodObject<{
44
+ search: z.ZodString;
45
+ replace: z.ZodString;
46
+ }, "strip", z.ZodTypeAny, {
47
+ replace: string;
48
+ search: string;
49
+ }, {
50
+ replace: string;
51
+ search: string;
52
+ }>, "many">>;
53
+ content: z.ZodOptional<z.ZodString>;
54
+ explanation: z.ZodString;
55
+ }, "strip", z.ZodTypeAny, {
56
+ path: string;
57
+ action: "modify" | "create" | "delete";
58
+ explanation: string;
59
+ content?: string | undefined;
60
+ changes?: {
61
+ replace: string;
62
+ search: string;
63
+ }[] | undefined;
64
+ }, {
65
+ path: string;
66
+ action: "modify" | "create" | "delete";
67
+ explanation: string;
68
+ content?: string | undefined;
69
+ changes?: {
70
+ replace: string;
71
+ search: string;
72
+ }[] | undefined;
73
+ }>, "many">;
74
+ commit_message: z.ZodString;
75
+ test_suggestions: z.ZodArray<z.ZodString, "many">;
76
+ risk_notes: z.ZodArray<z.ZodString, "many">;
77
+ }, "strip", z.ZodTypeAny, {
78
+ files: {
79
+ path: string;
80
+ action: "modify" | "create" | "delete";
81
+ explanation: string;
82
+ content?: string | undefined;
83
+ changes?: {
84
+ replace: string;
85
+ search: string;
86
+ }[] | undefined;
87
+ }[];
88
+ analysis: string;
89
+ fixable: boolean;
90
+ confidence: number;
91
+ commit_message: string;
92
+ test_suggestions: string[];
93
+ risk_notes: string[];
94
+ }, {
95
+ files: {
96
+ path: string;
97
+ action: "modify" | "create" | "delete";
98
+ explanation: string;
99
+ content?: string | undefined;
100
+ changes?: {
101
+ replace: string;
102
+ search: string;
103
+ }[] | undefined;
104
+ }[];
105
+ analysis: string;
106
+ fixable: boolean;
107
+ confidence: number;
108
+ commit_message: string;
109
+ test_suggestions: string[];
110
+ risk_notes: string[];
111
+ }>;
112
+ export declare const FixReviewSchema: z.ZodObject<{
113
+ approved: z.ZodBoolean;
114
+ confidence: z.ZodNumber;
115
+ concerns: z.ZodArray<z.ZodString, "many">;
116
+ verdict: z.ZodString;
117
+ }, "strip", z.ZodTypeAny, {
118
+ confidence: number;
119
+ approved: boolean;
120
+ concerns: string[];
121
+ verdict: string;
122
+ }, {
123
+ confidence: number;
124
+ approved: boolean;
125
+ concerns: string[];
126
+ verdict: string;
127
+ }>;
128
+ export declare function parseFixPlan(raw: string): z.infer<typeof FixPlanSchema>;
129
+ export declare function parseFixReview(raw: string): z.infer<typeof FixReviewSchema>;
130
+ //# sourceMappingURL=fix.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fix.d.ts","sourceRoot":"","sources":["file:///Users/andrewhathaway/code/goose/jfl/jfl-pr-sentinel/src/schemas/fix.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQ3B,CAAA;AAEF,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQxB,CAAA;AAEF,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;EAK1B,CAAA;AAEF,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAGvE;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAG3E"}