UNPKG

@2501-ai/cli

Version:

[![npm version](https://img.shields.io/npm/v/@2501-ai/cli.svg)](https://www.npmjs.com/package/@2501-ai/cli) [![HumanEval Score](https://img.shields.io/badge/HumanEval-96.95%25-brightgreen.svg)](https://www.2501.ai/research/full-humaneval-benchmark) [![Lic

23 lines (22 loc) 851 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getCurrentCommand = exports.getContext = exports.updateTelemetryContext = void 0; let telemetryContext = {}; const updateTelemetryContext = ({ orgId, tenantId, hostId, agentId, taskId, }) => { telemetryContext = { tenantId: tenantId || telemetryContext.tenantId, orgId: orgId || telemetryContext.orgId, hostId: hostId || telemetryContext.hostId, agentId: agentId || telemetryContext.agentId, taskId: taskId || telemetryContext.taskId, }; }; exports.updateTelemetryContext = updateTelemetryContext; const getContext = () => { return telemetryContext; }; exports.getContext = getContext; const getCurrentCommand = () => { return process.argv.slice(2).join(' '); }; exports.getCurrentCommand = getCurrentCommand;