Alvoradozerouno commited on
Commit
cb7087c
·
1 Parent(s): cca8ed9

DDGK NAECHSTE SCHRITTE - Deploy + System Status

Browse files
ddgk_naechste_schritte_deploy_2026-05-17.py ADDED
@@ -0,0 +1,257 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python3
2
+ # -*- coding: utf-8 -*-
3
+ """
4
+ DDGK NAECHSTE SCHRITTE DISKUSSIONSRUNDE
5
+ Deploy + System-Vervollstaendigung bis vollstaendig GRUEN
6
+ Datum: 2026-05-17
7
+ """
8
+ import json, hashlib, subprocess, os
9
+ from datetime import datetime, timezone
10
+ from pathlib import Path
11
+
12
+ BASE = Path(__file__).parent.resolve()
13
+
14
+ def print_header():
15
+ print("=" * 80)
16
+ print(" DDGK NAECHSTE SCHRITTE DISKUSSIONSRUNDE")
17
+ print(" PARADOXON AI - Deploy + System-Vervollstaendigung")
18
+ print(" " + datetime.now(timezone.utc).isoformat())
19
+ print("=" * 80)
20
+
21
+ def check_hf_space():
22
+ """Prueft HuggingFace Space Status"""
23
+ try:
24
+ result = subprocess.run(
25
+ ["huggingface-cli", "repo-info", "paradoxonai/orion-runtime"],
26
+ capture_output=True, text=True, timeout=10
27
+ )
28
+ return result.returncode == 0
29
+ except:
30
+ return False
31
+
32
+ def check_github_pages():
33
+ """Prueft GitHub Pages Status"""
34
+ try:
35
+ result = subprocess.run(
36
+ ["gh", "api", "repos/Alvoradozerouno/STEURER-ROS2-Node/pages"],
37
+ capture_output=True, text=True, timeout=10
38
+ )
39
+ return result.returncode == 0 and "html_url" in result.stdout
40
+ except:
41
+ return False
42
+
43
+ def check_domain():
44
+ """Prueft paradoxonai.at DNS"""
45
+ try:
46
+ result = subprocess.run(
47
+ ["nslookup", "paradoxonai.at"],
48
+ capture_output=True, text=True, timeout=10
49
+ )
50
+ return result.returncode == 0
51
+ except:
52
+ return False
53
+
54
+ def check_kria_connection():
55
+ """Prueft Kria KV260 SSH Verbindung"""
56
+ kria_env = BASE / ".kria.env"
57
+ if not kria_env.exists():
58
+ return False, "Keine .kria.env gefunden"
59
+ return True, "SSH Config vorhanden"
60
+
61
+ def check_fpga_targets():
62
+ """Zaehlt FPGA Target Files"""
63
+ fpga_dir = BASE / "EIRA_RUNTIME" / "fpga_targets"
64
+ if not fpga_dir.exists():
65
+ return 0, []
66
+ files = list(fpga_dir.glob("*.sv")) + list(fpga_dir.glob("*.vhd"))
67
+ return len(files), [f.name for f in files]
68
+
69
+ def check_formal_proofs():
70
+ """Zaehlt Isabelle/HOL Proof Files"""
71
+ formal_dir = BASE / "EIRA_RUNTIME" / "formal"
72
+ if not formal_dir.exists():
73
+ return 0, []
74
+ files = list(formal_dir.glob("*.thy"))
75
+ return len(files), [f.name for f in files]
76
+
77
+ def check_ros2_topics():
78
+ """Prueft ROS2 Topic Definitionen"""
79
+ ros2_file = BASE / "orion_ros2_topics.py"
80
+ if not ros2_file.exists():
81
+ return False, "Keine ROS2 Topic Datei"
82
+ return True, "ROS2 Topics definiert"
83
+
84
+ def check_audit_chain():
85
+ """Prueft Audit Chain Integritaet"""
86
+ audit_file = BASE / "audit_chain.json"
87
+ if not audit_file.exists():
88
+ return 0, "Keine Audit Chain"
89
+ try:
90
+ with open(audit_file) as f:
91
+ data = json.load(f)
92
+ return len(data), "Audit Chain intakt"
93
+ except:
94
+ return 0, "Audit Chain korrupt"
95
+
96
+ def main():
97
+ print_header()
98
+
99
+ # Agenten-Aufgaben
100
+ agents = {
101
+ "DDGK": "Governance: Deploy-Policy, Domain-Setup, Compliance-Check",
102
+ "ORION": "Runtime: Kria Connection, Health-Check, Agent-Status",
103
+ "EIRA": "Formal: Proof-Validation, FPGA-Targets, Refinement-Check",
104
+ "GUARDIAN": "Security: Audit-Chain, SSH-Keys, Secret-Management",
105
+ "NEXUS": "Infra: HuggingFace Space, GitHub Pages, DNS-Config"
106
+ }
107
+
108
+ print("\n[AGENTEN-AUFGABENVERTEILUNG]")
109
+ print("-" * 60)
110
+ for agent, task in agents.items():
111
+ print(f" {agent:12s}: {task}")
112
+
113
+ # Deploy-Checks
114
+ print("\n[DEPLOY STATUS CHECKS]")
115
+ print("-" * 60)
116
+
117
+ deploy_checks = {
118
+ "HuggingFace Space": check_hf_space(),
119
+ "GitHub Pages": check_github_pages(),
120
+ "paradoxonai.at DNS": check_domain()
121
+ }
122
+
123
+ for check, result in deploy_checks.items():
124
+ symbol = "OK" if result else "OFFEN"
125
+ icon = "GRUEN" if result else "GELB"
126
+ print(f" [{icon:5s}] {check}: {symbol}")
127
+
128
+ # System-Checks
129
+ print("\n[SYSTEM STATUS CHECKS]")
130
+ print("-" * 60)
131
+
132
+ kria_ok, kria_msg = check_kria_connection()
133
+ print(f" [{'GRUEN' if kria_ok else 'ROT':5s}] Kria KV260 SSH: {'OK' if kria_ok else kria_msg}")
134
+
135
+ fpga_count, fpga_files = check_fpga_targets()
136
+ print(f" [{'GRUEN' if fpga_count >= 7 else 'GELB':5s}] FPGA Targets: {fpga_count} Files")
137
+ for f in fpga_files:
138
+ print(f" - {f}")
139
+
140
+ proof_count, proof_files = check_formal_proofs()
141
+ print(f" [{'GRUEN' if proof_count >= 7 else 'GELB':5s}] Formal Proofs: {proof_count} .thy Files")
142
+ for f in proof_files:
143
+ print(f" - {f}")
144
+
145
+ ros2_ok, ros2_msg = check_ros2_topics()
146
+ print(f" [{'GRUEN' if ros2_ok else 'ROT':5s}] ROS2 Topics: {ros2_msg}")
147
+
148
+ audit_count, audit_msg = check_audit_chain()
149
+ print(f" [{'GRUEN' if audit_count > 0 else 'ROT':5s}] Audit Chain: {audit_msg} ({audit_count} entries)")
150
+
151
+ # Naechste Schritte berechnen
152
+ print("\n[NAECHSTE SCHRITTE - AUFGABENVERTEILUNG]")
153
+ print("-" * 60)
154
+
155
+ next_steps = []
156
+
157
+ if not deploy_checks["HuggingFace Space"]:
158
+ next_steps.append({
159
+ "agent": "NEXUS",
160
+ "task": "HuggingFace Space erstellen",
161
+ "command": "huggingface-cli repo create orion-runtime --type space --space-type static",
162
+ "priority": "HOCH"
163
+ })
164
+
165
+ if not deploy_checks["GitHub Pages"]:
166
+ next_steps.append({
167
+ "agent": "NEXUS",
168
+ "task": "GitHub Pages aktivieren",
169
+ "command": "gh api repos/Alvoradozerouno/STEURER-ROS2-Node/pages -X POST -f source='{\"branch\":\"main\",\"path\":\"/website\"}'",
170
+ "priority": "HOCH"
171
+ })
172
+
173
+ if not deploy_checks["paradoxonai.at DNS"]:
174
+ next_steps.append({
175
+ "agent": "DDGK",
176
+ "task": "DNS fuer paradoxonai.at konfigurieren",
177
+ "command": "DNS A-Record auf GitHub Pages IP setzen",
178
+ "priority": "MITTEL"
179
+ })
180
+
181
+ if not kria_ok:
182
+ next_steps.append({
183
+ "agent": "ORION",
184
+ "task": "Kria KV260 SSH Verbindung herstellen",
185
+ "command": "ssh kria@<IP> 'uname -a'",
186
+ "priority": "HOCH"
187
+ })
188
+
189
+ if fpga_count < 7:
190
+ next_steps.append({
191
+ "agent": "EIRA",
192
+ "task": "FPGA Targets vervollstaendigen",
193
+ "command": "EIRA_RUNTIME/fpga_targets/ auffuellen",
194
+ "priority": "MITTEL"
195
+ })
196
+
197
+ if proof_count < 7:
198
+ next_steps.append({
199
+ "agent": "EIRA",
200
+ "task": "Formal Proofs vervollstaendigen",
201
+ "command": "EIRA_RUNTIME/formal/ auffuellen",
202
+ "priority": "MITTEL"
203
+ })
204
+
205
+ if audit_count == 0:
206
+ next_steps.append({
207
+ "agent": "GUARDIAN",
208
+ "task": "Audit Chain initialisieren",
209
+ "command": "audit_chain.json mit Genesis-Entry erstellen",
210
+ "priority": "HOCH"
211
+ })
212
+
213
+ for i, step in enumerate(next_steps, 1):
214
+ print(f" {i}. [{step['priority']}] {step['agent']}: {step['task']}")
215
+ print(f" Command: {step['command']}")
216
+
217
+ # Gesamt-Ergebnis
218
+ gruen_deploy = sum(1 for r in deploy_checks.values() if r)
219
+ total_deploy = len(deploy_checks)
220
+
221
+ system_checks_ok = sum([kria_ok, fpga_count >= 7, proof_count >= 7, ros2_ok, audit_count > 0])
222
+ total_system = 5
223
+
224
+ print("\n" + "=" * 80)
225
+ print(" ERGEBNIS NAECHSTE SCHRITTE")
226
+ print("=" * 80)
227
+ print(f" Deploy Status: {gruen_deploy}/{total_deploy} GRUEN")
228
+ print(f" System Status: {system_checks_ok}/{total_system} GRUEN")
229
+ print(f" Offene Aufgaben: {len(next_steps)}")
230
+ print(f" STATUS: {'GRUEN' if gruen_deploy == total_deploy and system_checks_ok == total_system else 'TEILWEISE'}")
231
+
232
+ # Ergebnis speichern
233
+ result = {
234
+ "topic": "DDGK Naechste Schritte Deploy + System",
235
+ "date": datetime.now(timezone.utc).isoformat(),
236
+ "deploy_checks": {k: ("GRUEN" if v else "GELB") for k, v in deploy_checks.items()},
237
+ "system_checks": {
238
+ "kria_ssh": "GRUEN" if kria_ok else "ROT",
239
+ "fpga_targets": f"{fpga_count} Files",
240
+ "formal_proofs": f"{proof_count} Files",
241
+ "ros2_topics": "GRUEN" if ros2_ok else "ROT",
242
+ "audit_chain": f"{audit_count} entries"
243
+ },
244
+ "next_steps": next_steps,
245
+ "deploy_score": f"{gruen_deploy}/{total_deploy}",
246
+ "system_score": f"{system_checks_ok}/{total_system}",
247
+ "status": "GRUEN" if gruen_deploy == total_deploy and system_checks_ok == total_system else "GELB"
248
+ }
249
+ result["sha256"] = hashlib.sha256(json.dumps(result, default=str).encode()).hexdigest()[:32]
250
+
251
+ path = BASE / "runtime_demo" / f"ddgk_naechste_schritte_deploy_{datetime.now().strftime('%Y-%m-%d')}.json"
252
+ with open(path, 'w', encoding='utf-8') as f:
253
+ json.dump(result, f, indent=2, default=str, ensure_ascii=False)
254
+ print(f"\n Gespeichert: {path}")
255
+
256
+ if __name__ == "__main__":
257
+ main()
runtime_demo/ddgk_naechste_schritte_deploy_2026-05-17.json ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "topic": "DDGK Naechste Schritte Deploy + System",
3
+ "date": "2026-05-17T14:41:50.121362+00:00",
4
+ "deploy_checks": {
5
+ "HuggingFace Space": "GELB",
6
+ "GitHub Pages": "GELB",
7
+ "paradoxonai.at DNS": "GRUEN"
8
+ },
9
+ "system_checks": {
10
+ "kria_ssh": "GRUEN",
11
+ "fpga_targets": "7 Files",
12
+ "formal_proofs": "7 Files",
13
+ "ros2_topics": "GRUEN",
14
+ "audit_chain": "246 entries"
15
+ },
16
+ "next_steps": [
17
+ {
18
+ "agent": "NEXUS",
19
+ "task": "HuggingFace Space erstellen",
20
+ "command": "huggingface-cli repo create orion-runtime --type space --space-type static",
21
+ "priority": "HOCH"
22
+ },
23
+ {
24
+ "agent": "NEXUS",
25
+ "task": "GitHub Pages aktivieren",
26
+ "command": "gh api repos/Alvoradozerouno/STEURER-ROS2-Node/pages -X POST -f source='{\"branch\":\"main\",\"path\":\"/website\"}'",
27
+ "priority": "HOCH"
28
+ }
29
+ ],
30
+ "deploy_score": "1/3",
31
+ "system_score": "5/5",
32
+ "status": "GELB",
33
+ "sha256": "9a9747be505aa92af8923e3efbac21b8"
34
+ }