@standardagents/builder 0.24.4 → 0.24.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/built-in-routes.js +20 -17
- package/dist/built-in-routes.js.map +1 -1
- package/dist/client/{ApiKeysView-1m7uIS8S.js → ApiKeysView-CmObAp7n.js} +1 -1
- package/dist/client/{CenteredContentView-DJzHRMGj.js → CenteredContentView-gJXa9UHE.js} +1 -1
- package/dist/client/{CompositionView-nzqzVKAg.js → CompositionView-BohQwGLE.js} +1 -1
- package/dist/client/{ConfirmDialog.vue_vue_type_script_setup_true_lang-YX8WE_iB.js → ConfirmDialog.vue_vue_type_script_setup_true_lang-A1C0eTY7.js} +1 -1
- package/dist/client/{CopyButton.vue_vue_type_script_setup_true_lang-BpJt6BT0.js → CopyButton.vue_vue_type_script_setup_true_lang-D5q8qf4n.js} +1 -1
- package/dist/client/{DataTable.vue_vue_type_script_setup_true_lang-Dg3HMMJ0.js → DataTable.vue_vue_type_script_setup_true_lang-DzPpurCp.js} +1 -1
- package/dist/client/{JsonViewer-BdNA5OCG.js → JsonViewer-CKqMMqjU.js} +1 -1
- package/dist/client/{LoginView-BlF_2TtB.js → LoginView-BY2NMQQF.js} +1 -1
- package/dist/client/{MarketplaceView-DrlOb57k.js → MarketplaceView-DVEMUvDq.js} +1 -1
- package/dist/client/{Modal.vue_vue_type_script_setup_true_lang-hkOmEwrb.js → Modal.vue_vue_type_script_setup_true_lang-1t6cxO9H.js} +1 -1
- package/dist/client/{ModelModal.vue_vue_type_script_setup_true_lang-p3esoV-i.js → ModelModal.vue_vue_type_script_setup_true_lang-WFlATqyT.js} +1 -1
- package/dist/client/{ModelsView-CHBanMSH.js → ModelsView-_qZmXle8.js} +1 -1
- package/dist/client/{PromptEditView-b5B43l4Q.js → PromptEditView-DzY493YB.js} +1 -1
- package/dist/client/{PromptModal-BF5bdmNQ.js → PromptModal-BQYwnWKw.js} +1 -1
- package/dist/client/{PromptsView-6TfMOScI.js → PromptsView-DBiQ9X1g.js} +1 -1
- package/dist/client/{ProvidersView-CA5Yx2Fn.js → ProvidersView-DEH34_v0.js} +1 -1
- package/dist/client/{ThreadInspectorPane.vue_vue_type_script_setup_true_lang-ejyFhmNy.js → ThreadInspectorPane.vue_vue_type_script_setup_true_lang-Dtd1VFrj.js} +2 -2
- package/dist/client/{ThreadsView-yJpVmf42.js → ThreadsView-m1CAq3Aw.js} +1 -1
- package/dist/client/{ToolsView-DE1TDnlU.js → ToolsView-D-qvyctb.js} +1 -1
- package/dist/client/{UsersView-BXDHjJLB.js → UsersView-DaXRB61v.js} +1 -1
- package/dist/client/{VariablesView-Bz-CbaEv.js → VariablesView-DDomn-IB.js} +1 -1
- package/dist/client/assets/{ThreadInspectorPane-DLSVKyBu.css → ThreadInspectorPane-CjK6SKEi.css} +1 -1
- package/dist/client/{index-TIntu1KJ.js → index-DihZBCmQ.js} +2 -2
- package/dist/client/index.html +1 -1
- package/dist/{index-jDKWlMKG.d.ts → index-D7KMmRgr.d.ts} +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +55 -36
- package/dist/index.js.map +1 -1
- package/dist/runtime.d.ts +3 -2
- package/dist/runtime.js +55 -36
- package/dist/runtime.js.map +1 -1
- package/dist/test.d.ts +1 -1
- package/package.json +5 -5
package/dist/built-in-routes.js
CHANGED
|
@@ -252,14 +252,14 @@ function calculateUsageCost(usage, pricing) {
|
|
|
252
252
|
const inputPrice = useLongContext ? pricing.longInputPrice ?? pricing.inputPrice : pricing.inputPrice;
|
|
253
253
|
const outputPrice = useLongContext ? pricing.longOutputPrice ?? pricing.outputPrice : pricing.outputPrice;
|
|
254
254
|
const cachedTokenPrice = useLongContext ? pricing.longCachedPrice ?? pricing.cachedPrice ?? pricing.inputPrice : pricing.cachedPrice ?? pricing.inputPrice;
|
|
255
|
-
const costInput = roundCost(
|
|
256
|
-
|
|
257
|
-
);
|
|
255
|
+
const costInput = roundCost(uncachedPromptTokens * inputPrice / TOKENS_PER_MILLION);
|
|
256
|
+
const costCached = roundCost(cachedTokens * cachedTokenPrice / TOKENS_PER_MILLION);
|
|
258
257
|
const costOutput = roundCost(billableOutputTokens * outputPrice / TOKENS_PER_MILLION);
|
|
259
258
|
return {
|
|
260
259
|
costInput,
|
|
260
|
+
costCached,
|
|
261
261
|
costOutput,
|
|
262
|
-
costTotal: roundCost(costInput + costOutput)
|
|
262
|
+
costTotal: roundCost(costInput + costCached + costOutput)
|
|
263
263
|
};
|
|
264
264
|
}
|
|
265
265
|
var TOKENS_PER_MILLION;
|
|
@@ -2136,6 +2136,7 @@ var init_LLMRequest = __esm({
|
|
|
2136
2136
|
reasoning_tokens: response.usage.completion_tokens_details?.reasoning_tokens || 0,
|
|
2137
2137
|
total_tokens: response.usage.total_tokens,
|
|
2138
2138
|
cost_input: calculatedCost?.costInput,
|
|
2139
|
+
cost_cached: calculatedCost?.costCached,
|
|
2139
2140
|
cost_output: calculatedCost?.costOutput,
|
|
2140
2141
|
latency_ms: Date.now() - startTime,
|
|
2141
2142
|
time_to_first_token_ms: timing?.latencyMs ?? void 0,
|
|
@@ -2165,19 +2166,20 @@ var init_LLMRequest = __esm({
|
|
|
2165
2166
|
reasoning_tokens = ?5,
|
|
2166
2167
|
total_tokens = ?6,
|
|
2167
2168
|
cost_input = ?7,
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2169
|
+
cost_cached = ?8,
|
|
2170
|
+
cost_output = ?9,
|
|
2171
|
+
latency_ms = ?10,
|
|
2172
|
+
finish_reason = ?11,
|
|
2173
|
+
tools_called = ?12,
|
|
2174
|
+
cost_total = ?13,
|
|
2175
|
+
is_complete = ?14,
|
|
2176
|
+
reasoning_content = ?15,
|
|
2177
|
+
provider_tools = ?16,
|
|
2178
|
+
actual_provider = ?17,
|
|
2179
|
+
standard_agents_router_used = ?18,
|
|
2180
|
+
time_to_first_token_ms = ?19,
|
|
2181
|
+
generation_ms = ?20
|
|
2182
|
+
WHERE id = ?21
|
|
2181
2183
|
`,
|
|
2182
2184
|
logData.response_body,
|
|
2183
2185
|
logData.input_tokens,
|
|
@@ -2186,6 +2188,7 @@ var init_LLMRequest = __esm({
|
|
|
2186
2188
|
logData.reasoning_tokens,
|
|
2187
2189
|
logData.total_tokens,
|
|
2188
2190
|
logData.cost_input ?? null,
|
|
2191
|
+
logData.cost_cached ?? null,
|
|
2189
2192
|
logData.cost_output ?? null,
|
|
2190
2193
|
logData.latency_ms,
|
|
2191
2194
|
logData.finish_reason,
|