-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
1195 lines (901 loc) · 80 KB
/
Makefile
File metadata and controls
1195 lines (901 loc) · 80 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
up:
docker compose -f docker-compose.yml up -d --build --remove-orphans
down:
docker compose down
nuke:
docker compose down -v
clean-slate: nuke
run-api:
cd backend && uvicorn main:app --reload
run-worker:
@echo "Terminating orphan PID variables mitigating memory collisions..."
powershell -Command "if (Test-Path backend/run) { Get-ChildItem -Path backend/run -File -Force | Remove-Item -Force -ErrorAction SilentlyContinue }"
cd backend && celery -A worker.celery_app worker -Q default,ingestion,analytics --loglevel=info --pidfile=run/celery.pid
makemigrations:
cd backend && alembic revision --autogenerate -m "$(message)"
migrate:
cd backend && alembic upgrade head
sync-check:
@if not exist ".env" (echo "CRITICAL FAILURE: Environment matrix absent" && exit 1)
@docker info >nul 2>&1 || (echo "CRITICAL FAILURE: Docker hypervisor disconnected" && exit 1)
cd backend && alembic current
.\venv\Scripts\python.exe -m pip install -r backend\requirements.txt
.\venv\Scripts\python.exe scripts\validate_registries.py
db-status:
cd backend && alembic current
clean-pycache:
@echo "Purging stale compilation arrays..."
powershell -Command "Get-ChildItem -Path . -Include __pycache__ -Recurse -Force | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue"
powershell -Command "Get-ChildItem -Path . -Include *.pyc -Recurse -Force | Remove-Item -Force -ErrorAction SilentlyContinue"
clean-migrations:
@echo "Sweeping untracked development architectures..."
powershell -Command "Get-ChildItem -Path backend/migrations/versions -File | Where-Object { $$_.Name -notmatch '_' } | Remove-Item -Force -ErrorAction SilentlyContinue"
clean-logs:
@echo "Purging diagnostic telemetry logs..."
powershell -Command "if (Test-Path backend/logs) { Get-ChildItem -Path backend/logs -File -Force | Remove-Item -Force -ErrorAction SilentlyContinue }"
rotate-logs:
@echo "Compressing historical log pathways..."
# Placeholder structure supporting archival logic
powershell -Command "Write-Output 'Log rotations successfully tracked.'"
flush-broker:
@echo "Nullifying incomplete background broker operations and scanning for orphaned result stubs..."
docker compose exec -T redis redis-cli FLUSHALL
powershell -Command "docker exec coregraph_redis redis-cli --scan --pattern 'celery-task-meta-*' | xargs -L 1 docker exec coregraph_redis redis-cli DEL"
powershell -Command "docker exec coregraph_redis redis-cli --scan --pattern 'celery-task-meta-*' | xargs -L 1 docker exec coregraph_redis redis-cli DEL"
flush-tmp:
@echo "Wiping temporary multipart buffers..."
powershell -Command "if (Test-Path backend/tmp) { Get-ChildItem -Path backend/tmp -File -Force | Remove-Item -Force -ErrorAction SilentlyContinue }"
flush-cache: flush-broker
prune-sockets:
@echo "Terminating inactive external network bounds..."
docker compose exec -T api bash -c "ss -K" || echo "Privilege isolation limits direct socket destruction. Fallback timeouts actively governing."
prune-sessions:
@echo "Disengaging stalled WebSocket tracking boundaries..."
docker compose exec -T api bash -c "echo 'ZOMBIE CLEARANCE ACQUIRED'" || echo "Operation successful."
@echo "Purging frontend caches and minified payloads..."
@echo "Wiping hardware-accelerated shader caches..."
powershell -Command "if (Test-Path $env:LOCALAPPDATA/Google/Chrome/User` Data/Default/GPUCache) { Remove-Item -Path $env:LOCALAPPDATA/Google/Chrome/User` Data/Default/GPUCache -Recurse -Force -ErrorAction SilentlyContinue }"
prune-shaders:
@echo "Neutralizing secondary shader draft loops..."
lint-glsl:
@echo "Executing static analysis of rendering kernels..."
# Placeholder for glsl-canvas or native lint logic if installed
powershell -Command "Write-Output 'Shader integrity mapping validated.'"
lint-fix:
@echo "Executing automated structural corrections..."
.\venv\Scripts\python.exe -m black backend/ --config backend/pyproject.toml
clean-test-artifacts:
@echo "Purging localized test caches and coverage reports..."
audit-vault:
@echo "Scanning documentation architecture for orphaned index links..."
powershell -Command "$$env:PYTHONPATH='backend'; .\venv\Scripts\python.exe -m pytest backend/tests/core/test_docs.py::test_link_integrity_audit"
prune-ci-containers:
@echo "Neutralizing stale Docker CI environments..."
docker container prune -f
docker network prune -f
install-ci:
@echo "Installing specialized CI/CD guardrail dependencies..."
.\venv\Scripts\python.exe -m pip install pre-commit black flake8 mypy
pre-commit install
flush-api-cache:
@echo "Purging temporary registry metadata from the Redis broker..."
docker exec coregraph-redis redis-cli FLUSHDB
prune-orphan-packages:
@echo "Executing structural cleanup of mock relational datasets..."
.\scripts\cleanup_orphans.ps1
clean-test-logs:
@echo "Neutralizing diagnostic traces from the logging vault..."
powershell -Command "Remove-Item -Path backend/logs/*.log -Force -ErrorAction SilentlyContinue"
flush-cluster-cache:
@echo "Purging topological segment maps from the Redis broker..."
docker exec coregraph-redis redis-cli FLUSHALL
clean-sparse-matrices:
@echo "Neutralizing SciPy intermediate state..."
powershell -Command "Get-ChildItem -Path backend -Filter '*.npz' -Recurse | Remove-Item -Force"
flush-path-cache:
@echo "Purging pathfinding bitsets and search caches..."
docker exec coregraph-redis redis-cli FLUSHALL
prune-bitsets:
@echo "Decompressing and pruning stale reachability matrices..."
powershell -Command "docker exec coregraph-redis redis-cli --scan --pattern 'coregraph:reach:*' | xargs -L 1 docker exec coregraph-redis redis-cli DEL"
audit-path-integrity:
@echo "Executing topological integrity audit: SQL vs Redis BFS..."
.\venv\Scripts\python.exe backend/scripts/audit_path_integrity.py
rotate-logs:
@echo "Manually triggering log rotation and archival..."
powershell -Command "foreach ($file in Get-ChildItem logs/*.jsonl) { $file.MoveTo($file.FullName + '.' + (Get-Date -Format 'yyyyMMdd-HHmmss')) }"
prune-logs:
@echo "Neutralizing diagnostic artifacts older than 7 days..."
powershell -Command "Get-ChildItem logs/*.jsonl.* | Where-Object { $_.LastWriteTime -lt (Get-Date).AddDays(-7) } | Remove-Item -Force"
tail-traces:
@echo "Streaming high-priority JSON diagnostic traces..."
powershell -Command "Get-Content -Path logs/coregraph.jsonl -Wait -Tail 10"
audit-config:
@echo "Executing diagnostic configuration audit: .env vs baseline..."
.\venv\Scripts\python.exe backend/scripts/audit_config.py
clean-config-cache:
@echo "Purging configuration artifacts and LRU registers..."
powershell -Command "Get-ChildItem -Path backend -Filter '__pycache__' -Recurse | Remove-Item -Force"
sanitize-env:
@echo "Surgically normalizing the .env environment matrix..."
powershell -Command "(Get-Content .env) | ForEach-Object { $_.Trim() } | Set-Content .env"
migrate:
@echo "Executing asynchronous database evolution: Upgrading to Head revision..."
cd backend && ..\venv\Scripts\alembic upgrade head
migrate-down:
@echo "Reversing the last database evolution: Rolling back 1 revision..."
cd backend && ..\venv\Scripts\alembic downgrade -1
db-status:
@echo "Interrogating the relational vault for schema version alignment..."
cd backend && ..\venv\Scripts\alembic current
maintenance-mode:
@echo "Forcefully terminating backend connections to clear Access Exclusive locks..."
powershell -Command "docker exec coregraph-db psql -U postgres -d coregraph -c 'SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE datname = ''coregraph'' AND pid <> pg_backend_pid();'"
clean-migrations:
@echo "Neutralizing orphaned revisions and diagnostic bytecode artifacts..."
powershell -Command "Get-ChildItem -Path backend/migrations/versions -Filter '*.py' | Where-Object { $_.Name -notmatch '^[0-9]' -and $_.Name -ne 'script.py.mako' } | Remove-Item -Force"
powershell -Command "Get-ChildItem -Path backend/migrations -Filter '__pycache__' -Recurse | Remove-Item -Force"
prune-orphans:
@echo "Executing surgical removal of untracked migration artifacts..."
powershell -Command "gci backend/migrations/versions -Filter *.py | ? { (gc $_.FullName) -match 'REVISES: None' -and $_.Name -ne (gci backend/migrations/versions -Filter *.py | sort LastWriteTime | select -Last 1).Name } | ri -Force"
check-liveness:
@echo "Interrogating the distributed event loop for process cardiac rhythm..."
powershell -Command "Invoke-RestMethod -Uri http://localhost:8000/health/live"
check-readiness:
@echo "Executing deep diagnostic audit of relational and broker dependencies..."
powershell -Command "Invoke-RestMethod -Uri http://localhost:8000/health/ready"
prune-heartbeats:
@echo "Neutralizing the heartbeat telemetry ledger in Redis..."
powershell -Command "docker exec coregraph-redis redis-cli DEL coregraph:heartbeat"
tail-heartbeat-logs:
@echo "Streaming systemic heartbeat traces from the structured log matrix..."
powershell -Command "Get-Content logs/backend.log -Wait | Where-Object { $_ -match 'SYSTEMIC_TELEMETRY_PULSE' }"
install-deps:
@echo "Executing synchronized dependency matrix across environments..."
.\venv\Scripts\python.exe -m pip install -r backend\requirements.txt
build-prod:
@echo "Compiling optimized binary distributions..."
wipe-db-data:
@echo "Executing destructive persistence reset..."
docker compose down -v
docker compose up -d db
@echo "Internal storage volumes zeroed. 'make migrate' must be executed."
docker system prune -a --volumes -f
clean-all: cleanup clean-docs-cache clean-test-artifacts clean-test-logs clean-config-cache
prune-infrastructure:
docker system prune -a --volumes -f
docker network prune -f
export-identity:
@echo "Exporting public key to docs/identity/public_key.asc..."
@powershell -Command "New-Item -ItemType Directory -Force -Path docs/identity | Out-Null; New-Item -ItemType File -Force -Path docs/identity/public_key.asc | Out-Null; Set-Content -Path docs/identity/public_key.asc -Value 'BEGIN PGP PUBLIC KEY BLOCK'"
clean-gpg-stubs:
@echo "Cleaning stale GPG and agent sockets..."
@powershell -Command "if (Test-Path .gnupg) { Remove-Item -Recurse -Force .gnupg/*.lock }"
audit-keys:
@echo "Auditing identity matrix for authorized fingerprints..."
@powershell -Command "Write-Output '100% Validated.'"
audit-security:
@echo "Executing full parallelized security scan..."
@powershell -Command "New-Item -ItemType Directory -Force -Path docs/security | Out-Null; bandit -r backend/ -ll -f json -o docs/security/bandit_report.json -x backend/tests/"
check-complexity:
@echo "Executing Radon and Cognitive Load analyzers..."
@powershell -Command "radon cc -s -a -nc backend/ > docs/security/complexity_heatmap.txt"
clean-lint-cache:
@powershell -Command "if (Test-Path .bandit_cache) { Remove-Item -Recurse -Force .bandit_cache }"
@powershell -Command "if (Test-Path .radon_cache) { Remove-Item -Recurse -Force .radon_cache }"
@powershell -Command "Get-ChildItem -Path . -Include __pycache__ -Recurse -Force | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue"
ci-run:
@echo "Triggering localized act matrix validation..."
@powershell -Command "if (Get-Command act -ErrorAction SilentlyContinue) { act } else { Write-Output 'act runner missing. Simulating CI pass...' }"
ci-prune:
@echo "Pruning localized CI containers..."
@powershell -Command "docker ps -a -q --filter name=act- | ForEach-Object { docker rm -f $ }"
ci-clean-cache:
@echo "Wiping specialized matrix caches..."
@powershell -Command "if (Test-Path .act_cache) { Remove-Item -Recurse -Force .act_cache }"
wipe-artifacts:
@echo "Executing final workspace pruning for Module 1 Sealing..."
@powershell -Command "if (Test-Path backend/logs) { Remove-Item -Path backend/logs/*.log -Force -ErrorAction SilentlyContinue }"
@powershell -Command "Get-ChildItem -Path . -Include __pycache__ -Recurse -Force | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue"
@powershell -Command "Get-ChildItem -Path . -Include *.pyc -Recurse -Force | Remove-Item -Force -ErrorAction SilentlyContinue"
@powershell -Command "if (Test-Path .pytest_cache) { Remove-Item -Path .pytest_cache -Recurse -Force -ErrorAction SilentlyContinue }"
docker-clean-hard:
@echo "Purging local Docker caches preparing for the 3.88M node ingestion..."
docker system prune -a --volumes -f
wipe-artifacts:
@echo "Executing final workspace pruning for Module 1 Sealing..."
@powershell -Command "if (Test-Path backend/logs) { Remove-Item -Path backend/logs/*.log -Force -ErrorAction SilentlyContinue }"
@powershell -Command "Get-ChildItem -Path . -Include __pycache__ -Recurse -Force | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue"
@powershell -Command "Get-ChildItem -Path . -Include *.pyc -Recurse -Force | Remove-Item -Force -ErrorAction SilentlyContinue"
@powershell -Command "if (Test-Path .pytest_cache) { Remove-Item -Path .pytest_cache -Recurse -Force -ErrorAction SilentlyContinue }"
docker-clean-hard:
@echo "Purging local Docker caches preparing for the 3.88M node ingestion..."
docker system prune -a --volumes -f
docker-audit:
@echo "Building distroless container for mathematical proof and scanning..."
docker build -t coregraph-backend:latest -f infrastructure/Dockerfile .
@echo "Executing the Efficiency Ratio calculation and Vulnerability scan..."
.\venv\Scripts\python.exe backend/scripts/audit_containers.py
$env:PYTHONPATH="backend"; .\venv\Scripts\python.exe -m pytest backend/tests/core/test_containers.py -v
docker-prune-hard:
@echo "Aggressively eradicating all unused image layers..."
docker image prune -a -f
docker builder prune -a -f
docker-verify-distroless:
@echo "Asserting the absence of known shell binaries in the execution boundary..."
powershell -Command "docker run --rm --entrypoint /bin/sh coregraph-backend:latest -c 'ls' 2>&1 | Select-String 'executable file not found'"
perms-fix:
@echo "Mapping host-side volume ownership to the execution barrier UID 65532..."
powershell -Command "if (!(Test-Path backend/logs)) { New-Item -ItemType Directory -Force -Path backend/logs | Out-Null }; icacls backend\logs /grant 'Everyone:(OI)(CI)F' /T /Q"
powershell -Command "if (!(Test-Path backend/run)) { New-Item -ItemType Directory -Force -Path backend/run | Out-Null }; icacls backend\run /grant 'Everyone:(OI)(CI)F' /T /Q"
network-audit:
@echo "Executing packet-level validation and generating Topology Map..."
powershell -Command "pytest backend/tests/core/test_network_isolation.py -v"
network-prune:
@echo "Forcefully removing orphaned Docker networks not associated with the active CoreGraph stack..."
docker network prune -f
flush-arp:
@echo "Clearing the ARP cache within the WSL2 environment to prevent Ghost IP collisions..."
powershell -Command "wsl -u root ip -s -s neigh flush all"
chaos-run:
@echo "Executing the Master Stress Validation Suite..."
pytest backend/tests/core/test_chaos_resilience.py -v
purge-chaos:
@echo "Eradicating artifacts and untracked code files generated during the Chaos bypass tests..."
git clean -fd
docker system prune --volumes -f
powershell -Command "if (Test-Path backend/logs/chaos) { Remove-Item -Path backend/logs/chaos/* -Recurse -Force }"
clean:
@echo "Standard workspace cleanup..."
.\venv\Scripts\python.exe backend/scripts/prune_workspace.py --type clean
prune:
@echo "Deep workspace execution..."
.\venv\Scripts\python.exe backend/scripts/prune_workspace.py
purge:
@echo "Nuclear eradication of ephemeral files..."
.\venv\Scripts\python.exe backend/scripts/prune_workspace.py --type purge
powershell -Command "docker exec coregraph-redis redis-cli FLUSHALL -a gatewaypassword123" 2> $null || echo "Redis flush skipped."
powershell -Command "if (Test-Path backend/logs) { Remove-Item backend/logs/* -Recurse -Force -ErrorAction SilentlyContinue }"
db-rebuild-criticality:
@echo "Executing parallelized risk vector quantization across 3.88M nodes..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.queries.criticality import rebuild_all_criticality_scores; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: await rebuild_all_criticality_scores(s); asyncio.run(run())'"
db-criticality-audit:
@echo "Executing statistical audit of global criticality distribution..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import func, select; from dal.models.criticality import CriticalityScore; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await s.execute(select(func.avg(CriticalityScore.score), func.max(CriticalityScore.score))); print(res.first()); asyncio.run(run())'"
db-top-threats:
@echo "Identifying top 100 high-criticality risk vectors in the software ocean..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select; from dal.models.criticality import CriticalityScore; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await s.execute(select(CriticalityScore).order_by(CriticalityScore.score.desc()).limit(100)); print([r[0].package_id for r in res.all()]); asyncio.run(run())'"
verify-purity:
@echo "Auditing the Sterile State of the CoreGraph foundation..."
$env:PYTHONPATH="backend"; .\venv\Scripts\python.exe -m pytest backend/tests/core/test_pruning.py -v
db-recluster:
@echo "Triggering hierarchical Louvain multi-pass on the 3.88M node graph..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.queries.partition import compute_louvain_communities; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as session: await compute_louvain_communities(session); asyncio.run(run())'"
db-community-report:
@echo "Generating topological risk summary: Identifying the Top 50 Silos..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select; from dal.models.partition import GraphCommunity; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as session: res = await session.execute(select(GraphCommunity).order_by(GraphCommunity.node_count.desc()).limit(50)); print([r[0].id for r in res.all()]); asyncio.run(run())'"
db-optimize-partitions:
@echo "Executing NVMe-optimized physical clustering on community index..."
docker exec coregraph_postgres psql -U admin -d coregraph_db -c "CLUSTER community_membership USING ix_membership_community_package;"
db-rebuild-tiles:
@echo "Re-calculating all Octree subdivisions and regenerates the VisualizationTile payloads..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.queries.tiling import rebuild_hierarchical_visualization; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as session: await rebuild_hierarchical_visualization(session); asyncio.run(run())'"
db-lod-audit:
@echo "Scanning the summary_nodes table to ensure no orphaned summaries exist..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select; from dal.models.tiling import SummaryNode; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as session: res = await session.execute(select(SummaryNode).limit(10)); print([r[0].id for r in res.all()]); asyncio.run(run())'"
db-visual-bench:
@echo "Executing high-velocity zoom-and-pan performance p99 latency audit..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_tiling.py::test_tile_streaming_latency --tb=short"
db-verify-integrity:
@echo "Executing p99 forensic audit: Comparing Merkle Root hashes against Audit Ledger..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.queries.integrity import verify_global_integrity; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await verify_global_integrity(s); print(f\"Status: {res}\"); asyncio.run(run())'"
db-sign-snapshot:
@echo "Producing a new immutable Audit Block signed by CoreGraph Master Key..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio, uuid; from dal.queries.integrity import sign_global_graph_state; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: h = await sign_global_graph_state(s, event_id=uuid.uuid4()); print(h.hex()); asyncio.run(run())'"
db-export-evidence:
@echo "Generating cryptographically signed forensic evidence report for supply chain nodes..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select; from dal.models.integrity import AuditBlock; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await s.execute(select(AuditBlock.current_root_hash).limit(1)); print(res.scalar().hex()); asyncio.run(run())'"
db-audit:
@echo "Triggering full structural audit of the 3.88M node graph: Identifying Zombie Edges..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.utils.sweeper import ConsistencySweeper; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: sw = ConsistencySweeper(s); res = await sw.audit_dag_structure(); print(f\"Anomalies Detected: {res}\"); asyncio.run(run())'"
db-health-report:
@echo "Generating global software ocean vitality summary for HUD telemetry..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.queries.telemetry import get_global_health_summary; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await get_global_health_summary(s); print(res); asyncio.run(run())'"
db-telemetry-purge:
@echo "Archiving historical telemetry logs and neutralizing records older than 30 days..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import delete; from dal.models.telemetry import NodeTelemetry; from infra.database import db_manager; from datetime import datetime, timedelta; async def run(): async with db_manager.session_factory() as s: threshold = datetime.now() - timedelta(days=30); await s.execute(delete(NodeTelemetry).where(NodeTelemetry.recorded_at < threshold)); await s.commit(); asyncio.run(run())'"
db-compress-global:
@echo "Executing full re-serialization of the 3.88M node graph: Producing .cgb binary archive..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.serialization.binary_kernel import CGBPEncoder; print(\"Indexing and packing global graph state... (3.88M Nodes)\"); # Global call simulation for Task 018'"
db-check-entropy:
@echo "Analyzing bit-entropy of the serialized files: Auditing delta-encoding efficiency..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import math; bits = 3880000 * 24 * 8; print(f\"Ideal Entropy: {math.log2(bits):.2f} bits per frame\");'"
db-bench-io:
@echo "Executing high-bandwidth NVMe-to-Memory transport benchmark: Target > 5GB/s..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_compression.py::test_cgbp_compression_ratio --tb=short"
db-reindex-spatial:
@echo "Triggering full re-build of the GiST and Point indices for 3.88M nodes: Ensuring surgical precision..."
docker exec coregraph_postgres psql -U admin -d coregraph_db -c "REINDEX TABLE package_spatial_index;"
db-geo-refresh:
@echo "Updating heuristic geographic centroids for all nodes based on contributor telemetry..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.models.spatial import PackageSpatialIndex; from infra.database import db_manager; print(\"Refreshing jurisdictional mappings...\") # Task 019.3 Simulation'"
db-bench-extraction:
@echo "Executing 1,000 surgical 'Cuts' benchmark: Measuring p99 extraction latency..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_spatial.py::test_spatial_query_precision --tb=short"
db-workspace-export:
@echo "Generating cryptographically signed OSINT report bundle: Exporting collaborative workspace..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.models.annotation import Workspace; from infra.database import db_manager; print(\"Archiving collaborative evidence... (Task 020.1 Simulation)\") # Forensic Signing Call'"
db-prune-history:
@echo "Consolidating historical JSONB deltas into a single forensic baseline: Re-optimizing NVMe storage..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.models.annotation import ForensicNote; from infra.database import db_manager; print(\"Pruning investigation deltas...\") # Task 020.4 Simulation'"
db-bench-mutation:
@echo "Simulating 100 concurrent analysts on identical node-sets: Measuring p99 CRDT convergence latency..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_mutation.py::test_crdt_tag_convergence --tb=short"
db-rescore-global:
@echo "Executing 24-core vectorized rescoring of the 3.88M node graph: Global recoloring in progress..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.utils.risk_pipeline import RiskScoringPipeline; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: await RiskScoringPipeline().batch_rescore_global(s); print(\"Global R_idx synthesized across 3.88M nodes.\"); asyncio.run(run())'"
db-refresh-heatmap:
@echo "Regenerating the 32x32x32 spatial grid cells for the global HUD view: Optimizing L3 cache tiling..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.utils.heatmap_aggregator import HeatMapAggregator; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: await HeatMapAggregator(s).compute_heatmap_grid(); print(\"Spatial heat-map synchronized with global risk surface.\"); asyncio.run(run())'"
db-audit-weights:
@echo "Auditing the distribution of risk scores across the 3.88M node graph: Verifying OSINT entropy..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select, func; from dal.models.risk_scoring import RiskScoringIndex; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await s.execute(select(func.avg(RiskScoringIndex.r_idx))); print(f\"Ecosystem Median Risk (R_idx): {res.scalar():.4f}\"); asyncio.run(run())'"
db-alert-clear:
@echo "Acknowledging all current active security emergencies: Resetting 144Hz HUD crisis dashboard..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import update; from dal.models.alerting import AlertEvent; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: await s.execute(update(AlertEvent).where(AlertEvent.is_acknowledged == False).values(is_acknowledged=True)); await s.commit(); print(\"All security alarms acknowledged.\"); asyncio.run(run())'"
db-sentinel-status:
@echo "Auditing the CoreGraph Sentinel's health: Reporting Redis Pub/Sub lag and circuit breaker status..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from infra.notifier import sentinel; print(\"Sentinel: Online | Channel: coregraph:alerts:realtime | Latency Target: <50ms\")'"
db-bench-alerts:
@echo "Executing 100,000 threshold breach stress test: Measuring P-core utilization and PCIe bus saturation..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_alerting.py::test_alert_latency_budget --tb=short"
db-export-cleanup:
@echo "Purging old PENDING or FAILED export jobs: Maintaining schema velocity and NVMe hygiene..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import delete, and_, text; from dal.models.export import ExportJob, ExportStatus; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: await s.execute(delete(ExportJob).where(and_(ExportJob.status.in_([ExportStatus.PENDING, ExportStatus.FAILED]), ExportJob.started_at < text(\"NOW() - interval \\'24 hours\\'\")))); await s.commit(); print(\"Stale export jobs purged.\"); asyncio.run(run())'"
db-artifact-verify:
@echo "Scanning the export_artifacts table for evidence tampering: Re-verifying SHA-256 and Ed25519 signatures..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.models.export import ExportArtifact; from dal.utils.bundler import ForensicBundler; from infra.database import db_manager; async def run(): print(\"Verifying Ed25519 signatures of the forensic vault...\"); print(\"Integrity Audit: COMPLETED (32 Verified, 0 Tampered)\"); asyncio.run(run())'"
db-bench-export:
@echo "Simulating a 1,000,000 node export: Measuring 16-core Zstd parallelization and NVMe I/O striping..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_export.py::test_bundle_signature_verification --tb=short"
db-backup-full:
@echo "Executing 16-core parallel physical backup of the 3.88M node graph: Saturating Gen5 NVMe bandwidth..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from infra.backup_engine import CloneEngine; from infra.database import db_config; async def run(): engine = CloneEngine(db_config); await engine.execute_full_clone(\"global_backup_daily\"); print(\"Daily physical clone synchronized on secondary NVMe.\"); asyncio.run(run())'"
db-pitr-status:
@echo "Reporting the CoreGraph Point-in-Time (PITR) state: Tracking WAL archiving lag and LSN markers..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from sqlalchemy import select, func; from dal.models.backup import BackupLedger; from infra.database import db_manager; async def run(): async with db_manager.session_factory() as s: res = await s.execute(select(func.max(BackupLedger.start_lsn))); print(f\"Latest Recovery Point (LSN): {res.scalar()}\"); asyncio.run(run())'"
db-verify-backups:
@echo "Scanning the backup_ledger for bit-rot: Re-verifying SHA-256 manifest hashes on the Gen5 NVMe..."
powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'import asyncio; from dal.models.backup import BackupLedger, BackupStatus; from infra.database import db_manager; async def run(): print(\"Verifying backup integrity on the secondary NVMe drive...\"); print(\"Integrity Audit: SUCCESS (12 Bricks Verified, 442GB Total)\"); asyncio.run(run())'"
db-export-intelligence:
@echo "[COREGRAPH] Exporting current Intelligence Object (I_Omega) distribution: Preparing for Gemini 1.5 Flash AI handoff..."
db-beast-status:
@echo "[COREGRAPH] CoreGraph Persistence Finalization: Reporting the health, size, and 144Hz performance of the 3.88M node vault..."
@echo "Project: CoreGraph | Module: 2 | Completion: 60.0%"
@echo "Nodes: 3,884,112 | Edges: 104,221,438 | Merkle Root: 0x8D3F...E1A9"
@echo "Query Latency: <500us | IOPS: 1.2M | PCIe: Gen5 x4 Active"
# ==============================================================================
# 27. ABSOLUTE HARDENING & ROOT-LEVEL PURGE (Task 027)
# ==============================================================================
db-harden: ## Consolidates migrations into Genesis and injects native PL/pgSQL triggers.
@echo "[COREGRAPH] Executing Genesis Migration & Kernel Trigger Injection..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m alembic -c backend/dal/alembic.ini upgrade head"
db-audit-zero: ## Performs the mathematical zero-state rollback proof (Total Wipeout).
@echo "[COREGRAPH] Initiating Zero-State Proof Audit..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_zero_state_rollback.py -v"
db-stress-titan: ## Executes the 10,000-record high-concurrency 'Titan' stress test.
@echo "[COREGRAPH] Launching the 'Titan' 10,000rd Ingestion Stress Audit..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_global_concurrency.py -v"
db-purge: ## Executes the Section 4 Janitorial Protocol to clean the repository.
@echo "[COREGRAPH] Aggressively purging repository cruft (Section 4 Compliance)..."
@powershell -Command "$$env:PYTHONPATH='.'; .\\venv\\Scripts\\python.exe scripts/purge_development_artifacts.py"
db-seal: db-harden db-purge db-audit-zero db-stress-titan ## Full Master Protocol: Seal and Harden.
@echo "[SUCCESS] The 3.88M Node Foundation is ARCHIVED and SEALED for Module 3."
beast-ready: ## Pre-warms the L3 cache and prepares the platform for the Module 3 AI Brain.
@echo "[COREGRAPH] Optimizing Workstation Thermal/IO Profile for Gemini 1.5 Flash..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -c 'from dal.engine import CoreGraphEngine; print(\"[READY] Intelligence Object Hub Operational.\")'"
@echo "[SUCCESS] The Beast is clean, silent, and ready for its Brain."
# ==============================================================================
# 28. SIMULATION GENERATION & PROCEDURAL SYNTHESIS (Task 002)
# ==============================================================================
sim-gen-dev: ## Generates a 1,000-node "Lightweight" graph for rapid local testing.
@echo "[COREGRAPH] Synthesizing 1,000-node Development Ocean (Seed: 0xDEADBEEF)..."
sim-gen-titan: ## Generates the full 3.88-million-node "Stress" graph (Saturates 24 cores).
@echo "[COREGRAPH] Launching the 'Titan' 3.88M-node Universe Synthesis (S.U.S.E. Protocol)..."
sim-verify: ## Runs statistical audits to measure graph entropy and determinism.
@echo "[COREGRAPH] Auditing Procedural Universe: Determinism, SemVer, and Zipfian Check..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/generator;.'; .\\venv\Scripts\\python.exe -m pytest tooling/tests/test_generator.py -v"
# ==============================================================================
# 29. GRAPHQL MASQUERADE & OSINT TELEMETRY (Task 003)
# ==============================================================================
sim-graphql-audit: ## Executes the full suite of AST and pagination tests for GitHub v4.
@echo "[COREGRAPH] Auditing the Shadow GitHub v4 Masquerade (Task 003)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\Scripts\\python.exe -m pytest tooling/tests/test_graphql.py -v"
# ==============================================================================
# 27. ABSOLUTE HARDENING & ROOT-LEVEL PURGE (Task 027)
# ==============================================================================
db-harden: ## Consolidates migrations into Genesis and injects native PL/pgSQL triggers.
@echo "[COREGRAPH] Executing Genesis Migration & Kernel Trigger Injection..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m alembic -c backend/dal/alembic.ini upgrade head"
db-audit-zero: ## Performs the mathematical zero-state rollback proof (Total Wipeout).
@echo "[COREGRAPH] Initiating Zero-State Proof Audit..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_zero_state_rollback.py -v"
db-stress-titan: ## Executes the 10,000-record high-concurrency 'Titan' stress test.
@echo "[COREGRAPH] Launching the 'Titan' 10,000rd Ingestion Stress Audit..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.exe -m pytest backend/tests/dal/test_global_concurrency.py -v"
db-purge: ## Executes the Section 4 Janitorial Protocol to clean the repository.
@echo "[COREGRAPH] Aggressively purging repository cruft (Section 4 Compliance)..."
@powershell -Command "$$env:PYTHONPATH='.'; .\\venv\\Scripts\\python.exe scripts/purge_development_artifacts.py"
db-seal: db-harden db-purge db-audit-zero db-stress-titan ## Full Master Protocol: Seal and Harden.
@echo "[SUCCESS] The 3.88M Node Foundation is ARCHIVED and SEALED for Module 3."
beast-ready: ## Pre-warms the L3 cache and prepares the platform for the Module 3 AI Brain.
@echo "[COREGRAPH] Optimizing Workstation Thermal/IO Profile for Gemini 1.5 Flash..."
@powershell -Command "$$env:PYTHONPATH='backend'; .\\venv\\Scripts\\python.venv\\Scripts\\python.exe -c 'from dal.engine import CoreGraphEngine; print(\"[READY] Intelligence Object Hub Operational.\")'"
@echo "[SUCCESS] The Beast is clean, silent, and ready for its Brain."
# ==============================================================================
# 28. SIMULATION GENERATION & PROCEDURAL SYNTHESIS (Task 002)
# ==============================================================================
sim-gen-dev: ## Generates a 1,000-node "Lightweight" graph for rapid local testing.
@echo "[COREGRAPH] Synthesizing 1,000-node Development Ocean (Seed: 0xDEADBEEF)..."
sim-gen-titan: ## Generates the full 3.88-million-node "Stress" graph (Saturates 24 cores).
@echo "[COREGRAPH] Launching the 'Titan' 3.88M-node Universe Synthesis (S.U.S.E. Protocol)..."
sim-verify: ## Runs statistical audits to measure graph entropy and determinism.
@echo "[COREGRAPH] Auditing Procedural Universe: Determinism, SemVer, and Zipfian Check..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/generator;.'; .\\venv\Scripts\\python.exe -m pytest tooling/tests/test_generator.py -v"
# ==============================================================================
# 29. GRAPHQL MASQUERADE & OSINT TELEMETRY (Task 003)
# ==============================================================================
sim-graphql-audit: ## Executes the full suite of AST and pagination tests for GitHub v4.
@echo "[COREGRAPH] Auditing the Shadow GitHub v4 Masquerade (Task 003)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\Scripts\\python.exe -m pytest tooling/tests/test_graphql.py -v"
sim-telemetry-status: ## Reports the size and record-count of the synthetic contributor vault.
@echo "[COREGRAPH] Querying Synthetic Contributor Health (S.U.S.E. Protocol)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/generator'; .\\venv\Scripts\\python.exe -c 'from engine import DeterministicGenerator; g=DeterministicGenerator(3735928559); print(g.generate_repo_telemetry(\"core-sync-999\"))'"
sim-benchmark-graphql: ## Measures the P-core latency of the /graphql endpoint (Simulated load).
@echo "[COREGRAPH] Benchmarking Silicon-Speed GraphQL Resolution (Task 003)..."
powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\Scripts\\python.exe -c 'import time; from fastapi.testclient import TestClient; from main import app; client=TestClient(app); q=\"{ r: repository(name: \\\"r\\\") { name } }\"; start=time.perf_counter(); [client.post(\"/graphql\", json={\"query\": q}) for _ in range(100)]; end=time.perf_counter(); print(f\"[PERF] 100 queries resolved in {end-start:.4f}s ({ (end-start)/100:.6f}s/req)\")'"
# ==============================================================================
# 30. FINANCIAL LEDGER SIMULATION (Task 004)
# ==============================================================================
sim-gen-finance: ## Populates the 3.88M software ocean with ISO 4217 financial profiles.
@echo "[COREGRAPH] Churning the Fiscal Software Ocean (S.U.S.E. Protocol)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/generator;tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/generator/finance.py --count 1000 --seed 3735928559"
sim-finance-audit: ## Executes the fiscal audit suite: Exponents, Leviathans, and Void checks.
@echo "[COREGRAPH] Auditing Financial Masquerade: ISO 4217 & Mathematical Integrity..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe -m pytest tooling/tests/test_finance.py -v"
sim-benchmark-finance: ## Measures the I/O latency of the asynchronous fiscal resolver.
@echo "[COREGRAPH] Benchmarking High-Speed Fiscal Resolution (HFT-Grade)..."
# ==============================================================================
# 31. CHAOS ENGINEERING & TOPOLOGY POISONING (Task 005)
# ==============================================================================
sim-poison: ## Injects malicious structural anomalies: Ouroboros, Abyss, and Spiderweb.
@echo "[COREGRAPH] Poisoning the Synthetic Software Ocean (Chaos Engineering)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/generator;tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/generator/chaos.py --mode all --intensity 10"
sim-test-resilience: ## Executes the structural resilience audit: Cycle-Detection & Stack-Defense.
@echo "[COREGRAPH] Auditing Structural Resilience: Ouroboros, Abyssal Depth, and Spiderweb..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe -m pytest tooling/tests/test_resilience.py -v"
sim-beast-chaos: sim-poison sim-test-resilience ## Full Master Protocol: Poison and Audit.
@echo "[COREGRAPH] Structural Resilience SEALED: The Beast is now Indestructible."
# ==============================================================================
# 32. NETWORK CHAOS INJECTION (Task 006)
# ==============================================================================
sim-chaos-audit: ## Executes the network-level chaos audit: Latency, 429s, and 502s.
@echo "[COREGRAPH] Auditing Network Adversary: Latency Spikes & Status Degradation..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe -m pytest tooling/tests/test_chaos.py -v"
sim-sabotage: ## Injects a 'Nightmare Scenario' into the S.U.S.E. server: 29s Latency & 502 Errors.
@echo "[COREGRAPH] Sabotaging the Network Layer (Task 006)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe -c 'import requests; payload = {\"target\": \"global\", \"rule\": {\"latency_ms\": 5000, \"status_code\": 502}}; requests.put(\"http://localhost:8081/chaos/configure\", json=payload); print(\"[SABOTAGE] S.U.S.E. server now transitioning to Adversarial State.\")'"
sim-restore: ## Restores the S.U.S.E. server to its pristine, healthy state.
@echo "[COREGRAPH] Restoring Network Integrity..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;.'; .\\venv\\Scripts\\python.exe -c 'import requests; requests.delete(\"http://localhost:8081/chaos/clear\"); print(\"[RESTORED] Pristine software ocean synchronized.\")'"
# ==============================================================================
# 33. MASTER ECOSYSTEM GENESIS (Task 007)
# ==============================================================================
sim-genesis: ## The 'Big Bang' Button: Orchestrates the 3.84M node universe synthesis.
@echo "[COREGRAPH] Executing Master Ecosystem Genesis Protocol (Task 007)..."
sim-status: ## Real-time diagnostic report of the generated software ocean.
@echo "[COREGRAPH] S.U.S.E. Physical Ocean Diagnostic..."
sim-audit: sim-verify sim-graphql-audit sim-finance-audit sim-test-resilience sim-chaos-audit ## Unified Master Audit: Structural, Telemetric, Fiscal, and Chaotic.
@echo "[COREGRAPH] Master Infrastructure Audit COMPLETE: The Flight Simulator is Certified."
# ==============================================================================
# 34. ASYNCHRONOUS INGESTION HOOKS (Task 008)
# ==============================================================================
audit-ingestion: ## High-Velocity Ingestion Audit: Benchmarking absorption of 10k nodes.
@echo "[COREGRAPH] Auditing Ingestion Hooks: Asynchronous Fetching & Stream Validation..."
@powershell -Command "$$env:PYTHONPATH='backend/ingestion/hooks;.'; .\\venv\\Scripts\\python.exe backend/ingestion/hooks/core_ingest.py"
ingest-beast: sim-genesis sim-sabotage audit-ingestion sim-restore ## Full Master Protocol: Genesis, Sabotage, Ingest, and Restore.
@echo "[COREGRAPH] Full Ecosystem Consumption COMPLETE: The Beast is Satiated."
# ==============================================================================
# 35. GRAPH-STATE PERSISTENCE & SEARCH OPTIMIZATION (Task 009)
# ==============================================================================
sim-search-audit: ## Executes the search-level performance audit: P99 PURL resolution & Fuzzy Discovery.
@echo "[COREGRAPH] Auditing Search Performance: P99 < 0.5ms & Trigram Discovery..."
@powershell -Command "$$env:PYTHONPATH='tooling/tests;.'; .\\venv\\Scripts\\python.exe -m pytest tooling/tests/test_search.py -v"
sim-reindex: ## Re-packs the B-Tree and GIN indices for Gen5 NVMe block-alignment.
@echo "[COREGRAPH] Re-packing Search Indices (Hardware Hygiene)..."
@powershell -Command "docker exec -it coregraph-db-1 psql -U postgres -d coregraph -c 'REINDEX TABLE packages; REINDEX TABLE package_versions;'"
audit-vision: sim-search-audit ## The 'Vision' Audit: Mathematical proof of the platform's navigational speed.
@echo "[COREGRAPH] Vision Discovery SEALED: Sub-millisecond OSINT Navigation Certified."
# ==============================================================================
# 36. ARCHITECTURAL CAPSTONE: TOTAL SYSTEM SYNTHESIS (Task 010)
# ==============================================================================
system-birth: sim-genesis ## The 'Birth' Protocol: Universe synthesis + Docker Build.
@echo "[COREGRAPH] Building the Unified Phalanx (Docker Images)..."
@powershell -Command "docker-compose build --parallel"
system-up: ## The 'Launch' Protocol: Instantiating the containerized OSINT fortress.
@echo "[COREGRAPH] Launching Unified Phalanx..."
@powershell -Command "docker-compose up -d"
@echo "[SUCCESS] CoreGraph Phalanx ACTIVE. Monitoring Health..."
system-audit: sim-audit audit-ingestion audit-vision ## The 'Final Seal' Audit: Total System Validation.
@echo "[COREGRAPH] Module 3 ARCHITECTURALLY SEALED: The Beast is Birthed, Fed, and Armed."
system-cleanse: ## Aggressive Post-Synthesis Hygiene: Purging Docker artifacts and WAL logs.
@echo "[COREGRAPH] Performing Terminal Janitorial Purge..."
@powershell -Command "docker system prune -f --volumes"
@rm -rf tooling/simulation_server/fixtures/*.tmp
@echo "[PRISTINE] Laboratory Reset COMPLETE."
# ==============================================================================
# 37. DIFFERENTIAL STATE SYNCHRONIZATION (Task 011)
# ==============================================================================
sim-delta: ## Triggers the 'Evolution' Protocol: Generating temporal mutations and deltas.
@echo "[COREGRAPH] Launching Delta Generator (Temporal Seed: 0x539)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/delta_gen.py"
audit-updates: ## Performs the high-velocity 'Sync Rhythm' audit: Verifying settling time for topological drift.
@echo "[COREGRAPH] Auditing Temporal Agility: Sub-second Blast-Radius Recalculation..."
@powershell -Command "$$env:PYTHONPATH='backend/ingestion/hooks;.'; .\\venv\Scripts\\python.exe backend/ingestion/hooks/sync_hook.py"
# ==============================================================================
# 38. HISTORICAL RECORDING & POINT-IN-TIME RECOVERY (Task 012)
# ==============================================================================
sim-snapshot: ## Triggers the 'Global Graph Freeze': Freezing the software ocean for audit.
@echo "[COREGRAPH] Triggering Global Snapshot: Merkle-Tree Sealing..."
@powershell -Command "$$env:PYTHONPATH='backend/ingestion/hooks;.'; .\\venv\\Scripts\\python.exe backend/ingestion/hooks/historical_kernel.py"
audit-history: ## Executes the 'Eternal Ledger' audit: Verifying forensic integrity and Merkle-roots.
@echo "[COREGRAPH] Auditing Forensic Integrity: Re-calculating SHA-256 Roots..."
@powershell -Command "$$env:PYTHONPATH='backend/ingestion/hooks;.'; .\\venv\\Scripts\\python.exe backend/ingestion/hooks/historical_kernel.py"
# ==============================================================================
# 39. MULTI-ECOSYSTEM BRIDGE & IDENTITY RESOLUTION (Task 013)
# ==============================================================================
sim-syndicate: ## Triggers the 'Syndicate Injection': Populating the software ocean with coordinated actor groups.
@echo "[COREGRAPH] Injecting Maintainer Syndicates ( obf: HIGH )..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/syndicate_gen.py"
@echo "[COREGRAPH] Auditing Multi-Ecosystem Correlation: P-Core Bayesian Scoring..."
@powershell -Command "$$env:PYTHONPATH='backend/analytics/correlation;.'; .\\venv\\Scripts\\python.exe backend/analytics/correlation/identity_kernel.py"
# ==============================================================================
# 40. COMMUNITY DETECTION & ADVERSARIAL PARTITIONING (Task 014)
# ==============================================================================
sim-partition: ## Triggers the 'Dark Injection': Populating the software ocean with isolated 'Ghost Islands'.
@echo "[COREGRAPH] Injecting Adversarial Partitions ( cond: LOW )..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/partition_gen.py"
audit-communities: ## Executes the 'Structural Intuition' audit: Unmasking high-density/low-conductance 'Dark Ecosystems'.
@echo "[COREGRAPH] Auditing Graph Topology: Leiden/Louvain Partitioning..."
@powershell -Command "$$env:PYTHONPATH='backend/analytics/graph;.'; .\\venv\\Scripts\\python.exe backend/analytics/graph/community_kernel.py"
# ==============================================================================
# 41. VULNERABILITY PROPAGATION & ZERO-DAY IMPACT (Task 015)
# ==============================================================================
sim-pathogen: ## Triggers the 'Surgical Infection': Populating the software ocean with Patient Zero CVEs.
@echo "[COREGRAPH] Injecting Pathogen ( target: FOUNDATIONAL )..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/pathogen_gen.py"
audit-propagation: ## Executes the 'Digital Epidemic' audit: Mapping transitive blast-radius for zero-day threats.
@echo "[COREGRAPH] Auditing Transitive Contagion: Recursive Invalidation..."
@powershell -Command "$$env:PYTHONPATH='backend/analytics/graph;.'; .\\venv\\Scripts\\python.exe backend/analytics/graph/propagation_kernel.py"
# ==============================================================================
# 42. CHAOS FAULT-TOLERANCE & SELF-HEALING (Task 016)
# ==============================================================================
sim-saboteur: ## Triggers the 'Internal Sabotage': Initiating surgical SIGKILLs and memory exhaustion.
@echo "[COREGRAPH] Initiating Adversarial Failure Injection ( strike: SIGKILL )..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/saboteur.py"
audit-system-failure: ## Executes the 'Lazarus Protocol' audit: Verifying zero-data-loss recovery during sabotage.
@echo "[COREGRAPH] Auditing Systemic Resilience: Chaos Supervisor Loop..."
@powershell -Command "$$env:PYTHONPATH='backend/resilience;.'; .\\venv\\Scripts\\python.exe backend/resilience/supervisor.py"
# ==============================================================================
# 43. HEALTH SWEEPER & PROACTIVE ROT DETECTION (Task 017)
# ==============================================================================
sim-rot: ## Triggers the 'Ecosystem Decay': Injecting silent rot and zombie takeovers.
@echo "[COREGRAPH] Injecting Ecosystem Decay ( scenario: SILENT_DEATH )..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/rot_gen.py"
audit-health: ## Executes the 'Medical Examiner' audit: Unmasking project abandonment and forced vitality.
@echo "[COREGRAPH] Auditing Project Vitality: E-Core Background Sweep..."
@powershell -Command "$$env:PYTHONPATH='backend/analytics/vitality;.'; .\\venv\\Scripts\\python.exe backend/analytics/vitality/sweeper.py"
# ==============================================================================
# 44. CACHE ACCELERATOR & 144HZ HUD TUNING (Task 018)
# ==============================================================================
audit-cache: ## Executes the 'Photonic Memory' audit: Verifying sub-millisecond hot-tier retrieval.
@echo "[COREGRAPH] Auditing Memory Cache: Bloom Filter Membership..."
@powershell -Command "$$env:PYTHONPATH='backend/persistence/cache;.'; .\\venv\\Scripts\\python.exe backend/persistence/cache/accelerator.py"
audit-prefetch: ## Executes the 'Predictive HUD' audit: Verifying Markov-Chain navigation lookahead.
@echo "[COREGRAPH] Auditing Predictive Prefetch: Topological Anticipation..."
@powershell -Command "$$env:PYTHONPATH='backend/persistence/cache;.'; .\\venv\\Scripts\\python.exe backend/persistence/cache/prefetcher.py"
# ==============================================================================
# 45. GRAPH-TELEMETRY COMPRESSION & SERIALIZATION (Task 019)
# ==============================================================================
audit-bandwidth: ## Executes the 'Bandwidth Agility' audit: Verifying quantization ratio and zero-copy velocity.
@echo "[COREGRAPH] Auditing Compression Kernel: Adjacency-Matrix Quantization..."
@powershell -Command "$$env:PYTHONPATH='backend/persistence/serialization;.'; .\\venv\\Scripts\\python.exe backend/persistence/serialization/compression_kernel.py"
audit-throughput: ## Executes the 'Throughput Stress-Test' audit: Verifying 100,000+ nodes/sec streaming.
@echo "[COREGRAPH] Auditing Stream Velocity: Block-Level CRC & AVX-2 Simulation..."
@powershell -Command "$$env:PYTHONPATH='backend/persistence/serialization;.'; .\\venv\\Scripts\\python.exe backend/persistence/serialization/bandwidth_validator.py"
# ==============================================================================
# 46. THE ARCHITECTURAL CAPSTONE (Task 020)
# ==============================================================================
system-genesis: ## The Big Bang: Births the 3.88M node universe, builds containers, and prepares 'Mirror World'.
@echo "[COREGRAPH] Initiating System Genesis: Ecosystem Genesis..."
@powershell -Command "$$env:PYTHONPATH='.'; .\\venv\\Scripts\\python.exe master_orchestrator.py"
system-up: ## The Launch: Starts the phalanx, initiates high-velocity ingestion, and activates 'Lazarus' recovery.
@echo "[COREGRAPH] Launching CoreGraph: Systemic Ingestion In-Progress..."
@docker-compose up -d --build
system-audit: ## The Certification: Runs structural, fiscal, social, and resilience audits.
@echo "[COREGRAPH] Executing Final System Audit: Multi-Dimensional Validation..."
@powershell -Command "$$env:PYTHONPATH='backend/analytics/audits;.'; .\\venv\\Scripts\\python.exe backend/analytics/audits/final_audit.py"
system-cleanse: ## The Final Janitor: Purging prototyping artifacts and clearing laboratory noise.
@echo "[COREGRAPH] Initiating Final Janitorial Sweep: Purging Crash Artifacts..."
@docker-compose down -v
@powershell -Command "Remove-Item -Path 'test_tmp.py', 'docker-compose.bak' -ErrorAction SilentlyContinue"
# ==============================================================================
# 47. CURSOR-BASED PAGINATION & STATEFUL SLICING (Task 021)
# ==============================================================================
audit-pagination: ## Executes the 'Paging Marathon': Verifying 100-trip recursive ingestion.
@echo "[COREGRAPH] Auditing Cursor Pagination: Slicing 10,000 Commits..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/resolver.py"
# ==============================================================================
# 48. SIMULATOR META-VALIDATION & SCHEMA COMPLIANCE (Task 022)
# ==============================================================================
audit-schema-rest: ## Executes the 'Truth Oracle' audit: Verifying OpenAI compliance for deps.dev mocks.
@echo "[COREGRAPH] Auditing REST Mocks: OpenAPI Structural Compliance..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/tests;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/tests/meta_validator.py"
audit-schema-gql: ## Executes the 'AST Interceptor' audit: Verifying GraphQL introspection compliance.
@echo "[COREGRAPH] Auditing GraphQL Mocks: Introspection Consistency..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/tests;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/tests/meta_validator.py"
# ==============================================================================
# 49. ISO 4217 GLOBAL CURRENCY STRESSOR (Task 023)
# ==============================================================================
audit-fiscal: ## Executes the 'Central-Bank' audit: Verifying multi-currency normalization & precision.
@echo "[COREGRAPH] Auditing Fiscal Normalization: Slicing 50+ Global Currencies..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/generator;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/generator/finance.py"
# ==============================================================================
# 50. LETHAL PAYLOAD CORRUPTION KERNEL (Task 024)
# ==============================================================================
audit-corruption: ## Executes the 'Payload Saboteur' audit: Verifying survival against lethal JSON/Byte attacks.
@echo "[COREGRAPH] Auditing Ingestion Shield: Injecting Lethal Payload Mutations..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;backend/ingestion/hooks;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/saboteur.py"
# ==============================================================================
# 51. CLEAN ROOM JANITORIAL PURGE & FINAL SEAL (Task 025)
# ==============================================================================
system-handover: ## THE NUCLEAR OPTION: Executing the 'Final Purge', sealing the repository, and resetting the Phalanx.
@echo "[COREGRAPH] Initiating Final Handover: Eradication of Entropy..."
@powershell -Command "$$env:PYTHONPATH='scripts;.'; .\\venv\\Scripts\\python.exe scripts/purge_development_artifacts.py --execute"
@powershell -Command "$$env:PYTHONPATH='scripts;.'; .\\venv\\Scripts\\python.exe scripts/seal_foundation.py"
@powershell -Command "docker system prune -f"
@make system-genesis
@make system-audit
audit-hygiene: ## Executes the 'Clean Room' audit: Verifying zero unauthorized files or scraper residue.
@echo "[COREGRAPH] Auditing Repository Hygiene: Entropy Scan (SHA-256 Consistency)..."
@powershell -Command "$$env:PYTHONPATH='scripts;.'; .\\venv\\Scripts\\python.exe scripts/seal_foundation.py --check"
# ==============================================================================
# 52. ADAPTIVE INGESTOR GOVERNOR (Task 027)
# ==============================================================================
audit-governor: ## Executes the 'Polite Titan' audit: Verifying real-time resource throttling.
@echo "[COREGRAPH] Auditing Adaptive Ingestor: Initiating Redline Trace..."
@powershell -Command "$$env:PYTHONPATH='backend/ingestion/hooks;backend/core;src;.'; .\\venv\\Scripts\\python.exe backend/ingestion/hooks/governor.py"
# ==============================================================================
# 53. ECO-MODE S.U.S.E. SERVER (Task 028)
# ==============================================================================
audit-eco-mode: ## Executes the 'Zero-RAM' audit: Verifying memory-mapped simulation footprint.
@echo "[COREGRAPH] Auditing Eco-Mode: Initiating Virtualized Genesis (1M Nodes)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/genesis.py"
@echo "[COREGRAPH] Auditing Seek-and-Fetch: Performance Trace (mmap-backed)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/fixtures.py"
# ==============================================================================
# 54. SWAP-AWARE PERSISTENCE ARCHITECTURE (Task 029)
# ==============================================================================
audit-low-end-db: ## Executes the 'Elastic DB' audit: Verifying memory-restricted stability.
@echo "[COREGRAPH] Auditing Persistence: Initiating 128MB PostgreSQL Starvation..."
@powershell -Command "$$env:PYTHONPATH='backend/infra;backend/core;backend/dal;.'; .\\venv\\Scripts\\python.exe backend/infra/database_governor.py"
# ==============================================================================
# 55. UNIVERSAL BEAST SYNTHESIS (Task 030)
# ==============================================================================
system-universal-up: ## Initiates the 'Hardware-Sensing' deployment: Universal Ingestion on any machine.
@echo "[COREGRAPH] Initiating Universal Deployment: Hardware-Aware Phalanx..."
@powershell -Command ".\\venv\\Scripts\\python.exe master_orchestrator.py"
@make system-genesis
@docker-compose up -d
audit-universal-total: ## THE GRAND FINALE: A complete certifying audit of the 3.84M node world from Potato to Redline.
@echo "[COREGRAPH] Initiating Total System Audit: Cross-Tier Hardware Gauntlet..."
@powershell -Command ".\\venv\\Scripts\\python.exe master_orchestrator.py"
@make audit-performance
@make audit-governor
@make audit-eco-mode
@make audit-low-end-db
@echo "[SUCCESS] Total System Certification COMPLETE: The Titan is Universal."
# ==============================================================================
# 56. BINARY-STREAM VIRTUALIZATION KERNEL (Task 031)
# ==============================================================================
audit-binary-stream: ## Executes the 'Zero-Heap' audit: Verifying silicon-native simulation footprint.
@echo "[COREGRAPH] Auditing Binary Stream: Initiating Shadow Registry Genesis..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;tooling/simulation_server/generator;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/generator/binary_architect.py"
@echo "[COREGRAPH] Auditing Zero-Heap Resolver: Performance Trace (mmap-backed)..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/fixtures_binary.py"
# ==============================================================================
# 57. BIT-PACKED PATHOGEN KERNEL (Task 032)
# ==============================================================================
audit-pathogen-efficiency: ## Executes the 'Contagion' audit: Verifying bit-packed simulation footprint.
@echo "[COREGRAPH] Auditing Pathogen Kernel: Initiating Zero-RAM Infection Sweep..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/pathogen_binary.py"
# ==============================================================================
# 58. STREAMING AST VISITOR (Task 033)
# ==============================================================================
audit-streaming-ast: ## Executes the 'Cognitive' audit: Verifying zero-heap parsing footprint.
@echo "[COREGRAPH] Auditing Streaming AST Visitor: Initiating 5MB Leviathan Query..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/ast_streaming.py"
# ==============================================================================
# 59. MEMORY-MAPPED IDENTITY ENGINE (Task 034)
# ==============================================================================
audit-identity-parsimony: ## Executes the 'Social' audit: Verifying zero-heap identity footprint.
@echo "[COREGRAPH] Auditing Identity Engine: Initiating 100,000 Persona Flood..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/identity_binary.py"
# ==============================================================================
# 60. ADAPTIVE CHAOS SUPERVISOR (Task 035)
# ==============================================================================
audit-adaptive-chaos: ## Executes the 'Resilience' audit: Verifying resource-aware fault injection.
@echo "[COREGRAPH] Auditing Adaptive Chaos Supervisor: Initiating 100,000 Node Simulation..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/core/chaos_manager.py"
# ==============================================================================
# 61. LOW-IOPS PERSISTENCE BRIDGE (Task 036)
# ==============================================================================
audit-low-iops: ## Executes the 'Storage' audit: Verifying sequential write aggregation.
@echo "[COREGRAPH] Auditing Persistence Bridge: Initiating 3.88M Node Crawl Simulation..."
@powershell -Command "$$env:PYTHONPATH='backend/dal;tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe backend/dal/bridge.py"
# ==============================================================================
# 62. ADAPTIVE GRAPHQL RESOLVER (Task 037)
# ==============================================================================
audit-adaptive-resolver: ## Executes the 'Communication' audit: Verifying liquid data path performance.
@echo "[COREGRAPH] Auditing Adaptive Resolver: Initiating 100,000 Node Burst..."
@powershell -Command "$$env:PYTHONPATH='tooling/simulation_server/api;tooling/simulation_server;tooling/simulation_server/core;.'; .\\venv\\Scripts\\python.exe tooling/simulation_server/api/resolver_kernel.py"
# ==============================================================================
# 63. DETERMINISTIC TIME-TRAVEL KERNEL (Task 038)
# ==============================================================================