@highflame/policy 1.2.0 → 2.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.
Files changed (74) hide show
  1. package/README.md +219 -0
  2. package/_schemas/overwatch/context.json +463 -0
  3. package/_schemas/overwatch/schema.cedarschema +184 -0
  4. package/_schemas/palisade/context.json +325 -0
  5. package/_schemas/palisade/schema.cedarschema +168 -0
  6. package/dist/builder.d.ts +1 -2
  7. package/dist/builder.d.ts.map +1 -1
  8. package/dist/builder.js.map +1 -1
  9. package/dist/context.gen.d.ts +1 -94
  10. package/dist/context.gen.d.ts.map +1 -1
  11. package/dist/context.gen.js +1 -97
  12. package/dist/context.gen.js.map +1 -1
  13. package/dist/engine.d.ts +18 -18
  14. package/dist/engine.d.ts.map +1 -1
  15. package/dist/engine.js +44 -28
  16. package/dist/engine.js.map +1 -1
  17. package/dist/engine.test.js.map +1 -1
  18. package/dist/entities.gen.d.ts +1 -0
  19. package/dist/entities.gen.d.ts.map +1 -1
  20. package/dist/entities.gen.js +1 -0
  21. package/dist/entities.gen.js.map +1 -1
  22. package/dist/errors.d.ts +102 -0
  23. package/dist/errors.d.ts.map +1 -0
  24. package/dist/errors.js +127 -0
  25. package/dist/errors.js.map +1 -0
  26. package/dist/index.d.ts +2 -0
  27. package/dist/index.d.ts.map +1 -1
  28. package/dist/index.js +2 -0
  29. package/dist/index.js.map +1 -1
  30. package/dist/overwatch-context.gen.d.ts +31 -0
  31. package/dist/overwatch-context.gen.d.ts.map +1 -0
  32. package/dist/overwatch-context.gen.js +32 -0
  33. package/dist/overwatch-context.gen.js.map +1 -0
  34. package/dist/palisade-context.gen.d.ts +25 -0
  35. package/dist/palisade-context.gen.d.ts.map +1 -0
  36. package/dist/palisade-context.gen.js +26 -0
  37. package/dist/palisade-context.gen.js.map +1 -0
  38. package/dist/parser.d.ts.map +1 -1
  39. package/dist/parser.js +79 -34
  40. package/dist/parser.js.map +1 -1
  41. package/dist/parser.test.js +44 -0
  42. package/dist/parser.test.js.map +1 -1
  43. package/dist/schema.gen.d.ts +1 -1
  44. package/dist/schema.gen.d.ts.map +1 -1
  45. package/dist/schema.gen.js +60 -541
  46. package/dist/schema.gen.js.map +1 -1
  47. package/dist/schemas.d.ts +64 -0
  48. package/dist/schemas.d.ts.map +1 -0
  49. package/dist/schemas.js +70 -0
  50. package/dist/schemas.js.map +1 -0
  51. package/dist/schemas.test.d.ts +8 -0
  52. package/dist/schemas.test.d.ts.map +1 -0
  53. package/dist/schemas.test.js +381 -0
  54. package/dist/schemas.test.js.map +1 -0
  55. package/dist/types.d.ts +1 -0
  56. package/dist/types.d.ts.map +1 -1
  57. package/dist/types.js +2 -0
  58. package/dist/types.js.map +1 -1
  59. package/package.json +13 -6
  60. package/src/builder.ts +1 -2
  61. package/src/context.gen.ts +0 -97
  62. package/src/engine.test.ts +0 -1
  63. package/src/engine.ts +62 -33
  64. package/src/entities.gen.ts +1 -0
  65. package/src/errors.ts +195 -0
  66. package/src/index.ts +2 -0
  67. package/src/overwatch-context.gen.ts +34 -0
  68. package/src/palisade-context.gen.ts +28 -0
  69. package/src/parser.test.ts +53 -0
  70. package/src/parser.ts +83 -36
  71. package/src/schema.gen.ts +60 -541
  72. package/src/schemas.test.ts +449 -0
  73. package/src/schemas.ts +91 -0
  74. package/src/types.ts +3 -0
@@ -4,612 +4,131 @@
4
4
  * Embedded Cedar schema for policy validation.
5
5
  * This is the Highflame Cedar schema used across all services.
6
6
  */
7
- export const CEDAR_SCHEMA = `// Highflame Cedar Schema
8
- // ======================
9
- // This is the SOURCE OF TRUTH for all entity types, actions, and their relationships
10
- // across the Highflame platform.
7
+ export const CEDAR_SCHEMA = `// Highflame Cedar Schema - Entity and Action Definitions
8
+ // =======================================================
9
+ // This file defines all entity types and actions used across Highflame services.
10
+ // Used for code generation (EntityType and ActionType constants).
11
11
  //
12
- // All services (authz, Core, Guardian, Palisade) MUST use the types defined here.
13
- // The codegen tool parses this file and generates typed constants for Go, TypeScript,
14
- // and Python to ensure consistency.
15
- //
16
- // Usage:
17
- // - Policies are validated against this schema when created/updated
18
- // - Generated types prevent typos in application code
19
- // - Cedar CLI can validate: cedar validate --schema highflame.cedarschema --policies policy.cedar
12
+ // For policy validation, use service-specific schemas:
13
+ // - schemas/overwatch/schema.cedarschema (Guardian IDE security)
14
+ // - schemas/palisade/schema.cedarschema (ML supply chain security)
15
+
16
+ namespace Highflame {
20
17
 
21
18
  // =============================================================================
22
- // PRINCIPAL TYPES (Who is making the request)
19
+ // ENTITIES
23
20
  // =============================================================================
24
21
 
25
- // Human user or service account making requests
26
- // Well-known IDs: "mcp_client", "threat_processor"
27
22
  entity User {
28
- // User type: "external", "internal"
29
23
  user_type: String,
30
24
  };
31
25
 
32
- // AI agent or bot
33
26
  entity Agent {
34
- // Agent type: "llm", "scanner", "bot", "coding_assistant"
35
27
  agent_type: String,
36
28
  };
37
29
 
38
- // Security scanner service
39
- // Well-known IDs: "ramparts", "palisade"
40
30
  entity Scanner {
41
- // Scanner type: "ramparts", "palisade"
42
31
  scanner_type: String,
43
- // Scanner version
44
- version: String,
45
32
  };
46
33
 
47
- // Backend service account
48
34
  entity Service {
49
- // Service name
50
- service_name: String,
51
- // Environment: "production", "staging", "development"
52
- environment: String,
35
+ service_type: String,
53
36
  };
54
37
 
55
- // =============================================================================
56
- // RESOURCE TYPES (What is being accessed)
57
- // =============================================================================
58
-
59
- // Generic resource
60
- // Well-known IDs: "threat_analysis", "tools/list", "tools/call", "resources/list",
61
- // "resources/read", "prompts/list", "unknown"
62
38
  entity Resource {};
63
39
 
64
- // LLM response data
65
- // Well-known IDs: "response_data"
40
+ entity LlmPrompt {
41
+ prompt_type: String,
42
+ };
43
+
66
44
  entity ResponseData {};
67
45
 
68
- // MCP tool that can be called
69
46
  entity Tool {
70
- // Tool name
71
47
  tool_name: String,
72
- // Risk level: "safe", "moderate", "dangerous"
73
- risk_level: String,
74
- // Category: "file", "network", "shell", "api"
75
- category: String,
76
48
  };
77
49
 
78
- // File system path
79
50
  entity FilePath {
80
- // Full path
81
51
  path: String,
82
- // File extension
83
- extension: String,
84
- // Whether file is sensitive (.env, credentials, etc.)
85
- is_sensitive: Bool,
86
52
  };
87
53
 
88
- // HTTP endpoint
89
54
  entity HttpEndpoint {
90
- // Hostname
91
55
  hostname: String,
92
- // Scheme: "http", "https"
93
- scheme: String,
94
- // Port number
95
- port: Long,
96
- // Whether endpoint is internal
97
- is_internal: Bool,
98
56
  };
99
57
 
100
- // MCP Server
101
58
  entity Server {
102
- // Server name
103
59
  server_name: String,
104
60
  };
105
61
 
106
- // ML model artifact (for Palisade)
107
62
  entity Artifact {
108
- // Format: "safetensors", "pickle", "gguf", "onnx"
109
- artifact_type: String,
110
- // Source URL or path
111
- source: String,
112
- // SHA256 hash
113
- hash: String,
114
- // Whether artifact is signed
115
- is_signed: Bool,
63
+ artifact_format: String,
116
64
  };
117
65
 
118
- // Code repository
119
66
  entity Repository {
120
- // Repository URL
121
- url: String,
67
+ repo_url: String,
122
68
  };
123
69
 
124
- // Software package
125
70
  entity Package {
126
- // Package name
127
- name: String,
128
- // Package version
129
- version: String,
71
+ package_name: String,
130
72
  };
131
73
 
132
- // Git branch (for branch protection policies)
133
74
  entity GitBranch {
134
- // Branch name (e.g., "main", "develop", "feature/xyz")
135
75
  branch_name: String,
136
- // Whether this is a protected branch
137
- is_protected: Bool,
138
76
  };
139
77
 
140
- // LLM Model (for model-specific policies)
141
78
  entity Model {
142
- // Model name (e.g., "gpt-4", "claude-3-opus")
143
79
  model_name: String,
144
- // Provider (e.g., "openai", "anthropic", "google")
145
- provider: String,
146
- // Whether model is in preview/beta
147
- is_preview: Bool,
148
80
  };
149
81
 
150
- // External API endpoint (for external service calls)
151
82
  entity ExternalAPI {
152
- // API name or identifier
153
83
  api_name: String,
154
- // Base URL or hostname
155
- base_url: String,
156
- // Whether the API is trusted/verified
157
- is_trusted: Bool,
158
84
  };
159
85
 
160
- // Agent memory or RAG storage
161
86
  entity Memory {
162
- // Memory type: "short_term", "long_term", "rag", "vector_store"
163
87
  memory_type: String,
164
- // Whether memory contains sensitive data
165
- is_sensitive: Bool,
166
- };
167
-
168
- // =============================================================================
169
- // ACTIONS - LLM/Guardrails
170
- // =============================================================================
171
-
172
- // Process an LLM prompt
173
- // Context: prompt_text, yara_threats, threat_count, max_threat_severity,
174
- // user_type, monitoring_enabled, injection_score, content_score
175
- action process_prompt appliesTo {
176
- principal: [User, Agent],
177
- resource: [Resource],
178
- };
179
-
180
- // Process an LLM response
181
- // Context: response_size_mb, contains_pii, pii_types, content_category
182
- action process_response appliesTo {
183
- principal: [User, Agent],
184
- resource: [ResponseData],
185
- };
186
-
187
- // Invoke an LLM model
188
- // Context: model_name, model_provider, is_preview_model, estimated_tokens,
189
- // max_tokens, temperature, top_p, is_streaming
190
- action invoke_model appliesTo {
191
- principal: [User, Agent, Service],
192
- resource: [Model, Resource],
193
88
  };
194
89
 
195
- // Filter content (apply content filtering policies)
196
- // Context: content_type, content_category, content_score, harm_categories,
197
- // language, is_harmful, filter_action
198
- action filter_content appliesTo {
199
- principal: [User, Agent, Service],
200
- resource: [Resource, ResponseData],
201
- };
202
-
203
- // =============================================================================
204
- // ACTIONS - MCP/Tool
205
- // =============================================================================
206
-
207
- // Call an MCP tool
208
- // Context: tool_name, tool_arguments, risk_level
209
- action call_tool appliesTo {
210
- principal: [User, Agent, Service],
211
- resource: [Tool, Resource],
212
- };
213
-
214
- // Connect to an MCP server
215
- // Context: server_name, server_url, transport_type
216
- action connect_server appliesTo {
217
- principal: [User, Agent, Service],
218
- resource: [Server, Resource],
219
- };
220
-
221
- // Access a server-specific resource
222
- // Context: tool_name, resource_name, prompt_name
223
- action access_server_resource appliesTo {
224
- principal: [User, Agent, Service],
225
- resource: [Resource],
226
- };
227
-
228
- // Skip guardrails for an operation
229
- action skip_guardrails appliesTo {
230
- principal: [User, Agent, Service],
231
- resource: [Resource],
232
- };
233
-
234
- // =============================================================================
235
- // ACTIONS - File System
236
90
  // =============================================================================
237
-
238
- // Read a file
239
- // Context: path, extension, is_sensitive
240
- action read_file appliesTo {
241
- principal: [User, Agent, Scanner],
242
- resource: [FilePath, Resource],
243
- };
244
-
245
- // Write a file
246
- // Context: path, extension, is_sensitive, file_size_bytes
247
- action write_file appliesTo {
248
- principal: [User, Agent],
249
- resource: [FilePath, Resource],
250
- };
251
-
252
- // Delete a file
253
- // Context: path, extension, is_sensitive
254
- action delete_file appliesTo {
255
- principal: [User, Agent],
256
- resource: [FilePath, Resource],
257
- };
258
-
259
- // =============================================================================
260
- // ACTIONS - HTTP/Network
261
- // =============================================================================
262
-
263
- // Make an HTTP request
264
- // Context: hostname, ip_address, scheme, port, method, is_internal
265
- action http_request appliesTo {
266
- principal: [User, Agent, Service],
267
- resource: [HttpEndpoint, Resource],
268
- };
269
-
270
- // Call an external API
271
- // Context: api_name, endpoint_path, method, is_trusted, request_size_bytes
272
- action call_external_api appliesTo {
273
- principal: [User, Agent, Service],
274
- resource: [ExternalAPI, HttpEndpoint, Resource],
275
- };
276
-
277
- // =============================================================================
278
- // ACTIONS - Code Execution
279
- // =============================================================================
280
-
281
- // Execute code in a sandbox or environment
282
- // Context: code_language, is_sandboxed, code_size_bytes, has_network_access,
283
- // has_filesystem_access, execution_timeout_ms
284
- action execute_code appliesTo {
285
- principal: [User, Agent],
286
- resource: [Resource],
287
- };
288
-
289
- // Run tests
290
- // Context: test_framework, test_count, is_sandboxed, code_language
291
- action run_tests appliesTo {
292
- principal: [User, Agent, Service],
293
- resource: [Repository, Resource],
294
- };
295
-
296
- // Run build process
297
- // Context: build_tool, is_sandboxed, code_language
298
- action run_build appliesTo {
299
- principal: [User, Agent, Service],
300
- resource: [Repository, Resource],
301
- };
302
-
303
- // =============================================================================
304
- // ACTIONS - Git Operations
305
- // =============================================================================
306
-
307
- // General git operation (use for policies that apply to all git actions)
308
- // Context: git_op, target_branch, source_branch, is_force, is_protected_branch,
309
- // changed_files_count, commit_message, remote_url
310
- action git_operation appliesTo {
311
- principal: [User, Agent],
312
- resource: [Repository, GitBranch, Resource],
313
- };
314
-
315
- // Clone a repository
316
- // Context: remote_url, is_shallow, depth
317
- action git_clone appliesTo {
318
- principal: [User, Agent],
319
- resource: [Repository, Resource],
320
- };
321
-
322
- // Create a commit
323
- // Context: commit_message, changed_files_count, author, is_amend
324
- action git_commit appliesTo {
325
- principal: [User, Agent],
326
- resource: [Repository, GitBranch, Resource],
327
- };
328
-
329
- // Push changes to remote
330
- // Context: target_branch, is_force_push, is_protected_branch, remote_url
331
- action git_push appliesTo {
332
- principal: [User, Agent],
333
- resource: [Repository, GitBranch, Resource],
334
- };
335
-
336
- // Pull changes from remote
337
- // Context: source_branch, remote_url, is_rebase
338
- action git_pull appliesTo {
339
- principal: [User, Agent],
340
- resource: [Repository, GitBranch, Resource],
341
- };
342
-
343
- // Merge branches
344
- // Context: source_branch, target_branch, is_protected_branch, merge_strategy
345
- action git_merge appliesTo {
346
- principal: [User, Agent],
347
- resource: [Repository, GitBranch, Resource],
348
- };
349
-
350
- // Checkout branch or commit
351
- // Context: target_branch, is_new_branch, commit_hash
352
- action git_checkout appliesTo {
353
- principal: [User, Agent],
354
- resource: [Repository, GitBranch, Resource],
355
- };
356
-
357
- // Reset changes (potentially destructive)
358
- // Context: reset_mode, target_commit, is_hard_reset
359
- action git_reset appliesTo {
360
- principal: [User, Agent],
361
- resource: [Repository, GitBranch, Resource],
362
- };
363
-
364
- // Rebase branch
365
- // Context: source_branch, target_branch, is_interactive
366
- action git_rebase appliesTo {
367
- principal: [User, Agent],
368
- resource: [Repository, GitBranch, Resource],
369
- };
370
-
371
- // =============================================================================
372
- // ACTIONS - Agent Orchestration
373
- // =============================================================================
374
-
375
- // Delegate task to another agent
376
- // Context: delegation_depth, parent_agent_id, task_type, is_autonomous
377
- action delegate_task appliesTo {
378
- principal: [Agent, Service],
379
- resource: [Resource],
380
- };
381
-
382
- // Spawn a subprocess or child process
383
- // Context: process_name, is_sandboxed, has_network_access, has_filesystem_access
384
- action spawn_subprocess appliesTo {
385
- principal: [User, Agent, Service],
386
- resource: [Resource],
387
- };
388
-
389
- // Access agent memory or RAG storage
390
- // Context: memory_type, operation (read, write, delete), is_sensitive
391
- action access_memory appliesTo {
392
- principal: [Agent, Service],
393
- resource: [Memory, Resource],
394
- };
395
-
396
- // =============================================================================
397
- // ACTIONS - Scanner
398
- // =============================================================================
399
-
400
- // Scan a target (MCP server, repository, etc.)
401
- action scan_target appliesTo {
402
- principal: [Scanner, Service],
403
- resource: [Resource, Repository, Server],
404
- };
405
-
406
- // Scan a software package
407
- action scan_package appliesTo {
408
- principal: [Scanner, Service],
409
- resource: [Package, Resource],
410
- };
411
-
412
- // =============================================================================
413
- // ACTIONS - Palisade/ML
414
- // =============================================================================
415
-
416
- // Scan an ML artifact
417
- // Context: environment, artifact_format, artifact_signed, severity, finding_type,
418
- // provenance_signer, pickle_exec_path_detected, metadata_malicious_pattern,
419
- // tokenizer_added_tokens_count, safetensors_integrity_violation,
420
- // gguf_suspicious_metadata, adapter_base_digest_mismatch,
421
- // metadata_cosai_level_numeric
422
- action scan_artifact appliesTo {
423
- principal: [Scanner, Service],
424
- resource: [Artifact, Resource],
425
- };
426
-
427
- // Validate artifact integrity
428
- action validate_integrity appliesTo {
429
- principal: [Scanner, Service],
430
- resource: [Artifact],
431
- };
432
-
433
- // Validate artifact provenance
434
- action validate_provenance appliesTo {
435
- principal: [Scanner, Service],
436
- resource: [Artifact],
437
- };
438
-
439
- // Quarantine an artifact
440
- action quarantine_artifact appliesTo {
441
- principal: [Scanner, Service],
442
- resource: [Artifact],
443
- };
444
-
445
- // Load an ML model
446
- action load_model appliesTo {
447
- principal: [User, Agent, Service],
448
- resource: [Artifact],
449
- };
450
-
451
- // Deploy an ML model
452
- action deploy_model appliesTo {
453
- principal: [User, Service],
454
- resource: [Artifact],
455
- };
456
-
457
- // =============================================================================
458
- // ACTIONS - Data Loss Prevention (DLP)
459
- // =============================================================================
460
-
461
- // Transfer data (for DLP policies)
462
- // Context: data_classification, destination_type, transfer_size_bytes,
463
- // contains_pii, pii_types, is_encrypted
464
- action transfer_data appliesTo {
465
- principal: [User, Agent, Service],
466
- resource: [Resource],
467
- };
468
-
469
- // Export data (for DLP policies)
470
- // Context: export_format, data_classification, destination_type, is_encrypted
471
- action export_data appliesTo {
472
- principal: [User, Agent, Service],
473
- resource: [Resource],
474
- };
475
-
476
- // =============================================================================
477
- // CONTEXT ATTRIBUTES REFERENCE (Documentation Only)
478
- // =============================================================================
479
- // Cedar context is dynamic and not enforced by schema, but these are the
480
- // standard attributes used across Highflame services:
481
- //
482
- // -----------------------------------------------------------------------------
483
- // GUARDRAILS/CORE
484
- // -----------------------------------------------------------------------------
485
- // tool_name: String - Name of tool being called
486
- // resource_name: String - Name of resource being accessed
487
- // prompt_name: String - Name of prompt
488
- // prompt_text: String - Raw prompt text (for injection detection)
489
- // response_size_mb: Long - Response size in megabytes
490
- // yara_threats: Set<String> - Set of detected YARA threat names
491
- // threat_count: Long - Number of threats detected
492
- // max_threat_severity: Long - Highest severity (0=INFO, 4=CRITICAL)
493
- // user_type: String - "external" or "internal"
494
- // monitoring_enabled: Bool - Whether monitoring is active
495
- // path: String - File path
496
- // hostname: String - HTTP hostname
497
- // ip_address: String - IP address (for SSRF detection)
498
- // scheme: String - HTTP scheme
499
- // port: Long - Port number
500
- //
501
- // -----------------------------------------------------------------------------
502
- // MODEL INVOCATION
503
- // -----------------------------------------------------------------------------
504
- // model_name: String - Name of the model (e.g., "gpt-4", "claude-3-opus")
505
- // model_provider: String - Provider name (e.g., "openai", "anthropic", "google", "azure", "bedrock")
506
- // is_preview_model: Bool - Whether model is in preview/beta
507
- // estimated_tokens: Long - Estimated input + output tokens
508
- // max_tokens: Long - Maximum tokens allowed for response
509
- // temperature: Long - Temperature setting (scaled by 100, e.g., 70 = 0.7)
510
- // top_p: Long - Top-p sampling (scaled by 100)
511
- // is_streaming: Bool - Whether response is streamed
512
- //
513
- // -----------------------------------------------------------------------------
514
- // CONTENT FILTERING
515
- // -----------------------------------------------------------------------------
516
- // content_type: String - Type of content ("text", "code", "image", "audio", "video")
517
- // content_category: String - Category ("general", "adult", "violence", "hate", etc.)
518
- // content_score: Long - Content risk score (0-100)
519
- // injection_score: Long - Prompt injection detection score (0-100)
520
- // jailbreak_score: Long - Jailbreak attempt detection score (0-100)
521
- // contains_pii: Bool - Whether content contains PII
522
- // pii_types: Set<String> - Types of PII detected ("email", "phone", "ssn", "credit_card", etc.)
523
- // language: String - Detected language code (e.g., "en", "es", "zh")
524
- // is_harmful: Bool - Whether content is harmful
525
- // harm_categories: Set<String> - Categories of harm ("violence", "hate", "self_harm", "sexual", etc.)
526
- // filter_action: String - Action to take ("inspect", "mask", "redact", "replace", "anonymize", "reject")
527
- // csam_detected: Bool - Whether CSAM was detected
528
- // hallucination_score: Long - Hallucination detection score (0-100)
529
- //
530
- // -----------------------------------------------------------------------------
531
- // RATE LIMITING
532
- // -----------------------------------------------------------------------------
533
- // concurrent_calls: Long - Current number of concurrent calls
534
- // requests_per_minute: Long - Current requests per minute
535
- // tokens_per_minute: Long - Current tokens per minute
536
- // rate_limit_bucket: String - Rate limit bucket identifier
537
- // is_rate_limited: Bool - Whether rate limit is exceeded
538
- //
539
- // -----------------------------------------------------------------------------
540
- // GIT OPERATIONS
541
- // -----------------------------------------------------------------------------
542
- // git_op: String - Type of git operation ("clone", "commit", "push", "pull", etc.)
543
- // target_branch: String - Target branch name
544
- // source_branch: String - Source branch name
545
- // is_force_push: Bool - Whether this is a force push
546
- // is_protected_branch: Bool - Whether target is a protected branch
547
- // changed_files_count: Long - Number of files changed
548
- // commit_message: String - Commit message text
549
- // remote_url: String - Remote repository URL
550
- // is_shallow: Bool - Whether clone is shallow
551
- // depth: Long - Clone depth for shallow clones
552
- // is_amend: Bool - Whether commit is an amend
553
- // merge_strategy: String - Merge strategy ("merge", "rebase", "squash")
554
- // is_hard_reset: Bool - Whether reset is hard (destructive)
555
- // reset_mode: String - Reset mode ("soft", "mixed", "hard")
556
- // is_interactive: Bool - Whether operation is interactive
557
- //
558
- // -----------------------------------------------------------------------------
559
- // CODE EXECUTION
560
- // -----------------------------------------------------------------------------
561
- // code_language: String - Programming language ("python", "javascript", "go", etc.)
562
- // is_sandboxed: Bool - Whether code runs in a sandbox
563
- // code_size_bytes: Long - Size of code in bytes
564
- // has_network_access: Bool - Whether code has network access
565
- // has_filesystem_access: Bool - Whether code has filesystem access
566
- // execution_timeout_ms: Long - Execution timeout in milliseconds
567
- // test_framework: String - Test framework being used
568
- // test_count: Long - Number of tests being run
569
- // build_tool: String - Build tool being used
570
- //
571
- // -----------------------------------------------------------------------------
572
- // AGENT ORCHESTRATION
573
- // -----------------------------------------------------------------------------
574
- // delegation_depth: Long - Current delegation nesting depth
575
- // parent_agent_id: String - ID of parent agent (if delegated)
576
- // task_type: String - Type of task being performed
577
- // is_autonomous: Bool - Whether agent is operating autonomously
578
- // session_id: String - Agent session identifier
579
- // process_name: String - Name of subprocess being spawned
580
- //
581
- // -----------------------------------------------------------------------------
582
- // MEMORY/RAG
583
- // -----------------------------------------------------------------------------
584
- // memory_type: String - Type of memory ("short_term", "long_term", "rag", "vector_store")
585
- // memory_operation: String - Operation being performed ("read", "write", "delete", "search")
586
- // memory_is_sensitive: Bool - Whether memory contains sensitive data
587
- //
588
- // -----------------------------------------------------------------------------
589
- // DATA LOSS PREVENTION (DLP)
590
- // -----------------------------------------------------------------------------
591
- // data_classification: String - Classification level ("public", "internal", "confidential", "restricted")
592
- // destination_type: String - Where data is going ("internal", "external", "cloud", "email")
593
- // transfer_size_bytes: Long - Size of data being transferred
594
- // is_encrypted: Bool - Whether data is encrypted
595
- // export_format: String - Format of exported data ("json", "csv", "pdf", etc.)
596
- //
597
- // -----------------------------------------------------------------------------
598
- // PALISADE/ML
599
- // -----------------------------------------------------------------------------
600
- // environment: String - "production", "development", "research"
601
- // artifact_format: String - "pickle", "safetensors", "gguf", "onnx"
602
- // artifact_signed: Bool - Whether artifact has signature
603
- // severity: String - "CRITICAL", "HIGH", "MEDIUM", "LOW", "INFO"
604
- // finding_type: String - Type of security finding
605
- // provenance_signer: String - Who signed ("unknown", "unsigned", or name)
606
- // pickle_exec_path_detected: Bool - RCE path found in pickle
607
- // metadata_malicious_pattern: Bool - Malicious pattern in metadata
608
- // tokenizer_added_tokens_count: Long - Number of added tokens
609
- // safetensors_integrity_violation: Bool - Safetensors integrity failed
610
- // gguf_suspicious_metadata: Bool - Suspicious GGUF metadata
611
- // adapter_base_digest_mismatch: Bool - LoRA adapter digest mismatch
612
- // metadata_cosai_level_numeric: Long - CoSAI maturity level (0-5)
613
- //
91
+ // ACTIONS
92
+ // =============================================================================
93
+
94
+ action process_prompt;
95
+ action process_response;
96
+ action invoke_model;
97
+ action filter_content;
98
+ action call_tool;
99
+ action connect_server;
100
+ action access_server_resource;
101
+ action skip_guardrails;
102
+ action read_file;
103
+ action write_file;
104
+ action delete_file;
105
+ action http_request;
106
+ action call_external_api;
107
+ action execute_code;
108
+ action run_tests;
109
+ action run_build;
110
+ action git_operation;
111
+ action git_clone;
112
+ action git_commit;
113
+ action git_push;
114
+ action git_pull;
115
+ action git_merge;
116
+ action git_checkout;
117
+ action git_reset;
118
+ action git_rebase;
119
+ action delegate_task;
120
+ action spawn_subprocess;
121
+ action access_memory;
122
+ action scan_target;
123
+ action scan_package;
124
+ action scan_artifact;
125
+ action validate_integrity;
126
+ action validate_provenance;
127
+ action quarantine_artifact;
128
+ action load_model;
129
+ action deploy_model;
130
+ action transfer_data;
131
+ action export_data;
132
+ }
614
133
  `;
615
134
  //# sourceMappingURL=schema.gen.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"schema.gen.js","sourceRoot":"","sources":["../src/schema.gen.ts"],"names":[],"mappings":"AAAA,2DAA2D;AAC3D,uCAAuC;AAEvC;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+lB3B,CAAC"}
1
+ {"version":3,"file":"schema.gen.js","sourceRoot":"","sources":["../src/schema.gen.ts"],"names":[],"mappings":"AAAA,2DAA2D;AAC3D,uCAAuC;AAEvC;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8H3B,CAAC"}