{"_id":"@thinkhive/sdk","_rev":"16-87d4325881e98ea5fb3f4771ea8ff58d","name":"@thinkhive/sdk","dist-tags":{"latest":"4.2.6"},"versions":{"2.0.0":{"name":"@thinkhive/sdk","version":"2.0.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","openai","anthropic","agent"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@2.0.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/thinkhive/thinkhive-js/issues"},"dist":{"shasum":"83d67cc4039f136511d256e197c814de8007f355","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-2.0.0.tgz","fileCount":5,"integrity":"sha512-azuIQ+A+9eLdv0fIHPIV79Awdt9hpXqY1r1CUe5/wI+U1fQFyj9pbB7R/VjO/A/mfp7oYB2mtpM+RTJdM03ljA==","signatures":[{"sig":"MEUCIH26rP2gIu8ycy/p9P7GHbHCIpSf2zss76nJhmdQOxLeAiEAqhgizN+HipXJO8yvaLuuwjRz8We1CQQQhgfhugbUr8A=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":99810},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=16.0.0"},"scripts":{"test":"echo \"No tests yet\" && exit 0"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/thinkhive/thinkhive-js.git","type":"git"},"_npmVersion":"10.8.2","description":"ThinkHive SDK - AI Agent Observability Platform with explainability, RAG evaluation, and business impact analysis","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/sdk_2.0.0_1766995611776_0.6104475062291002","host":"s3://npm-registry-packages-npm-production"}},"2.0.1":{"name":"@thinkhive/sdk","version":"2.0.1","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","openai","anthropic","agent"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@2.0.1","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/thinkhive/thinkhive-js/issues"},"dist":{"shasum":"e84f6c87fabb1d4073b915f2cf1b263dd1efe119","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-2.0.1.tgz","fileCount":5,"integrity":"sha512-IuSqOVmknGJgy+w5T7eK5O9eglJCyI9FN3ZrW1BQkGk1VUh9wQGZ/Gpi/hMIoWn8e0EJG7glkUgfZ5s4v92lZw==","signatures":[{"sig":"MEUCIQC0bCe4YF6ejTBfZYgpy7PD7IgIwEWeWm/BBAn+F3MQMQIgZLQb0hhjyzP2KFP5G8oCTQsif7iiE748XbDannnb374=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":100561},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=16.0.0"},"scripts":{"test":"echo \"No tests yet\" && exit 0"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/thinkhive/thinkhive-js.git","type":"git"},"_npmVersion":"10.8.2","description":"ThinkHive SDK - AI Agent Observability Platform with explainability, RAG evaluation, and business impact analysis","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/sdk_2.0.1_1766995730216_0.8460420730636018","host":"s3://npm-registry-packages-npm-production"}},"3.0.0":{"name":"@thinkhive/sdk","version":"3.0.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@3.0.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/thinkhive/thinkhive-js/issues"},"dist":{"shasum":"f19b089122269a4b622648d96a0e09e5107c6f17","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-3.0.0.tgz","fileCount":26,"integrity":"sha512-rVSUeJrF2gT0DaWMlUqLx8QHjJjWEixhfyyYiOJWvILoRAg88PRoi2So97vsTysy7inryPiJMVLoWX/YN0QyVA==","signatures":[{"sig":"MEUCIGFgKN564yjrg5XB0NxXLhjlNq9WIlQqEDRQQrnw/bG2AiEA8zgXUzoWbTTcJiBLFiJeE4HUsa7Gq49yoOhGGyXoR6s=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":374555},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"7d7643a4d83bf6f3f85c52b5c631c389d53e0b6c","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/thinkhive/thinkhive-js.git","type":"git"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v3.0 - Run-centric AI agent observability with facts vs inferences, deterministic linking, and calibrated predictions","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_3.0.0_1767049265135_0.43458293925018077","host":"s3://npm-registry-packages-npm-production"}},"3.1.0":{"name":"@thinkhive/sdk","version":"3.1.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@3.1.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/thinkhive/thinkhive-js/issues"},"dist":{"shasum":"9bb4ff2e4b904074e6aa1f51d64171bedfdd1776","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-3.1.0.tgz","fileCount":26,"integrity":"sha512-9BHoPL6avj65kGiwsuNWa/iThIIh1+0hMSQHMBoOjMVF2YLy5PIvI4CZI846QLU85f42xOE2epcBA64cNtkh0A==","signatures":[{"sig":"MEYCIQD8/etKT9JG7ttvvFGGJwhz25Fcet54KJx6GOQShdRlLAIhAK0U5pq5yMQDmfO2bepmVcvFKEXjNQNkdYGFSXvdFSZ9","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":374842},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"2bdc3d3a55f9da95089ac56f287c9ec0a358fe4b","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/thinkhive/thinkhive-js.git","type":"git"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v3.1 - AI agent observability supporting 25 trace formats including LangSmith, Langfuse, Opik, Braintrust, Datadog, MLflow, and more","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_3.1.0_1767083190756_0.18901231153284992","host":"s3://npm-registry-packages-npm-production"}},"3.1.1":{"name":"@thinkhive/sdk","version":"3.1.1","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@3.1.1","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"3041af87ac6a295c7dc7e634c8db60c151996a8e","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-3.1.1.tgz","fileCount":26,"integrity":"sha512-MEgVbMjoS9tzPKNn6eYErM3jxIduUtJHnlYqhix0ARIqP1TeqW5EqUE3LTq9yYGglb4AlBWMS6q4YuS/thJxaA==","signatures":[{"sig":"MEUCIFXv2WAETYsIxcjDTKqtjRzOfxcFH3RjxC4KreCAgj8JAiEAu4Rxr09lL+ZkUp0IAh3sms7cHCVHOy8Jme4cBUaLzYc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":374930},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"145f5f699d940bb99afbe94d4363d9045428ad53","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v3.1 - AI agent observability supporting 25 trace formats including LangSmith, Langfuse, Opik, Braintrust, Datadog, MLflow, and more","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_3.1.1_1767331929464_0.1092612734669749","host":"s3://npm-registry-packages-npm-production"}},"3.3.0":{"name":"@thinkhive/sdk","version":"3.3.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@3.3.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"5bbb69b4f655650312e47b6389b25b916880aae8","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-3.3.0.tgz","fileCount":46,"integrity":"sha512-tq2fQqPoMOLVmk7eln8l05r+PhMq8x5ZzPZiNj/Z6QNiO+DZNV5O1fs4ZTA3FA7HvV46sVvIbDr6gJF64Sqf4A==","signatures":[{"sig":"MEUCIEVEKZwUIqitJBzaAu4eE55YcALGbBqIb2OTuA9vyxD2AiEA4X3VFq6kw01dgAL60zpbxahBwGGGbjfChXudDpNvSP0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":787087},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"76ccef05f439bb7df40239d0be4f409ea2330222","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v3.3 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_3.3.0_1769428749309_0.4987628905499868","host":"s3://npm-registry-packages-npm-production"}},"4.0.0":{"name":"@thinkhive/sdk","version":"4.0.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.0.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"636b235994ec5acaf310656a8f56871cde025ac5","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.0.0.tgz","fileCount":48,"integrity":"sha512-h507kCmQQpV+McAsPENBxMY+5bIm8iKILuwQnC5ATAqCTP0nN4mpaKB0Vhv5pBE73cqr+fURW6nq8jv+36dZ1Q==","signatures":[{"sig":"MEUCICmZJC792TNX03Z6Hg0Yw8MDvpcMrtvFWwYqu2/PFKxmAiEAsHT+kkmJ8ESI4WdLtw8cED0Zj6RDXl7KqvfWL2312WM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":818314},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"b89de05c0c0e7073a838793c4ae5af83d871d408","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.0.0_1772651894201_0.45729026416269436","host":"s3://npm-registry-packages-npm-production"}},"4.0.1":{"name":"@thinkhive/sdk","version":"4.0.1","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.0.1","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"7e04deb894947eb6f1b087824ff9d44152d7aa3f","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.0.1.tgz","fileCount":48,"integrity":"sha512-zNzTJQrlI7tCdNwpQZ9yO3paOBol4JeyH8biPKea3fhJKSzHyrcDX8KT0SuJsH6WEOV+PfFe2f44pDHNOCp5hg==","signatures":[{"sig":"MEYCIQDVi3yOPfJ0OAZ3runjxHym3Rb/BBVno1Q+b2lg1lHirAIhAKbpgwbNHFs/NkyyLDIuIAHhLUo1gYkhAOKrgbDRTYcv","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":818953},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"febe16dba99c17804631b50572ed6b5672a4e626","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.0.1_1772652071978_0.25130710041843396","host":"s3://npm-registry-packages-npm-production"}},"4.1.0":{"name":"@thinkhive/sdk","version":"4.1.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.1.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"a78f42f3bfa458ff0d6f0ddef7b8de3f51572e69","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.1.0.tgz","fileCount":48,"integrity":"sha512-Gi+j2uKkzskBGjuGg9m+bHZS04JpJ8eaMmlwj9Ej4ucjx8m+odWwlHdNv7THhRBcD/vnP1tzkBYoEp4kxcbRSA==","signatures":[{"sig":"MEUCIQDuQR/W91JKtfkl0swLUQNJ3KdquqU6QDHbbPfpz1yergIgP68oi3SSuipAm9f3RA12oHLONZaG1bLGHYjy0FHeSyg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":853089},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"491d4f2787e4a56605a272dcc0cf1c82a48223c2","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.1.0_1772793276417_0.4521326331069426","host":"s3://npm-registry-packages-npm-production"}},"4.2.0":{"name":"@thinkhive/sdk","version":"4.2.0","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.0","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"6d792bda6fc850e8b22e88eaafd93e6152e7e724","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.0.tgz","fileCount":66,"integrity":"sha512-TPc8QqZhnHHytvRpb/D//ocN170LgRT0CpcQYFoCPLymN3H5aIVBbxQTSBHfZuKO2LIRcTko+BzgannP60l69g==","signatures":[{"sig":"MEYCIQCxgbFFb6XwCba/Aaz8Ne1cEAraJM2cQTvgtI9mNZ/AVgIhANXwpfPzEbDY4an+qpzXVM3JnIwywWqlBefXWk14MbNe","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":983521},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"dab0d8a4b8a9207fd3f33b720ce16d4eef8941d0","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.0_1773907223482_0.3240989387065789","host":"s3://npm-registry-packages-npm-production"}},"4.2.1":{"name":"@thinkhive/sdk","version":"4.2.1","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.1","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"dd417903ec8e681219487de01981e1593e10d245","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.1.tgz","fileCount":66,"integrity":"sha512-TTvV1rVHSg8i3sX5Hrt/JCwZ8WBLJkT3C6IYT9lS2et1ky+hLITJDax9sJ64fKZ/XzLA5LLTte/iBVoZ2d21mQ==","signatures":[{"sig":"MEUCIQDznSHj953TkqLqtZ0gLiZdYUhoY513wAV/+RtO0Dyr0QIgIfii+/FlcUrzLKFl9f+Yz7fzzFISCiIglWrxgNnaGTo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":987737},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"d73d5bb5a2c4360f77e62e0d9b84cdd76f9de0a2","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.1_1773907517409_0.6187880725707233","host":"s3://npm-registry-packages-npm-production"}},"4.2.2":{"name":"@thinkhive/sdk","version":"4.2.2","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.2","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"949c8bc2f440462b785061c3dd68824f28631124","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.2.tgz","fileCount":66,"integrity":"sha512-jADxqAZjuAUFzI8khv15boQK/kQkeOh9ZmMdi6PqsIBOWuEPIkWrFwcOcEX0oJVgUERNs85P+SLvMuhOTp+PHg==","signatures":[{"sig":"MEYCIQDNhZ9gtLxTe6V1o5MGN2+zW4R6gE1TJKmA7ScP85yfWQIhAI4Kemw+FT2/5m9R9iKv7+sQ34EYDJhbw1dB+/5iAabi","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":987737},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"9d44f0448e973e01171ae869962f6bc8919194ec","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.2_1773907767688_0.1471607969237816","host":"s3://npm-registry-packages-npm-production"}},"4.2.3":{"name":"@thinkhive/sdk","version":"4.2.3","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.3","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"2e303e2dbff6d58c5536d04e27b0bba906a63803","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.3.tgz","fileCount":66,"integrity":"sha512-hxy98Jt5wcoibQX/AWgH60iGyGgBiGitYD6oyjbt8UafdP7yilnuWuXOQFXUfO1yojqgoTbw2vXdfzAcJSR6xw==","signatures":[{"sig":"MEUCIQCPjGiCQVP7dFIq3S+ylLLpIWBtBAR3MTjKINdj4GTQUQIgRxIzUKIBRZ2/U98qmM3k5zPkBfD83EfF+zZeDhHPMsQ=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1016069},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"a5cb1cab3d8e7ad8da0bb3a9ba2ce3b6055f89b9","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.8.0","@opentelemetry/resources":"^1.21.0","@opentelemetry/sdk-trace-base":"^1.21.0","@opentelemetry/sdk-trace-node":"^1.21.0","@opentelemetry/exporter-trace-otlp-proto":"^0.49.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.3_1774136256818_0.748253746132115","host":"s3://npm-registry-packages-npm-production"}},"4.2.4":{"name":"@thinkhive/sdk","version":"4.2.4","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.4","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"b1d4d0413177d113875483721ab6100ceecb274d","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.4.tgz","fileCount":66,"integrity":"sha512-aR5T1j7N4De21fNeqDeA2494xUalRpfDLl1TpoxRaYRDlatvHodeGb3jP8kgzKkJTj7w9Rj4l/gEJVtodwUVDg==","signatures":[{"sig":"MEUCIASv5T/nBC8yHBOOhoLd8nZ4qsbLfQNGCef4wXSSpfUcAiEAyVfklEx1ia4HzXOY0piiPP40kO6OEi/jkBHz68TkWpo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1016216},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"3d4b3a3e03ff7b6869c0225897ff64680e5fcdfe","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/resources":"^2.6.0","@opentelemetry/sdk-trace-base":"^2.6.0","@opentelemetry/sdk-trace-node":"^2.6.0","@opentelemetry/exporter-trace-otlp-proto":"^0.213.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.4_1774137499000_0.8616411804634578","host":"s3://npm-registry-packages-npm-production"}},"4.2.5":{"name":"@thinkhive/sdk","version":"4.2.5","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","_id":"@thinkhive/sdk@4.2.5","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"homepage":"https://thinkhive.ai","bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"dist":{"shasum":"a3495dcc5d53b3d3a2943c9cbf78eb18e2662003","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.5.tgz","fileCount":66,"integrity":"sha512-m6U/vz8MXAjflqo6X3edJu/K5ZSDZ/dhBMAliPg/75bA8LBaz3osjbUzJulLvlfVYwqg0lIFgTaGvG74Qk8Ptg==","signatures":[{"sig":"MEYCIQCOU6+8gAAR5akfVLbSAUTvSRITrNjJWWguEow1dft8hQIhAMev9thv/n2jzcjcWa4oyczXR22Vj7H1a9eS3VqfF2I5","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1018329},"main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js"},"./instrumentation/openai":{"types":"./dist/instrumentation/openai.d.ts","require":"./dist/instrumentation/openai.js"},"./instrumentation/langchain":{"types":"./dist/instrumentation/langchain.d.ts","require":"./dist/instrumentation/langchain.js"},"./integrations/ticket-linking":{"types":"./dist/integrations/ticket-linking.d.ts","require":"./dist/integrations/ticket-linking.js"},"./integrations/customer-context":{"types":"./dist/integrations/customer-context.d.ts","require":"./dist/integrations/customer-context.js"}},"gitHead":"55defe4a1ee083c4d5d14ea6ceac9b6fe48aec17","scripts":{"lint":"eslint src --ext .ts","test":"vitest run","build":"tsc","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","prepublishOnly":"npm run clean && npm run build"},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"repository":{"url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","type":"git","directory":"thinkhive-js"},"_npmVersion":"10.8.2","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","directories":{},"_nodeVersion":"20.19.5","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/resources":"^2.6.0","@opentelemetry/sdk-trace-base":"^2.6.0","@opentelemetry/sdk-trace-node":"^2.6.0","@opentelemetry/exporter-trace-otlp-proto":"^0.213.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^8.0.0","vitest":"^1.0.0","typescript":"^5.0.0","@types/node":"^20.0.0","@typescript-eslint/parser":"^6.0.0","@typescript-eslint/eslint-plugin":"^6.0.0"},"peerDependencies":{"openai":">=4.0.0","@langchain/core":">=0.1.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/sdk_4.2.5_1774139179637_0.8443514664912501","host":"s3://npm-registry-packages-npm-production"}},"4.2.6":{"name":"@thinkhive/sdk","version":"4.2.6","description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","main":"dist/index.js","types":"dist/index.d.ts","exports":{".":{"require":"./dist/index.js","types":"./dist/index.d.ts"},"./instrumentation/openai":{"require":"./dist/instrumentation/openai.js","types":"./dist/instrumentation/openai.d.ts"},"./instrumentation/langchain":{"require":"./dist/instrumentation/langchain.js","types":"./dist/instrumentation/langchain.d.ts"},"./integrations/ticket-linking":{"require":"./dist/integrations/ticket-linking.js","types":"./dist/integrations/ticket-linking.d.ts"},"./integrations/customer-context":{"require":"./dist/integrations/customer-context.js","types":"./dist/integrations/customer-context.d.ts"}},"scripts":{"build":"tsc","clean":"rm -rf dist","prepublishOnly":"npm run clean && npm run build","test":"vitest run","test:watch":"vitest","lint":"eslint src --ext .ts","typecheck":"tsc --noEmit"},"keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","homepage":"https://thinkhive.ai","repository":{"type":"git","url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","directory":"thinkhive-js"},"bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"publishConfig":{"access":"public"},"engines":{"node":">=18.0.0"},"dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/exporter-trace-otlp-proto":"^0.213.0","@opentelemetry/resources":"^2.6.0","@opentelemetry/sdk-trace-base":"^2.6.0","@opentelemetry/sdk-trace-node":"^2.6.0"},"devDependencies":{"@types/node":"^20.0.0","@typescript-eslint/eslint-plugin":"^6.0.0","@typescript-eslint/parser":"^6.0.0","eslint":"^8.0.0","typescript":"^5.0.0","vitest":"^1.0.0"},"peerDependencies":{"@langchain/core":">=0.1.0","openai":">=4.0.0"},"peerDependenciesMeta":{"openai":{"optional":true},"@langchain/core":{"optional":true}},"_id":"@thinkhive/sdk@4.2.6","gitHead":"eb397d6331cf0e6b14c216ff9d5981a9370688b2","_nodeVersion":"20.19.5","_npmVersion":"10.8.2","dist":{"integrity":"sha512-HYiMmNdwyy7J6nTvNlk8OHmTMCaLnNkZGdeRYyNJKX+w7BOegHSpvgB9UOxmut4ENBwnEwjlOMNa5n5k+cgTwg==","shasum":"a19f30315476bd689f9b0563704299b12dc7cdc5","tarball":"https://registry.npmjs.org/@thinkhive/sdk/-/sdk-4.2.6.tgz","fileCount":66,"unpackedSize":1018262,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIA1txOrzf7w+7Itf3K3GPh1H+XUILjgL9WsaePmPmTNOAiA8G6ePNnpJPKcLJbaqAVQWirUBQHm/VLrDaFjYmY8sbw=="}]},"_npmUser":{"name":"abdul-omira","email":"aomira@cs.stanford.edu"},"directories":{},"maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sdk_4.2.6_1774139853602_0.025108098991686978"},"_hasShrinkwrap":false}},"time":{"created":"2025-12-29T08:06:51.648Z","modified":"2026-03-22T00:37:33.913Z","2.0.0":"2025-12-29T08:06:51.909Z","2.0.1":"2025-12-29T08:08:50.348Z","3.0.0":"2025-12-29T23:01:05.282Z","3.1.0":"2025-12-30T08:26:30.889Z","3.1.1":"2026-01-02T05:32:09.652Z","3.3.0":"2026-01-26T11:59:09.518Z","4.0.0":"2026-03-04T19:18:14.413Z","4.0.1":"2026-03-04T19:21:12.167Z","4.1.0":"2026-03-06T10:34:36.608Z","4.2.0":"2026-03-19T08:00:23.650Z","4.2.1":"2026-03-19T08:05:17.795Z","4.2.2":"2026-03-19T08:09:27.862Z","4.2.3":"2026-03-21T23:37:36.999Z","4.2.4":"2026-03-21T23:58:19.145Z","4.2.5":"2026-03-22T00:26:19.798Z","4.2.6":"2026-03-22T00:37:33.779Z"},"bugs":{"url":"https://github.com/Abdul-Omira/ThinkHiveMind/issues"},"author":{"name":"ThinkHive","email":"support@thinkhive.ai"},"license":"MIT","homepage":"https://thinkhive.ai","keywords":["thinkhive","ai","llm","observability","tracing","opentelemetry","explainability","rag","hallucination-detection","business-impact","langchain","langgraph","openai","anthropic","agent","facts-vs-inferences","calibration","zendesk","intercom","customer-support"],"repository":{"type":"git","url":"git+https://github.com/Abdul-Omira/ThinkHiveMind.git","directory":"thinkhive-js"},"description":"ThinkHive SDK v4.0 - AI agent observability with business metrics, ROI analytics, and 25+ trace format support","maintainers":[{"name":"abdul-omira","email":"aomira@cs.stanford.edu"}],"readme":"# ThinkHive SDK v4.2.2\n\nThe official JavaScript/TypeScript SDK for [ThinkHive](https://thinkhive.ai) - AI Agent Observability Platform.\n\n## Features\n\n- **OpenTelemetry-Based Tracing**: Built on OTLP for seamless integration with existing observability tools\n- **Run-Centric Architecture**: Atomic unit of work tracking with claims, calibration, and linking\n- **Facts vs Inferences**: Claims API for separating verified facts from inferences\n- **Deterministic Ticket Linking**: 7 methods for linking runs to support tickets (Zendesk, Intercom, Salesforce, Freshdesk)\n- **Calibrated Predictions**: Brier scores and ECE for prediction accuracy\n- **Configurable ROI Engine**: Business impact calculation with customizable cost, deflection, and attribution models\n- **Auto-Instrumentation**: Works with LangChain, OpenAI, Anthropic, and more\n- **Multi-Format Support**: Normalizes traces from 25+ observability platforms\n\n## Installation\n\n```bash\nnpm install @thinkhive/sdk\n```\n\n## Quick Start\n\n### Initialization\n\n```typescript\nimport { init, runs, shutdown } from '@thinkhive/sdk';\n\ninit({\n  apiKey: 'thk_your_api_key',\n  serviceName: 'my-ai-agent',\n  autoInstrument: true,\n  frameworks: ['langchain', 'openai'],\n});\n\n// Create a run (atomic unit of work)\nconst run = await runs.create({\n  agentId: 'weather-agent',\n  conversationMessages: [\n    { role: 'user', content: 'What is the weather in San Francisco?' },\n    { role: 'assistant', content: 'The weather in San Francisco is currently 65F and sunny.' }\n  ],\n  outcome: 'success',\n});\n\nconsole.log(`Run ID: ${run.id}`);\nawait shutdown();\n```\n\n## API Reference\n\n### Core APIs (V3)\n\n| API | Import | Description |\n|-----|--------|-------------|\n| `runs` | `@thinkhive/sdk` | Create and manage runs (atomic work units) |\n| `claims` | `@thinkhive/sdk` | Manage facts/inferences for runs |\n| `calibration` | `@thinkhive/sdk` | Track prediction accuracy (Brier scores) |\n| `linking` | `@thinkhive/sdk` | Connect runs to support tickets (7 methods) |\n| `customerContext` | `@thinkhive/sdk` | Time-series customer snapshots |\n| `roiAnalytics` | `@thinkhive/sdk` | Configurable ROI calculation engine |\n| `agents` | `@thinkhive/sdk` | Agent CRUD management |\n| `apiKeys` | `@thinkhive/sdk` | API key management with scoped permissions |\n\n### Assessment APIs\n\n| API | Description |\n|-----|-------------|\n| `humanReview` | Human-in-the-loop review queues |\n| `nondeterminism` | Multi-sample reliability testing |\n| `evalHealth` | Metric health monitoring |\n| `deterministicGraders` | Rule-based grading |\n| `conversationEval` | Multi-turn conversation grading |\n| `transcriptPatterns` | Pattern detection in transcripts |\n\n### Operations & Monitoring APIs\n\n| API | Description |\n|-----|-------------|\n| `evalRuns` | Create, manage, and query evaluation runs |\n| `signals` | Behavioral signal configuration, stats, and trends |\n| `notifications` | Alert rules and notification management |\n| `documents` | Agent RAG document upload and management |\n| `shadowTests` | Shadow test creation and execution |\n| `sessions` | Trace session grouping and querying |\n| `drift` | Model/behavior drift detection |\n| `llmCosts` | LLM usage cost tracking and optimization |\n\n### Legacy APIs (V2)\n\n| API | Description |\n|-----|-------------|\n| `issues` | Clustered failure patterns |\n| `analyzer` | User-selected trace analysis with cost estimation |\n| `businessMetrics` | Industry-driven metrics with historical tracking |\n| `qualityMetrics` | RAG scoring and hallucination detection |\n\n---\n\n## Runs API\n\n```typescript\nimport { runs, createRunWithContext } from '@thinkhive/sdk';\n\n// Create a run\nconst run = await runs.create({\n  agentId: 'support-agent',\n  conversationMessages: [\n    { role: 'user', content: 'Help me cancel my order' },\n    { role: 'assistant', content: 'I can help you cancel your order...' }\n  ],\n  outcome: 'resolved',\n  durationMs: 1500,\n});\n\n// List runs with filters\nconst result = await runs.list({\n  agentId: 'support-agent',\n  outcome: 'resolved',\n  startedAfter: '2025-01-01',\n  limit: 50,\n});\n\n// Get a specific run\nconst existing = await runs.get('run_abc123');\n\n// Get run statistics\nconst stats = await runs.stats('support-agent');\n```\n\n## Claims API (Facts vs Inferences)\n\n```typescript\nimport { claims, isFact, isInference, getHighConfidenceClaims } from '@thinkhive/sdk';\n\n// List claims for a run\nconst claimList = await claims.list(runId);\n\n// Filter by type\nconst facts = claimList.filter(isFact);\nconst inferences = claimList.filter(isInference);\n\n// Get high confidence claims\nconst confident = getHighConfidenceClaims(claimList, 0.9);\n\n// Group by category\nconst byCategory = groupClaimsByCategory(claimList);\n```\n\n## Calibration API\n\n```typescript\nimport { calibration, calculateBrierScore, isWellCalibrated } from '@thinkhive/sdk';\n\n// Get calibration status for a prediction type\nconst status = await calibration.status('agent-123', 'churn_risk');\n\n// Get all calibration metrics\nconst metrics = await calibration.allMetrics('agent-123');\n\n// Single prediction\nconst score = calculateBrierScore(0.8, true); // 0.04\n\n// Batch calculation\nconst batchScore = calculateBrierScore([\n  { predicted: 0.8, actual: 1 },\n  { predicted: 0.3, actual: 0 },\n]);\n\nif (isWellCalibrated(score)) {\n  console.log('Agent predictions are well calibrated');\n}\n```\n\n## Ticket Linking (V3)\n\nDeterministic linking between runs and support tickets using 7 methods with explicit confidence scores.\n\n```typescript\nimport {\n  linking,\n  generateZendeskMarker,\n  linkRunToTicket,\n  linkRunToZendeskTicket,\n  getBestLinkMethod,\n  LINK_METHOD_CONFIDENCE,\n} from '@thinkhive/sdk';\n\n// SDK explicit linking (confidence: 1.0)\nconst link = await linking.create({\n  runId: 'run_abc123',\n  ticketId: 'ticket_xyz',\n  method: 'sdk_explicit',\n});\n\n// Zendesk marker linking\nconst zdLink = await linking.create({\n  runId: 'run_abc123',\n  externalTicketId: '12345',\n  platform: 'zendesk',\n  method: 'zendesk_marker',\n});\n\n// Convenience functions\nawait linkRunToTicket('run_abc123', 'ticket_xyz');\nawait linkRunToZendeskTicket('run_abc123', '12345');\n\n// Get links for a run\nconst links = await linking.getForRun('run_abc123');\n\n// Get links for a ticket\nconst ticketLinks = await linking.getForTicket('ticket_xyz');\n\n// Verify a link\nawait linking.verify('link_id', { verified: true, notes: 'Confirmed by agent' });\n\n// Auto-link using all available evidence\nconst autoLinked = await linking.autoLink('run_abc123');\n\n// Get link statistics\nconst stats = await linking.stats();\n// { totalLinks, byMethod, avgConfidence, verifiedCount, unverifiedCount }\n\n// Generate a Zendesk marker to embed in responses\nconst marker = generateZendeskMarker('run_abc123');\n// Returns: '[THID:run_abc123]'\n\n// Server-side marker generation with format options\nconst serverMarker = await linking.generateMarker({\n  traceId: 'trace_123',\n  format: 'html_comment',\n});\n\n// Delete a link\nawait linking.delete('link_id');\n```\n\n### Link Methods and Confidence\n\n| Method | Confidence | Description |\n|--------|-----------|-------------|\n| `sdk_explicit` | 1.0 | Direct SDK call with ticket ID |\n| `zendesk_marker` | 1.0 | Embedded THID marker in response |\n| `custom_field` | 1.0 | Zendesk custom field |\n| `manual` | 1.0 | Human-assigned |\n| `middleware_stamp` | 0.98 | Middleware-injected trace ID |\n| `session_match` | 0.95 | Session ID correlation |\n| `email_time_window` | 0.6 | Email + 15min window |\n\n## ROI Analytics (V3)\n\nConfigurable ROI calculation engine with customizable cost models, deflection definitions, and attribution rules.\n\n### Configuration\n\n```typescript\nimport { roiAnalytics } from '@thinkhive/sdk';\n\n// Get active ROI config (auto-provisions default if none exists)\nconst config = await roiAnalytics.getConfig();\n\n// Create custom ROI config\nconst newConfig = await roiAnalytics.createConfig({\n  costConfig: {\n    humanAgentCostPerHour: 35,\n    aiCostPer1kTokens: 0.01,\n    escalationCostMultiplier: 2.5,\n    infrastructureMonthlyCost: 200,\n  },\n  deflectionConfig: {\n    definition: 'resolved_without_human',\n    outcomesThatCount: ['resolved'],\n    minConfidence: 0.8,\n    excludeEscalated: true,\n  },\n  resolutionConfig: {\n    definition: 'customer_confirmed',\n    requiresSatisfaction: false,\n    minSatisfactionScore: null,\n    noRecontactWindowHours: 24,\n  },\n  attributionConfig: {\n    timeSavedValuePerHour: 50,\n    churnPreventionAttribution: 0.2,\n    upsellAttribution: 0.1,\n    useActualARR: true,\n    defaultARRIfUnknown: 10000,\n  },\n});\n\n// Update config (creates new version, keeps history)\nconst updated = await roiAnalytics.updateConfig({\n  costConfig: { humanAgentCostPerHour: 40 },\n});\n\n// List config version history\nconst versions = await roiAnalytics.configVersions({ limit: 10 });\n```\n\n### Calculate ROI\n\n```typescript\n// Calculate ROI for a date range\nconst result = await roiAnalytics.calculateV3({\n  startDate: '2025-01-01',\n  endDate: '2025-02-01',\n  includeBreakdown: true,\n  includeConfidenceIntervals: false,\n});\n\nconsole.log(`Net ROI: $${result.summary.netROI}`);\nconsole.log(`ROI %: ${result.summary.roiPercentage}%`);\nconsole.log(`Deflection Rate: ${result.metrics.deflectionRate}`);\nconsole.log(`Total Runs: ${result.metrics.totalRuns}`);\n\n// Filter by agent\nconst agentROI = await roiAnalytics.calculateV3({\n  agentId: 'support-agent',\n  startDate: '2025-01-01',\n  endDate: '2025-02-01',\n});\n```\n\n### ROI Trends\n\n```typescript\n// Get ROI trend over time\nconst trend = await roiAnalytics.trendV3({\n  granularity: 'day', // 'day' | 'week' | 'month'\n  startDate: '2025-01-01',\n  endDate: '2025-02-01',\n});\n\nfor (const bucket of trend.trend) {\n  console.log(`${bucket.periodStart}: ${bucket.runCount} runs, $${bucket.netROI} ROI`);\n}\n\nif (trend.comparison) {\n  console.log(`Improving: ${trend.comparison.isImproving}`);\n  console.log(`Change: ${trend.comparison.changePercent}%`);\n}\n```\n\n### Legacy V1 ROI (still available)\n\n```typescript\n// V1 summary endpoint\nconst summary = await roiAnalytics.summary({\n  startDate: '2025-01-01',\n  endDate: '2025-01-31',\n});\n\n// V1 trends\nconst trends = await roiAnalytics.trends({\n  startDate: '2025-01-01',\n  endDate: '2025-01-31',\n});\n\n// V1 per-trace ROI calculation\nconst impact = await roiAnalytics.calculate({\n  traceId: 'trace_abc123',\n});\n\n// V1 industry configs\nconst industries = await roiAnalytics.industries();\n\n// V1 correlation analysis\nconst correlations = await roiAnalytics.correlations();\n```\n\n## Manual Tracing\n\n```typescript\nimport { traceLLM, traceRetrieval, traceTool, traceChain } from '@thinkhive/sdk';\n\n// Trace an LLM call\nconst response = await traceLLM({\n  name: 'generate-response',\n  modelName: 'gpt-4',\n  provider: 'openai',\n  input: { prompt: 'Hello!' }\n}, async () => {\n  return await openai.chat.completions.create({...});\n});\n\n// Trace a retrieval operation\nconst docs = await traceRetrieval({\n  name: 'search-knowledge-base',\n  query: 'refund policy',\n  topK: 5\n}, async () => {\n  return await vectorStore.similaritySearch(query, 5);\n});\n\n// Trace a tool call\nconst result = await traceTool({\n  name: 'lookup-order',\n  toolName: 'order_lookup',\n  parameters: { orderId: '12345' }\n}, async () => {\n  return await lookupOrder('12345');\n});\n\n// Trace a chain/workflow\nconst output = await traceChain({\n  name: 'support-workflow',\n  input: { query: 'help with refund' }\n}, async () => {\n  const docs = await retrieveContext(query);\n  return await generateResponse(docs);\n});\n```\n\n## Analyzer API\n\n```typescript\nimport { analyzer } from '@thinkhive/sdk';\n\n// Estimate cost before running analysis\nconst estimate = await analyzer.estimateCost({\n  traceIds: ['trace-1', 'trace-2'],\n  tier: 'standard',\n});\nconsole.log(`Estimated cost: $${estimate.estimatedCost}`);\n\n// Analyze specific traces\nconst analysis = await analyzer.analyze({\n  traceIds: ['trace-1', 'trace-2'],\n  tier: 'standard',\n  includeRootCause: true,\n  includeLayers: true,\n});\n\n// Analyze traces by time window with smart sampling\nconst windowAnalysis = await analyzer.analyzeWindow({\n  agentId: 'support-agent',\n  startDate: new Date('2025-01-01'),\n  endDate: new Date('2025-01-31'),\n  filters: { outcomes: ['failure'], minSeverity: 'medium' },\n  sampling: { strategy: 'smart', samplePercent: 10 },\n});\n\n// Get aggregated insights\nconst summary = await analyzer.summarize({\n  agentId: 'support-agent',\n  startDate: new Date('2025-01-01'),\n  endDate: new Date('2025-01-31'),\n});\n```\n\n## Issues API\n\n```typescript\nimport { issues } from '@thinkhive/sdk';\n\nconst issueList = await issues.list('support-agent', { status: 'open', limit: 10 });\nconst issue = await issues.get('issue-123');\nconst fixes = await issues.getFixes('issue-123');\n```\n\n## API Keys\n\n```typescript\nimport { apiKeys, hasPermission, canAccessAgent } from '@thinkhive/sdk';\n\nconst result = await apiKeys.create({\n  name: 'CI Pipeline Key',\n  permissions: { read: true, write: true, delete: false },\n  scopeType: 'agent',\n  allowedAgentIds: ['agent-prod-001'],\n  environment: 'production',\n  expiresAt: new Date(Date.now() + 90 * 24 * 60 * 60 * 1000),\n});\n\nif (hasPermission(key, 'write')) { /* can write */ }\nif (canAccessAgent(key, 'agent-123')) { /* can access */ }\n```\n\n## Business Metrics\n\n```typescript\nimport { businessMetrics, isMetricReady, getStatusMessage } from '@thinkhive/sdk';\n\nconst metric = await businessMetrics.current('agent-123', 'Deflection Rate');\nconst history = await businessMetrics.history('agent-123', 'Deflection Rate', {\n  startDate: new Date(Date.now() - 30 * 24 * 60 * 60 * 1000),\n  granularity: 'daily',\n});\n\nawait businessMetrics.record('agent-123', {\n  metricName: 'CSAT/NPS',\n  value: 4.5,\n  unit: 'score',\n  periodStart: '2025-01-01T00:00:00Z',\n  periodEnd: '2025-01-07T23:59:59Z',\n  source: 'survey_system',\n});\n```\n\n## Auto-Instrumentation\n\n```typescript\nimport { init } from '@thinkhive/sdk';\n\ninit({\n  apiKey: 'thk_your_api_key',\n  serviceName: 'my-ai-agent',\n  autoInstrument: true,\n  frameworks: ['langchain', 'openai', 'anthropic'],\n});\n// All LangChain, OpenAI, and Anthropic calls are now automatically traced\n```\n\n## Sub-package Imports\n\n```typescript\n// OpenAI instrumentation\nimport { instrumentOpenAIClient } from '@thinkhive/sdk/instrumentation/openai';\n\n// LangChain instrumentation\nimport { ThinkHiveCallbackHandler } from '@thinkhive/sdk/instrumentation/langchain';\n\n// Ticket linking (standalone)\nimport { linking, generateZendeskMarker } from '@thinkhive/sdk/integrations/ticket-linking';\n\n// Customer context (standalone)\nimport { customerContext, captureCustomerContext } from '@thinkhive/sdk/integrations/customer-context';\n```\n\n## Environment Variables\n\n| Variable | Description |\n|----------|-------------|\n| `THINKHIVE_API_KEY` | Your ThinkHive API key |\n| `THINKHIVE_ENDPOINT` | Custom API endpoint (default: `https://app.thinkhive.ai`) |\n| `THINKHIVE_SERVICE_NAME` | Service name for traces (optional) |\n| `THINKHIVE_AGENT_ID` | Default agent ID (optional) |\n\n## Eval Runs\n\n```typescript\nimport { evalRuns } from '@thinkhive/sdk';\n\n// Create an evaluation run\nconst run = await evalRuns.create('agent-123', { confidenceLevel: 'medium' });\n\n// Get results\nconst results = await evalRuns.getResults(run.id, { limit: 50 });\n\n// Estimate cost before running\nconst cost = await evalRuns.estimateCost('agent-123', { confidenceLevel: 'high' });\n\n// List recent runs\nconst runs = await evalRuns.list({ agentId: 'agent-123', limit: 10 });\n```\n\n## Signals\n\n```typescript\nimport { signals } from '@thinkhive/sdk';\n\n// List all signals\nconst allSignals = await signals.list();\n\n// Create a custom behavioral signal\nawait signals.create('Escalation Request', 'negative', {\n  type: 'keywords',\n  keywords: ['speak to manager', 'escalate'],\n});\n\n// Get signal stats and trends\nconst stats = await signals.getStats({ agentId: 'agent-123' });\nconst trends = await signals.getTrends({ granularity: 'daily' });\n```\n\n## Notifications\n\n```typescript\nimport { notifications } from '@thinkhive/sdk';\n\n// Create an alert rule\nawait notifications.createRule({\n  agentId: 'agent-123',\n  name: 'High failure rate alert',\n  eventType: 'failure_spike',\n  condition: { threshold: 0.3 },\n  channel: 'email',\n  target: 'team@company.com',\n});\n\n// List notifications\nconst alerts = await notifications.list('agent-123', true);\n// or: await notifications.listNotifications('agent-123', true);\n```\n\n## Documents (RAG)\n\n```typescript\nimport { documents } from '@thinkhive/sdk';\n\n// Upload a document\nawait documents.upload('agent-123', 'faq.txt', 'text/plain', 1024);\n\n// List agent documents\nconst docs = await documents.list('agent-123');\n\n// Delete a document\nawait documents.remove('agent-123', 'doc-456');\n```\n\n## Shadow Tests\n\n```typescript\nimport { shadowTests } from '@thinkhive/sdk';\n\n// Create a shadow test\nawait shadowTests.create({\n  fixId: 'fix-456',\n  agentId: 'agent-123',\n  testName: 'Refund policy test',\n  inputData: { message: 'How do I get a refund?' },\n  expectedOutput: 'You can request a refund within 30 days.',\n});\n\n// List tests for an agent\nconst tests = await shadowTests.list('agent-123');\n```\n\n## Sessions\n\n```typescript\nimport { sessions } from '@thinkhive/sdk';\n\n// List conversation sessions\nconst allSessions = await sessions.list('agent-123', { limit: 20 });\n\n// Get all traces in a session\nconst traces = await sessions.getTraces('session-789', 'agent-123');\n```\n\n## Drift Detection\n\n```typescript\nimport { drift, hasDrift, getDriftSeverity } from '@thinkhive/sdk';\n\n// Detect drift for an agent\nconst report = await drift.detect('agent-123');\nif (hasDrift(report)) {\n  console.log(`Drift severity: ${getDriftSeverity(report)}`);\n}\n\n// Detect drift across all agents\nconst allDrift = await drift.detectAll();\n```\n\n## LLM Costs\n\n```typescript\nimport { llmCosts, formatCost } from '@thinkhive/sdk';\n\n// Get cost summary\nconst summary = await llmCosts.summary({ period: '30d' });\n// or: await llmCosts.getSummary({ period: '30d' });\nconsole.log(`Total cost: ${formatCost(summary.totalCost)}`);\n\n// Get per-agent breakdown\nconst breakdown = await llmCosts.getBreakdown('agent-123');\n\n// Get optimization savings\nconst savings = await llmCosts.getSavings();\n```\n\n## Error Handling\n\n```typescript\nimport { ThinkHiveError, RateLimitError } from '@thinkhive/sdk';\n\ntry {\n  await runs.create({ /* ... */ });\n} catch (error) {\n  if (error instanceof RateLimitError) {\n    console.log(`Retry after ${error.retryAfter}ms`);\n  }\n}\n\n// Both forms work:\nthrow new RateLimitError(60000);\nthrow new RateLimitError('Custom message', 60000);\n```\n\n## Upgrading\n\n### v4.2.0 → v4.2.2\n\nImprovements in v4.2.2:\n- **`RateLimitError`** now accepts both `new RateLimitError(retryAfterMs)` and `new RateLimitError('message', retryAfterMs)` signatures\n- **Claims helpers** (`isFact`, `isInference`, `isComputed`) now accept both `{claimType: 'observed'}` (API format) and `{type: 'fact'}` (shorthand)\n- **`groupClaimsByType`** returns both API names (`observed`/`inferred`/`computed`) and shorthand names (`fact`/`inference`)\n- **`calculateBrierScore`** now accepts both single prediction `(probability, outcome)` and batch `([{predicted, actual}])` forms\n- **`calculateECE`** now accepts pre-computed bucket objects `[{averageConfidence, accuracy, count}]` in addition to raw predictions\n- **`isWellCalibrated`** accepts both a raw number and `{brierScore: number}` object\n- **`calculatePassAtK`** now supports both `(passRate, k)` and `(n, c, k)` calling conventions\n- **`isReliableEvaluation`** accepts both a CriterionAnalysis object and a raw reliability score\n- **Rule helpers** (`createRegexRule`, `createContainsRule`, `createLengthRule`, `createJsonSchemaRule`) now return named rule objects with `{type, name, config}` structure\n- **`allRulesPassed`** and **`getFailedRules`** accept any `{passed: boolean}` objects, not just `RuleResult[]`\n- **`aggregateWorst`** / **`aggregateAverage`** now accept simple `number[]` arrays in addition to `TurnEvaluation[]`\n- **Method aliases added** for cross-SDK consistency:\n  - `signals.delete()` (alias for `remove()`)\n  - `notifications.list()` (alias for `listNotifications()`)\n  - `llmCosts.summary()` (alias for `getSummary()`)\n  - `qualityMetrics.evaluate()` (alias for `evaluateRag()`)\n  - `guardrails.evaluate()` (alias for `scan()`)\n  - `customerContext.capture()` (alias for `captureSnapshot()`)\n\n### v4.1.0 → v4.2.0\n\nNew in v4.2.0:\n- **`evalRuns`** — create, list, and manage evaluation runs programmatically\n- **`signals`** — behavioral signal CRUD with stats and trends\n- **`notifications`** — alert rule configuration and notification management\n- **`documents`** — agent RAG document upload/list/delete\n- **`shadowTests`** — shadow test creation and management\n- **`sessions`** — trace session grouping and querying\n- **`drift`** — model/behavior drift detection with helpers\n- **`llmCosts`** — LLM usage cost tracking and optimization savings\n\n### v4.0 → v4.1.0\n\n- `roiAnalytics` now includes V3 methods: `getConfig()`, `createConfig()`, `updateConfig()`, `configVersions()`, `calculateV3()`, `trendV3()`\n- `linking` now includes: `autoLink()`, `stats()`, `generateMarker()`\n- GET `/roi/config` auto-provisions a default configuration if none exists\n- ROI date range limit increased to 92 days\n\n## License\n\nMIT License - see [LICENSE](LICENSE) for details.\n","readmeFilename":"README.md"}