agent-governance 1.0.4__py3-none-any.whl
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.
- agent_governance/__init__.py +49 -0
- agent_governance/agentctl.py +945 -0
- agent_governance/contracts/__init__.py +0 -0
- agent_governance/contracts/output_packet.schema.json +88 -0
- agent_governance/contracts/task_packet.schema.json +74 -0
- agent_governance/init.py +1049 -0
- agent_governance/update_check.py +310 -0
- agent_governance-1.0.4.dist-info/METADATA +133 -0
- agent_governance-1.0.4.dist-info/RECORD +12 -0
- agent_governance-1.0.4.dist-info/WHEEL +5 -0
- agent_governance-1.0.4.dist-info/entry_points.txt +2 -0
- agent_governance-1.0.4.dist-info/top_level.txt +1 -0
|
File without changes
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"title": "OutputPacket",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"required": [
|
|
6
|
+
"task_id",
|
|
7
|
+
"role",
|
|
8
|
+
"run_id",
|
|
9
|
+
"status",
|
|
10
|
+
"changes",
|
|
11
|
+
"diff",
|
|
12
|
+
"commands_run",
|
|
13
|
+
"command_outputs"
|
|
14
|
+
],
|
|
15
|
+
"properties": {
|
|
16
|
+
"task_id": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"description": "Must match TaskPacket.id"
|
|
19
|
+
},
|
|
20
|
+
"role": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "Role that produced this output"
|
|
23
|
+
},
|
|
24
|
+
"run_id": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "Unique identifier for this execution/run"
|
|
27
|
+
},
|
|
28
|
+
"status": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"enum": ["success", "fail", "blocked"]
|
|
31
|
+
},
|
|
32
|
+
"changes": {
|
|
33
|
+
"type": "object",
|
|
34
|
+
"required": ["files_changed"],
|
|
35
|
+
"properties": {
|
|
36
|
+
"files_changed": {
|
|
37
|
+
"type": "array",
|
|
38
|
+
"items": { "type": "string" }
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"additionalProperties": false
|
|
42
|
+
},
|
|
43
|
+
"diff": {
|
|
44
|
+
"type": "string",
|
|
45
|
+
"description": "Unified diff inline or a path reference"
|
|
46
|
+
},
|
|
47
|
+
"commands_run": {
|
|
48
|
+
"type": "array",
|
|
49
|
+
"items": { "type": "string" },
|
|
50
|
+
"minItems": 1,
|
|
51
|
+
"description": "Exact commands executed"
|
|
52
|
+
},
|
|
53
|
+
"command_outputs": {
|
|
54
|
+
"type": "array",
|
|
55
|
+
"items": { "type": "string" },
|
|
56
|
+
"minItems": 1,
|
|
57
|
+
"description": "Captured logs or paths to command outputs"
|
|
58
|
+
},
|
|
59
|
+
"remaining_issues": {
|
|
60
|
+
"type": "array",
|
|
61
|
+
"items": { "type": "string" },
|
|
62
|
+
"description": "If status != success, what is still broken"
|
|
63
|
+
},
|
|
64
|
+
"next_step": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"description": "If status != success, the smallest next actionable step"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"allOf": [
|
|
70
|
+
{
|
|
71
|
+
"if": { "properties": { "status": { "const": "success" } } },
|
|
72
|
+
"then": {
|
|
73
|
+
"not": {
|
|
74
|
+
"anyOf": [
|
|
75
|
+
{ "required": ["next_step"] }
|
|
76
|
+
]
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"if": { "properties": { "status": { "enum": ["fail", "blocked"] } } },
|
|
82
|
+
"then": {
|
|
83
|
+
"required": ["remaining_issues", "next_step"]
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
],
|
|
87
|
+
"additionalProperties": false
|
|
88
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"title": "TaskPacket",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"required": [
|
|
6
|
+
"id",
|
|
7
|
+
"title",
|
|
8
|
+
"role",
|
|
9
|
+
"goal",
|
|
10
|
+
"repo_context",
|
|
11
|
+
"constraints",
|
|
12
|
+
"deliverables",
|
|
13
|
+
"stop_conditions"
|
|
14
|
+
],
|
|
15
|
+
"properties": {
|
|
16
|
+
"id": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"description": "Unique task identifier"
|
|
19
|
+
},
|
|
20
|
+
"title": {
|
|
21
|
+
"type": "string"
|
|
22
|
+
},
|
|
23
|
+
"role": {
|
|
24
|
+
"type": "string",
|
|
25
|
+
"description": "Agent role to execute this task"
|
|
26
|
+
},
|
|
27
|
+
"goal": {
|
|
28
|
+
"type": "string",
|
|
29
|
+
"description": "Single-sentence objective"
|
|
30
|
+
},
|
|
31
|
+
"repo_context": {
|
|
32
|
+
"type": "object",
|
|
33
|
+
"required": ["branch", "commit"],
|
|
34
|
+
"properties": {
|
|
35
|
+
"branch": { "type": "string" },
|
|
36
|
+
"commit": { "type": "string" },
|
|
37
|
+
"paths": {
|
|
38
|
+
"type": "array",
|
|
39
|
+
"items": { "type": "string" }
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"inputs": {
|
|
44
|
+
"type": "array",
|
|
45
|
+
"items": { "type": "string" },
|
|
46
|
+
"description": "Files, logs, or commands already available"
|
|
47
|
+
},
|
|
48
|
+
"constraints": {
|
|
49
|
+
"type": "object",
|
|
50
|
+
"required": ["allowed_write_paths"],
|
|
51
|
+
"properties": {
|
|
52
|
+
"allowed_write_paths": {
|
|
53
|
+
"type": "array",
|
|
54
|
+
"items": { "type": "string" }
|
|
55
|
+
},
|
|
56
|
+
"forbidden_actions": {
|
|
57
|
+
"type": "array",
|
|
58
|
+
"items": { "type": "string" }
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
},
|
|
62
|
+
"deliverables": {
|
|
63
|
+
"type": "array",
|
|
64
|
+
"items": {
|
|
65
|
+
"enum": ["diff", "tests", "logs", "commands", "report"]
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"stop_conditions": {
|
|
69
|
+
"type": "array",
|
|
70
|
+
"items": { "type": "string" }
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
"additionalProperties": false
|
|
74
|
+
}
|