@duo-director/cli 0.1.1 → 0.1.2
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.
|
@@ -13336,8 +13336,12 @@ function llmProviderState(config, provider) {
|
|
|
13336
13336
|
return "disabled";
|
|
13337
13337
|
return provider === void 0 ? "unavailable" : provider.status();
|
|
13338
13338
|
}
|
|
13339
|
-
|
|
13339
|
+
function redactLLMRequest(request) {
|
|
13340
|
+
return { ...request, instructions: redactSecrets(request.instructions).text, input: redactSecrets(request.input).text };
|
|
13341
|
+
}
|
|
13342
|
+
async function invokeLLM(provider, original, options = {}) {
|
|
13340
13343
|
const t0 = performance5.now();
|
|
13344
|
+
const request = redactLLMRequest(original);
|
|
13341
13345
|
const aborted = () => request.signal?.aborted === true;
|
|
13342
13346
|
const requestEstimate = { tokens: countTokens(request.instructions) + countTokens(request.input), estimator: TOKEN_ESTIMATOR.name };
|
|
13343
13347
|
const done = (response2, called, cached = false) => ({
|
|
@@ -13789,7 +13793,7 @@ async function semanticAssist(input) {
|
|
|
13789
13793
|
lines4.push(`CLAIM ${c.id} rule=${c.rule} subject=${c.subject.id}`, `expected: ${c.expected}`, `observed: ${c.observed}`, `evidence: ${c.evidenceIds.join(", ")}`, "");
|
|
13790
13794
|
for (const id3 of allowed) {
|
|
13791
13795
|
const e = input.store.get(id3);
|
|
13792
|
-
lines4.push(`EVIDENCE ${id3} [${e?.basis ?? "?"}] ${e?.summary ?? ""}`, truncateToTokens(input.store.excerpt(id3) ?? "", perExcerpt).text, "");
|
|
13796
|
+
lines4.push(`EVIDENCE ${id3} [${e?.basis ?? "?"}] ${e?.summary ?? ""}`, truncateToTokens(redactSecrets(input.store.excerpt(id3) ?? "").text, perExcerpt).text, "");
|
|
13793
13797
|
}
|
|
13794
13798
|
const ids2 = new Set(candidates3.map((c) => c.id));
|
|
13795
13799
|
const invocation = await invokeLLM(input.provider, {
|
package/dist/duoctl.js
CHANGED
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duo-director/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@duo-director/cli",
|
|
9
|
-
"version": "0.1.
|
|
9
|
+
"version": "0.1.2",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@modelcontextprotocol/client": "2.1.0",
|
|
12
12
|
"@modelcontextprotocol/server": "2.1.0",
|