You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Although I was planning to parse it into two numeric fields with data pipeline function of our telemetry backend, but I found it a little difficult because tokenConsumed field was recognized as string attributes tokenConsumed: "{\"input\": 123, \"output\": 456}"
Although we are sending business metrics (token consumption is a kind of business metrics) to our observability backend now, we are planning to send them to to BI platform in the future.
Ways to resolve current problem
option 1: send input/output tokens as structured log using body field
pros: (slightly) better in data representation because two attributes related to token consumption can be represented as child attributes of tokenConsumed
cons:
bad in uniformity because "only" token consumption data is sent in body field although other metrics are
still requires preprocessing pipeline to get input/output token from body field
option 2: send input/output tokens as two flat attributes
pros: no preprocessing parser required
cons: (slightly) bad in data representation
TODO (Optional)
decide which option to choose
fix current instrumentation
The text was updated successfully, but these errors were encountered:
sending tokenConsumedInput and tokenConsumedOutput as two flat attributes (option 2)
using body to send nested attributes and deploying separate collector if we need many kinds of structured attributes in the future (option 1-a)
Rindrics
changed the title
Flatten tokenConsumed to postpone introduction of parser pipeline
Fix instrumentation of input/output token consumed to be recognized as numeric attributes
Dec 9, 2024
Task description
Fix instrumentation of input/output token consumed to be recognized as numeric attributes
Background
tokenConsumed: {"input": 123, "output": 456}
tokenConsumed
field was recognized as string attributestokenConsumed: "{\"input\": 123, \"output\": 456}"
Additional context
Although we are sending business metrics (token consumption is a kind of business metrics) to our observability backend now, we are planning to send them to to BI platform in the future.
Ways to resolve current problem
body
fieldtokenConsumed
TODO (Optional)
The text was updated successfully, but these errors were encountered: