update service
This commit is contained in:
4
config/prediction-service.env.example
Normal file
4
config/prediction-service.env.example
Normal file
@@ -0,0 +1,4 @@
|
||||
# Replace these placeholders in /etc/cbpred/prediction-service.env before the
|
||||
# next 8H run. They only allow the example YAML to be parsed.
|
||||
CBPRED_WEBHOOK_TOKEN=replace-me
|
||||
CBPRED_SMTP_PASSWORD=replace-me
|
||||
42
config/prediction-service.user.yml.example
Normal file
42
config/prediction-service.user.yml.example
Normal file
@@ -0,0 +1,42 @@
|
||||
# User-systemd variant of prediction-service.yml.example.
|
||||
# ${NAME} values are expanded from the user service environment.
|
||||
scheduler:
|
||||
poll_seconds: 60
|
||||
grace_seconds: 120
|
||||
state_file: /home/ctyun/.local/state/cbpred/prediction-service-state.json
|
||||
|
||||
prediction:
|
||||
working_dir: /data/quant/cbpred
|
||||
banbot_dir: /home/ctyun/ban/banbot
|
||||
banbot_config: /home/ctyun/ban/banbot/biz/config.yml
|
||||
data_dir: /data/quant/cbpred/data
|
||||
artifact: /data/quant/cbpred/artifacts/v1/model.joblib
|
||||
output_dir: /data/quant/cbpred/predictions/latest_v1
|
||||
history_months: 36
|
||||
holdout_months: 10
|
||||
min_age_days: 730
|
||||
chunk_size: 100
|
||||
db_type: auto
|
||||
exchange: binance
|
||||
|
||||
notifications:
|
||||
http:
|
||||
- url: https://example.internal/hooks/cbpred
|
||||
method: POST
|
||||
timeout_seconds: 15
|
||||
headers:
|
||||
Authorization: "Bearer ${CBPRED_WEBHOOK_TOKEN}"
|
||||
include_predictions: true
|
||||
|
||||
email:
|
||||
enabled: true
|
||||
host: smtp.example.com
|
||||
port: 465
|
||||
ssl: true
|
||||
username: alerts@example.com
|
||||
password: "${CBPRED_SMTP_PASSWORD}"
|
||||
from: alerts@example.com
|
||||
to:
|
||||
- trader@example.com
|
||||
subject: cbpred 8H prediction completed
|
||||
attach_csv: true
|
||||
48
config/prediction-service.yml.example
Normal file
48
config/prediction-service.yml.example
Normal file
@@ -0,0 +1,48 @@
|
||||
# Copy this file outside the repository, then replace paths and secrets.
|
||||
# ${NAME} values are expanded from the service environment; they are never stored in code.
|
||||
scheduler:
|
||||
# The daemon polls cheaply, but executes only once for each completed 8H boundary.
|
||||
poll_seconds: 60
|
||||
# Wait for banbot/exchange ingestion after 00:00, 08:00 and 16:00 UTC.
|
||||
grace_seconds: 120
|
||||
state_file: /var/lib/cbpred/prediction-service-state.json
|
||||
|
||||
prediction:
|
||||
working_dir: /data/quant/cbpred
|
||||
banbot_dir: /home/ctyun/ban/banbot
|
||||
banbot_config: /home/ctyun/ban/banbot/biz/config.yml
|
||||
data_dir: /data/quant/cbpred/data
|
||||
artifact: /data/quant/cbpred/artifacts/v1/model.joblib
|
||||
output_dir: /data/quant/cbpred/predictions/latest_v1
|
||||
history_months: 36
|
||||
holdout_months: 10
|
||||
min_age_days: 730
|
||||
chunk_size: 100
|
||||
db_type: auto
|
||||
exchange: binance
|
||||
|
||||
notifications:
|
||||
http:
|
||||
- url: https://example.internal/hooks/cbpred
|
||||
method: POST
|
||||
timeout_seconds: 15
|
||||
headers:
|
||||
Authorization: "Bearer ${CBPRED_WEBHOOK_TOKEN}"
|
||||
# Set false when the receiving service only needs report.json fields.
|
||||
include_predictions: true
|
||||
# Optional. Without this, all prediction rows are sent.
|
||||
# max_rows: 100
|
||||
|
||||
email:
|
||||
enabled: true
|
||||
host: smtp.example.com
|
||||
port: 465
|
||||
ssl: true
|
||||
# With ssl=true this defaults to false. For port 587, set ssl: false and starttls: true.
|
||||
username: alerts@example.com
|
||||
password: "${CBPRED_SMTP_PASSWORD}"
|
||||
from: alerts@example.com
|
||||
to:
|
||||
- trader@example.com
|
||||
subject: cbpred 8H prediction completed
|
||||
attach_csv: true
|
||||
Reference in New Issue
Block a user