-
Notifications
You must be signed in to change notification settings - Fork 73
/
Copy pathconfig.yaml
65 lines (58 loc) · 1.87 KB
/
config.yaml
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
ingest:
kafka:
broker: kafka:9092
brokerAddressFamily: v4
socketKeepAliveEnable: true
topicMetadataRefreshInterval: 10s
aggregation:
clickhouse:
address: clickhouse:9000
sink:
minCommitCount: 1
namespaceRefetch: 1s
namespaceRefetchTimeout: 1s
kafka:
brokers: kafka:9092
brokerAddressFamily: v4
socketKeepAliveEnable: true
topicMetadataRefreshInterval: 10s
dedupe:
enabled: true
driver: redis
config:
address: redis:6379
database: 0
expiration: 768h # 32d
postgres:
url: postgres://postgres:postgres@postgres:5432/postgres?sslmode=disable
autoMigrate: migration # Runs migrations as part of the service startup, valid values are: ent, migration, false
meters:
# Sample meter to count API requests
- slug: api_requests_total # Unique identifier for the meter
description: API Requests
eventType: request # Filter events by type
aggregation: COUNT # Aggregation method: COUNT, SUM, etc.
groupBy:
method: $.method # HTTP Method: GET, POST, etc.
route: $.route # Route: /products/:product_id
# Sample meter to sum API request duration
- slug: api_requests_duration
description: API Request Duration
eventType: request
aggregation: SUM
valueProperty: $.duration_ms # JSONPath to parse usage value
groupBy:
method: $.method
route: $.route
# Sample meter to count LLM Token Usage
- slug: tokens_total
description: AI Token Usage
eventType: prompt # Filter events by type
aggregation: SUM
valueProperty: $.tokens # JSONPath to parse usage value
groupBy:
model: $.model # AI model used: gpt4-turbo, etc.
type: $.type # Prompt type: input, output, system
portal:
enabled: true
tokenSecret: this-isnt-secure