Files
zCode-CLI-X/~/.npm-cache/@opentelemetry/sdk-metrics@2.6.1@@@1/build/esnext/view/AggregationOption.js
admin 875c7f9b91 feat: Complete zCode CLI X with Telegram bot integration
- Add full Telegram bot functionality with Z.AI API integration
- Implement 4 tools: Bash, FileEdit, WebSearch, Git
- Add 3 agents: Code Reviewer, Architect, DevOps Engineer
- Add 6 skills for common coding tasks
- Add systemd service file for 24/7 operation
- Add nginx configuration for HTTPS webhook
- Add comprehensive documentation
- Implement WebSocket server for real-time updates
- Add logging system with Winston
- Add environment validation

🤖 zCode CLI X - Agentic coder with Z.AI + Telegram integration
2026-05-05 09:01:26 +00:00

38 lines
1.8 KiB
JavaScript

import { DEFAULT_AGGREGATION, DROP_AGGREGATION, ExplicitBucketHistogramAggregation, ExponentialHistogramAggregation, HISTOGRAM_AGGREGATION, LAST_VALUE_AGGREGATION, SUM_AGGREGATION, } from './Aggregation';
export var AggregationType;
(function (AggregationType) {
AggregationType[AggregationType["DEFAULT"] = 0] = "DEFAULT";
AggregationType[AggregationType["DROP"] = 1] = "DROP";
AggregationType[AggregationType["SUM"] = 2] = "SUM";
AggregationType[AggregationType["LAST_VALUE"] = 3] = "LAST_VALUE";
AggregationType[AggregationType["EXPLICIT_BUCKET_HISTOGRAM"] = 4] = "EXPLICIT_BUCKET_HISTOGRAM";
AggregationType[AggregationType["EXPONENTIAL_HISTOGRAM"] = 5] = "EXPONENTIAL_HISTOGRAM";
})(AggregationType || (AggregationType = {}));
export function toAggregation(option) {
switch (option.type) {
case AggregationType.DEFAULT:
return DEFAULT_AGGREGATION;
case AggregationType.DROP:
return DROP_AGGREGATION;
case AggregationType.SUM:
return SUM_AGGREGATION;
case AggregationType.LAST_VALUE:
return LAST_VALUE_AGGREGATION;
case AggregationType.EXPONENTIAL_HISTOGRAM: {
const expOption = option;
return new ExponentialHistogramAggregation(expOption.options?.maxSize, expOption.options?.recordMinMax);
}
case AggregationType.EXPLICIT_BUCKET_HISTOGRAM: {
const expOption = option;
if (expOption.options == null) {
return HISTOGRAM_AGGREGATION;
}
else {
return new ExplicitBucketHistogramAggregation(expOption.options?.boundaries, expOption.options?.recordMinMax);
}
}
default:
throw new Error('Unsupported Aggregation');
}
}
//# sourceMappingURL=AggregationOption.js.map