Skip to content

Commit 7bb8be4

Browse files
authored
Merge branch 'main' into issue/435-578-idempotency-recovery
2 parents cfeefe8 + a14481a commit 7bb8be4

408 files changed

Lines changed: 82961 additions & 829 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.env.example

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# Which of these vars are actually required depends on which entry point
2+
# you're running (the REST API, the streaming pipeline, on-chain submission,
3+
# training, ...). See config/contracts.py for the per-runtime-mode contract,
4+
# and run `make check-env MODE=<mode>` to check your .env against one before
5+
# starting the service.
6+
17
# Stellar Horizon API endpoint used for ingestion.
28
# Default: https://horizon.stellar.org
39
# Optional.

.github/CODEOWNERS

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
# LedgerLens CODEOWNERS
2+
# Each line is a file pattern followed by one or more owners.
3+
# Order matters: later rules override earlier ones for matching files.
4+
# See https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners
5+
6+
# ── Default owners for everything ────────────────────────────────────────────
7+
* @Ledger-Lenz/core-maintainers
8+
9+
# ── Data ingestion pipeline ──────────────────────────────────────────────────
10+
/ingestion/ @Ledger-Lenz/data-team
11+
/ingestion/horizon_streamer.py @Ledger-Lenz/data-team @Ledger-Lenz/infra-team
12+
/ingestion/kafka_producer.py @Ledger-Lenz/data-team @Ledger-Lenz/streaming-team
13+
/ingestion/rate_limiter.py @Ledger-Lenz/infra-team
14+
15+
# ── Detection engine ─────────────────────────────────────────────────────────
16+
/detection/ @Ledger-Lenz/ml-team
17+
/detection/benford_engine.py @Ledger-Lenz/ml-team
18+
/detection/feature_engineering.py @Ledger-Lenz/ml-team
19+
/detection/model_training.py @Ledger-Lenz/ml-team
20+
/detection/model_inference.py @Ledger-Lenz/ml-team
21+
/detection/wallet_graph.py @Ledger-Lenz/ml-team
22+
/detection/gnn_encoder.py @Ledger-Lenz/ml-team
23+
/detection/shap_explainer.py @Ledger-Lenz/ml-team
24+
/detection/differential_privacy.py @Ledger-Lenz/ml-team @Ledger-Lenz/security-team
25+
/detection/adversarial/ @Ledger-Lenz/ml-team @Ledger-Lenz/security-team
26+
/detection/persistence.py @Ledger-Lenz/data-team
27+
/detection/risk_score_store.py @Ledger-Lenz/data-team
28+
29+
# ── Streaming / real-time pipeline ───────────────────────────────────────────
30+
/streaming/ @Ledger-Lenz/streaming-team
31+
/streaming/pipeline.py @Ledger-Lenz/streaming-team
32+
/streaming/kafka_worker.py @Ledger-Lenz/streaming-team @Ledger-Lenz/infra-team
33+
/streaming/ws_server.py @Ledger-Lenz/streaming-team
34+
/streaming/alert_dispatcher.py @Ledger-Lenz/streaming-team
35+
36+
# ── Integrations / smart contracts ───────────────────────────────────────────
37+
/integrations/ @Ledger-Lenz/contract-team
38+
/integrations/contract_client.py @Ledger-Lenz/contract-team
39+
/integrations/soroban/ @Ledger-Lenz/contract-team
40+
/integrations/zk_attestor.py @Ledger-Lenz/contract-team
41+
42+
# ── Monitoring & observability ───────────────────────────────────────────────
43+
/monitoring/ @Ledger-Lenz/infra-team
44+
/monitoring/prometheus.yml @Ledger-Lenz/infra-team
45+
/monitoring/alert_rules.yml @Ledger-Lenz/infra-team
46+
47+
# ── Configuration ────────────────────────────────────────────────────────────
48+
/config.py @Ledger-Lenz/core-maintainers
49+
/config/ @Ledger-Lenz/core-maintainers
50+
/.env.example @Ledger-Lenz/core-maintainers
51+
52+
# ── Reporting ────────────────────────────────────────────────────────────────
53+
/reporting/ @Ledger-Lenz/data-team
54+
/reporting/fatf_exporter.py @Ledger-Lenz/data-team @Ledger-Lenz/compliance-team
55+
56+
# ── Privacy & differential privacy ───────────────────────────────────────────
57+
/privacy/ @Ledger-Lenz/ml-team @Ledger-Lenz/security-team
58+
59+
# ── CI/CD & build ───────────────────────────────────────────────────────────
60+
/.github/ @Ledger-Lenz/core-maintainers
61+
/.github/workflows/ @Ledger-Lenz/infra-team
62+
/Dockerfile @Ledger-Lenz/infra-team
63+
/docker-compose.yml @Ledger-Lenz/infra-team
64+
/Makefile @Ledger-Lenz/core-maintainers
65+
66+
# ── Testing ──────────────────────────────────────────────────────────────────
67+
/tests/ @Ledger-Lenz/core-maintainers
68+
/tests/integration/ @Ledger-Lenz/core-maintainers @Ledger-Lenz/infra-team
69+
/tests/fuzz/ @Ledger-Lenz/ml-team
70+
71+
# ── Scripts ──────────────────────────────────────────────────────────────────
72+
/scripts/ @Ledger-Lenz/core-maintainers
73+
/scripts/stream.py @Ledger-Lenz/streaming-team
74+
/scripts/retrain_if_drifted.py @Ledger-Lenz/ml-team
75+
/scripts/testnet_setup.py @Ledger-Lenz/contract-team
76+
77+
# ── Utilities ────────────────────────────────────────────────────────────────
78+
/utils/ @Ledger-Lenz/core-maintainers
79+
/utils/logging.py @Ledger-Lenz/infra-team
80+
/utils/tracing.py @Ledger-Lenz/infra-team
81+
82+
# ── Models & data artifacts ──────────────────────────────────────────────────
83+
/models/ @Ledger-Lenz/ml-team
84+
/data/ @Ledger-Lenz/data-team
85+
86+
# ── Documentation ────────────────────────────────────────────────────────────
87+
/docs/ @Ledger-Lenz/core-maintainers
88+
/README.md @Ledger-Lenz/core-maintainers
89+
/CONTRIBUTING.md @Ledger-Lenz/core-maintainers
90+
/CHANGELOG.md @Ledger-Lenz/core-maintainers

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,66 @@
22

33
What does this PR change and why?
44

5+
## Type of change
6+
7+
<!-- Check all that apply -->
8+
- [ ] Bug fix
9+
- [ ] New feature
10+
- [ ] Data/schema change (affects feature columns, data models, Avro schema)
11+
- [ ] Model change (affects training, inference, or evaluation metrics)
12+
- [ ] Infrastructure / CI change
13+
- [ ] Documentation only
14+
- [ ] Security fix
15+
16+
## Changelog
17+
18+
<!-- REQUIRED: paste the entry you added to CHANGELOG.md under [Unreleased] -->
19+
<!-- If this PR touches detection/feature_engineering.py, detection/model_*.py, -->
20+
<!-- ingestion/data_models.py, data/*, or models/* an entry is mandatory. -->
21+
22+
```
23+
### Added / Changed / Fixed / ...
24+
- <your entry here>
25+
```
26+
27+
## Impact assessment
28+
29+
### Data / feature schema changes
30+
<!-- If feature_engineering.py, data_models.py, or data/trade_avro_schema.json changed: -->
31+
- [ ] No schema changes
32+
- [ ] New feature columns added (update data/feature_dictionary.md)
33+
- [ ] Feature columns removed or renamed (update feature_schema_hash; note downstream impact)
34+
- [ ] Avro schema evolved (backward-compatible / breaking)
35+
36+
### Model changes
37+
<!-- If model_training.py, model_inference.py, or models/* changed: -->
38+
- [ ] No model changes
39+
- [ ] Model retrained — include before/after AUC-ROC / F1 in the summary above
40+
- [ ] Inference API changed — update ledgerlens-core if RiskScore shape changed
41+
- [ ] Feature schema hash will change — all consumers need to reload models
42+
43+
### Downstream impact
44+
<!-- Check any systems affected by this change -->
45+
- [ ] `ledgerlens-api` — REST API response shape may change
46+
- [ ] `ledgerlens-dashboard` — visualization or SHAP field names may change
47+
- [ ] `ledgerlens-contract` — on-chain RiskScore struct may change
48+
- [ ] `ledgerlens-core` — shared types or thresholds may change
49+
- [ ] None
50+
551
## Checklist
652

753
- [ ] `make test` passes locally
854
- [ ] `make lint` and `make format` are clean
955
- [ ] New/changed behavior has test coverage
10-
- [ ] `CHANGELOG.md` updated under "Unreleased"
56+
- [ ] `CHANGELOG.md` updated under `[Unreleased]`
1157
- [ ] If a shared contract changed (`RiskScore`, asset pair format, feature
1258
schema), linked issues/PRs in `ledgerlens-core` and downstream repos
59+
60+
<!--
61+
If this PR touches a high-risk path (wire schema, shared contracts, feature
62+
or training code, DB schema, tenant config, model metadata), CI will ask you
63+
to add a short note under a specific heading. See
64+
.github/review-checklists.md — or run `make check-review-gates` to see which
65+
apply before you push.
66+
-->
67+

0 commit comments

Comments
 (0)