🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@quantakrypto/agent

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@quantakrypto/agent

BYOK LLM client for qScan triage and remediation. Native fetch, zero runtime dependencies.

latest
Source
npmnpm
Version
0.9.0
Version published
Maintainers
1
Created
Source

@quantakrypto/agent

BYOK (bring-your-own-key) LLM client for qScan triage and remediation. Native fetch, zero third-party runtime dependencies.

This is the only networked package in the quantakrypto toolset. All deterministic pieces (the context redactor, the verify_fix gate, codemods, the patch-policy engine) live in @quantakrypto/core, so the offline MCP server never loads this package.

What it provides

  • resolveClient(config) → an LlmClient for anthropic or any openai-compatible endpoint (baseURL + key + model). Responses are JSON-schema-validated with one repair-retry.
  • triageFindings(findings, opts) — ask the model for an exposure verdict per finding (annotate + re-rank, never suppress).
  • proposeFix(finding, opts) — ask the model for a corrected full file. Skips any file containing secrets; the result is gated downstream by verify_fix.
  • A response cache keyed by (promptVersion, model, contextLevel, fingerprint) so reruns are reproducible and cheap.

Usage

You normally reach these through qscan --triage and qremediate --llm rather than directly. The BYOK key is read from the environment: QK_LLM_API_KEY, or the provider-native ANTHROPIC_API_KEY / OPENAI_API_KEY.

import { resolveClient, triageFindings } from "@quantakrypto/agent";

const client = resolveClient({
  provider: "anthropic",
  model: "claude-sonnet-5",
  apiKey: process.env.ANTHROPIC_API_KEY!,
});

const verdicts = await triageFindings(findings, {
  client,
  level: "snippet", // metadata | snippet | function | file — key material redacted (best-effort)
  readFile: (p) => fs.promises.readFile(p, "utf8"),
  fingerprint: fingerprintFinding,
});

Safety properties

  • Best-effort secret redaction on every egress path. Findings whose match is key material are never sent as code, and a file with any stripped secret is never sent for a full-file rewrite. Redaction is pattern-based and can miss novel token formats — review the exact payload with qscan --triage --dry-run, and do not enable triage on repositories holding regulated data (see THREAT-MODEL).
  • Zero third-party runtime deps — native fetch only.
  • Only the configured endpoint is contacted. No telemetry.

Apache-2.0 · quantakrypto.com/tools

FAQs

Package last updated on 05 Aug 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts