@yyc3/ai-family-kernel 0.0.0-stage → 2.52.0
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/README.md +11 -2
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/index.d.ts +24 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/index.js +24 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-1-foundation/foundation-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-1-foundation/foundation-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-1-foundation/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-1-foundation/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-2-bole/bole-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-2-bole/bole-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-2-bole/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-2-bole/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-3-prophet/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-3-prophet/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-3-prophet/prophet-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-3-prophet/prophet-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-4-thinker/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-4-thinker/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-4-thinker/thinker-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-4-thinker/thinker-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-5-navigator/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-5-navigator/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-5-navigator/navigator-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-5-navigator/navigator-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-6-creative/creative-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-6-creative/creative-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-6-creative/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-6-creative/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-7-master/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-7-master/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-7-master/master-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-7-master/master-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-8-guardian/guardian-capability.d.ts +16 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-8-guardian/guardian-capability.js +29 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-8-guardian/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-8-guardian/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-9-meta-oracle/index.d.ts +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-9-meta-oracle/index.js +4 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-9-meta-oracle/meta-oracle-capability.d.ts +17 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-9-meta-oracle/meta-oracle-capability.js +30 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-registry.d.ts +34 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/layer-registry.js +76 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/types.d.ts +49 -0
- package/dist/src/01-/344/271/235/345/261/202/346/236/266/346/236/204/345/210/206/345/261/202/345/272/225/345/272/247/types.js +33 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/index.d.ts +7 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/index.js +7 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/orchestrator.d.ts +47 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/orchestrator.js +59 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/task-decomposer.d.ts +21 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/task-decomposer.js +72 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/confidence-calibrator.d.ts +31 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/confidence-calibrator.js +39 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/consistency-metrics.d.ts +45 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/consistency-metrics.js +44 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/cross-validator.d.ts +44 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/cross-validator.js +69 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/gateway.d.ts +64 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/gateway.js +96 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/ground-truth-checker.d.ts +33 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/ground-truth-checker.js +74 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/index.d.ts +12 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/index.js +12 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/oracle-registry.d.ts +18 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/cloud-pivot-orchestrator/verification-gateway/oracle-registry.js +26 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/dashu-self-healing/index.d.ts +5 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/dashu-self-healing/index.js +5 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/dashu-self-healing/self-healing-controller.d.ts +33 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/dashu-self-healing/self-healing-controller.js +68 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/event-bus.d.ts +99 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/event-bus.js +178 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/index.d.ts +7 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/index.js +7 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/trajectory-bridge.d.ts +57 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-communication-bus/trajectory-bridge.js +72 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-phone-system/index.d.ts +4 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-phone-system/index.js +4 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-phone-system/phone-system.d.ts +46 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/family-phone-system/phone-system.js +85 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/global-status-center/index.d.ts +4 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/global-status-center/index.js +4 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/global-status-center/status-center.d.ts +27 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/global-status-center/status-center.js +57 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/index.d.ts +21 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/index.js +21 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/bus-mcp-codec.d.ts +29 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/bus-mcp-codec.js +84 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/index.d.ts +31 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/index.js +28 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/server/index.d.ts +5 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/server/index.js +5 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/server/protocol.d.ts +80 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/server/protocol.js +148 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/stdio-transport.d.ts +47 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/stdio-transport.js +178 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/types.d.ts +63 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/mcp-adapter/types.js +7 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/types.d.ts +167 -0
- package/dist/src/02-/344/272/221/346/236/242/346/240/270/345/277/203/345/274/225/346/223/216/types.js +23 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/index.d.ts +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/index.js +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/outcome-labeler.d.ts +34 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/outcome-labeler.js +38 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/pattern-extractor.d.ts +64 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/pattern-extractor.js +94 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/trajectory-collector.d.ts +39 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/experience-reflow/trajectory-collector.js +36 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/index.d.ts +23 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/index.js +23 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/index.d.ts +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/index.js +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/preference-tracker.d.ts +32 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/preference-tracker.js +49 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/rule-evolution.d.ts +41 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/rule-evolution.js +60 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/semantic-diff.d.ts +32 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/knowledge-update/semantic-diff.js +69 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-loop.d.ts +146 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-loop.js +171 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/budget-allocator.d.ts +29 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/budget-allocator.js +58 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/index.d.ts +6 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/index.js +6 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/priority-queue.d.ts +22 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/learning-scheduler/priority-queue.js +34 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/param-adaptation.d.ts +59 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/param-adaptation.js +55 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/index.d.ts +12 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/index.js +12 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-eval.d.ts +77 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-eval.js +110 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-executor.d.ts +51 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-executor.js +63 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-id.d.ts +32 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-id.js +54 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-index.d.ts +29 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-index.js +32 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-merger.d.ts +26 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-merger.js +65 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-pruner.d.ts +31 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-pruner.js +35 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-store-file.d.ts +33 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-store-file.js +76 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-versioner.d.ts +33 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/skill-consolidation/skill-versioner.js +63 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/forgetting-detector.d.ts +31 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/forgetting-detector.js +26 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/index.d.ts +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/index.js +7 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/regression-tester.d.ts +30 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/regression-tester.js +48 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/rollback-controller.d.ts +19 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/stability-guard/rollback-controller.js +19 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/types.d.ts +137 -0
- package/dist/src/05-/346/214/201/347/273/255/345/255/246/344/271/240/345/274/225/346/223/216/types.js +22 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/compliance-audit/compliance-audit.d.ts +20 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/compliance-audit/compliance-audit.js +83 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/compliance-audit/index.d.ts +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/compliance-audit/index.js +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/index.d.ts +18 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/index.js +18 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/index.d.ts +6 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/index.js +6 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/policy-bus.d.ts +39 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/policy-bus.js +73 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/policy-registry.d.ts +19 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/policy-registry.js +44 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/security-policies.d.ts +54 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/policy-registry/security-policies.js +80 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/quality-governance/index.d.ts +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/quality-governance/index.js +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/quality-governance/quality-governance.d.ts +23 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/quality-governance/quality-governance.js +38 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/security-governance/index.d.ts +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/security-governance/index.js +4 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/security-governance/security-governance.d.ts +24 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/security-governance/security-governance.js +29 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/types.d.ts +77 -0
- package/dist/src/06-/346/262/273/347/220/206/344/270/255/345/277/203/types.js +17 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/consistency-repair/consistency-repair.d.ts +25 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/consistency-repair/consistency-repair.js +66 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/consistency-repair/index.d.ts +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/consistency-repair/index.js +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/degradation-controller/degradation-controller.d.ts +50 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/degradation-controller/degradation-controller.js +90 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/degradation-controller/index.d.ts +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/degradation-controller/index.js +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/fault-detector/fault-detector.d.ts +42 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/fault-detector/fault-detector.js +55 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/fault-detector/index.d.ts +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/fault-detector/index.js +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/index.d.ts +19 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/index.js +19 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/rollback-controller/index.d.ts +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/rollback-controller/index.js +4 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/rollback-controller/rollback-controller.d.ts +36 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/rollback-controller/rollback-controller.js +71 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/types.d.ts +73 -0
- package/dist/src/07-/350/207/252/346/204/210/344/270/255/345/277/203/types.js +63 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/index.d.ts +5 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/index.js +5 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/mcp-server-assembly.d.ts +48 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/mcp-server-assembly.js +53 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/runtime-assembly.d.ts +175 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/runtime-assembly.js +249 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/runtime-entry.d.ts +68 -0
- package/dist/src/08-/347/263/273/347/273/237/350/243/205/351/205/215/runtime-entry.js +86 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/capability-instrumentation.d.ts +53 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/capability-instrumentation.js +85 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/collaboration-instrumentation.d.ts +56 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/collaboration-instrumentation.js +100 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/family-metrics.d.ts +172 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/family-metrics.js +313 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/index.d.ts +8 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/index.js +8 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/metrics-registry.d.ts +123 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/metrics-registry.js +270 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/metrics-server.d.ts +45 -0
- package/dist/src/09-/345/217/257/350/247/202/346/265/213/346/200/247/metrics-server.js +86 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/allowlist.d.ts +79 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/allowlist.js +122 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/catalog.d.ts +67 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/catalog.js +71 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/index.d.ts +14 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/index.js +10 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/integrity.d.ts +44 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/integrity.js +99 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/plugin-loader.d.ts +39 -0
- package/dist/src/10-/350/203/275/345/212/233/346/263/250/345/206/214/344/270/255/345/277/203/plugin-loader.js +89 -0
- package/dist/src/a2a-adapter/card-discovery.d.ts +40 -0
- package/dist/src/a2a-adapter/card-discovery.js +47 -0
- package/dist/src/a2a-adapter/index.d.ts +7 -0
- package/dist/src/a2a-adapter/index.js +7 -0
- package/dist/src/a2a-adapter/task-delegate.d.ts +85 -0
- package/dist/src/a2a-adapter/task-delegate.js +94 -0
- package/dist/src/index.d.ts +10 -0
- package/dist/src/index.js +10 -0
- package/dist/vendor/memory-framework/episodic-store/episode-indexer.d.ts +30 -0
- package/dist/vendor/memory-framework/episodic-store/episode-indexer.js +45 -0
- package/dist/vendor/memory-framework/episodic-store/index.d.ts +30 -0
- package/dist/vendor/memory-framework/episodic-store/index.js +45 -0
- package/dist/vendor/memory-framework/episodic-store/retrieval-adapter.d.ts +20 -0
- package/dist/vendor/memory-framework/episodic-store/retrieval-adapter.js +29 -0
- package/dist/vendor/memory-framework/episodic-store/trajectory-logger.d.ts +36 -0
- package/dist/vendor/memory-framework/episodic-store/trajectory-logger.js +32 -0
- package/dist/vendor/memory-framework/index.d.ts +19 -0
- package/dist/vendor/memory-framework/index.js +19 -0
- package/dist/vendor/memory-framework/memory-orchestrator/consistency-checker.d.ts +20 -0
- package/dist/vendor/memory-framework/memory-orchestrator/consistency-checker.js +41 -0
- package/dist/vendor/memory-framework/memory-orchestrator/index.d.ts +55 -0
- package/dist/vendor/memory-framework/memory-orchestrator/index.js +185 -0
- package/dist/vendor/memory-framework/memory-orchestrator/retrieval-router.d.ts +21 -0
- package/dist/vendor/memory-framework/memory-orchestrator/retrieval-router.js +37 -0
- package/dist/vendor/memory-framework/procedural-memory/guardrail-registry.d.ts +34 -0
- package/dist/vendor/memory-framework/procedural-memory/guardrail-registry.js +22 -0
- package/dist/vendor/memory-framework/procedural-memory/index.d.ts +31 -0
- package/dist/vendor/memory-framework/procedural-memory/index.js +34 -0
- package/dist/vendor/memory-framework/procedural-memory/prompt-rule-extractor.d.ts +95 -0
- package/dist/vendor/memory-framework/procedural-memory/prompt-rule-extractor.js +160 -0
- package/dist/vendor/memory-framework/procedural-memory/skill-registry.d.ts +115 -0
- package/dist/vendor/memory-framework/procedural-memory/skill-registry.js +165 -0
- package/dist/vendor/memory-framework/procedural-memory/workflow-patterns.d.ts +36 -0
- package/dist/vendor/memory-framework/procedural-memory/workflow-patterns.js +22 -0
- package/dist/vendor/memory-framework/semantic-graph/entity-resolver.d.ts +26 -0
- package/dist/vendor/memory-framework/semantic-graph/entity-resolver.js +61 -0
- package/dist/vendor/memory-framework/semantic-graph/index.d.ts +23 -0
- package/dist/vendor/memory-framework/semantic-graph/index.js +25 -0
- package/dist/vendor/memory-framework/semantic-graph/knowledge-graph.d.ts +50 -0
- package/dist/vendor/memory-framework/semantic-graph/knowledge-graph.js +44 -0
- package/dist/vendor/memory-framework/sensory-buffer/index.d.ts +41 -0
- package/dist/vendor/memory-framework/sensory-buffer/index.js +70 -0
- package/dist/vendor/memory-framework/types.d.ts +192 -0
- package/dist/vendor/memory-framework/types.js +42 -0
- package/dist/vendor/memory-framework/working-context/attention-scorer.d.ts +39 -0
- package/dist/vendor/memory-framework/working-context/attention-scorer.js +45 -0
- package/dist/vendor/memory-framework/working-context/context-window.d.ts +33 -0
- package/dist/vendor/memory-framework/working-context/context-window.js +35 -0
- package/dist/vendor/memory-framework/working-context/index.d.ts +30 -0
- package/dist/vendor/memory-framework/working-context/index.js +44 -0
- package/dist/vendor/memory-framework/write-policy/consolidation.d.ts +37 -0
- package/dist/vendor/memory-framework/write-policy/consolidation.js +50 -0
- package/dist/vendor/memory-framework/write-policy/forgetting-policy.d.ts +28 -0
- package/dist/vendor/memory-framework/write-policy/forgetting-policy.js +31 -0
- package/dist/vendor/memory-framework/write-policy/index.d.ts +40 -0
- package/dist/vendor/memory-framework/write-policy/index.js +50 -0
- package/dist/vendor/memory-framework/write-policy/salience-scorer.d.ts +41 -0
- package/dist/vendor/memory-framework/write-policy/salience-scorer.js +70 -0
- package/dist/vendor/self-judge-kit/assumption-tracker.d.ts +31 -0
- package/dist/vendor/self-judge-kit/assumption-tracker.js +45 -0
- package/dist/vendor/self-judge-kit/confidence-scorer.d.ts +46 -0
- package/dist/vendor/self-judge-kit/confidence-scorer.js +60 -0
- package/dist/vendor/self-judge-kit/deviation-detector.d.ts +23 -0
- package/dist/vendor/self-judge-kit/deviation-detector.js +55 -0
- package/dist/vendor/self-judge-kit/escalation-policy.d.ts +17 -0
- package/dist/vendor/self-judge-kit/escalation-policy.js +45 -0
- package/dist/vendor/self-judge-kit/index.d.ts +46 -0
- package/dist/vendor/self-judge-kit/index.js +79 -0
- package/dist/vendor/self-judge-kit/types.d.ts +87 -0
- package/dist/vendor/self-judge-kit/types.js +18 -0
- package/package.json +41 -4
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 家族业务指标集(family-metrics)——「09-可观测性」业务埋点门面(v2.7.0,P0 数据面)。
|
|
3
|
+
* 职责:把五支柱运行时事件翻译为 `family_*` 指标(Counter / Gauge / Histogram),
|
|
4
|
+
* 供 Prometheus 抓取、告警规则消费(ops/observability/prometheus-rules.yaml)。
|
|
5
|
+
* 边界:只记录;指标存储归 metrics-registry,HTTP 暴露归 metrics-server。
|
|
6
|
+
*
|
|
7
|
+
* 指标 → 告警映射(§P0 数据面闭环):
|
|
8
|
+
* family_task_execution_duration_seconds → HighPerfP99Latency
|
|
9
|
+
* family_task_executed_total{outcome} → HighAvailabilityErrorRate
|
|
10
|
+
* family_selfjudge_agreement_ratio → SelfJudgeCalibrationDrift
|
|
11
|
+
* family_memory_retrieval_duration_seconds → MemoryRetrievalSlow
|
|
12
|
+
* family_learning_regression_failed_cases → LearningRegressionFailure
|
|
13
|
+
* family_regression_gate_failed_total(CI 侧) → RegressionGateFailed
|
|
14
|
+
* family_pillar_failed_cases{pillar}(CI 侧) → FivePillarDashboardRed
|
|
15
|
+
* family_capability_plugin_denied_total → CapabilityPluginDenied
|
|
16
|
+
*
|
|
17
|
+
* 五维映射(P1-T4):19 项运行时 + 2 项 CI 指标的主维归属见
|
|
18
|
+
* assets/schemas/five-dimension-map.json(时间/空间/属性/事件/关联);
|
|
19
|
+
* 协同度 4 项(v2.14.0):clarify / human-confirm / trace / replay,由
|
|
20
|
+
* `recordCollaboration(kind, hit)` 按「命中/总数」折算为 0..1 的 Gauge。
|
|
21
|
+
* 生产端接线(P1-T4b):千行澄清 / self-judge escalation / 审计链 / 学习回流
|
|
22
|
+
* 见 collaboration-instrumentation.ts(四个零侵入 Proxy 仪表);
|
|
23
|
+
* 复盘回流为两端记账——桥接受理=决策周期(recordReplay(1,0) 分母)、
|
|
24
|
+
* 回流标注=已复盘(recordReplay(0,1) 分子),见 runtime-assembly。
|
|
25
|
+
*/
|
|
26
|
+
import { MetricsRegistry } from './metrics-registry.js';
|
|
27
|
+
/** 记忆检索耗时分桶(毫秒级操作,秒为单位:10ms~5s)。 */
|
|
28
|
+
const MEMORY_BUCKETS = [0.01, 0.025, 0.05, 0.1, 0.2, 0.3, 0.5, 1, 2.5, 5];
|
|
29
|
+
/** 家族业务指标集。 */
|
|
30
|
+
export class FamilyMetrics {
|
|
31
|
+
registry;
|
|
32
|
+
/** 任务执行结果计数(outcome=completed|failed)。 */
|
|
33
|
+
taskExecuted;
|
|
34
|
+
/** 任务执行时长(finishedAt - startedAt,秒)。 */
|
|
35
|
+
taskDuration;
|
|
36
|
+
/** 总线-轨迹桥接事件(result=accepted|rejected)。 */
|
|
37
|
+
bridgeEvents;
|
|
38
|
+
/** 学习周期数。 */
|
|
39
|
+
learningCycles;
|
|
40
|
+
/** 固化技能数。 */
|
|
41
|
+
learningPromoted;
|
|
42
|
+
/** 回滚技能数。 */
|
|
43
|
+
learningRolledBack;
|
|
44
|
+
/** 本周期回归失败用例数(>0 触发告警)。 */
|
|
45
|
+
regressionFailedCases;
|
|
46
|
+
/** 自评-外验一致率(Phase B 门禁 > 90%)。 */
|
|
47
|
+
agreementRatio;
|
|
48
|
+
/** 海市蜃楼累计数(快照值)。 */
|
|
49
|
+
mirageCount;
|
|
50
|
+
/** 记忆检索耗时(秒)。 */
|
|
51
|
+
memoryRetrieval;
|
|
52
|
+
/** 自愈动作(layer × status)。 */
|
|
53
|
+
healingActions;
|
|
54
|
+
/** 自愈 RTO(秒,按层)。 */
|
|
55
|
+
healingRto;
|
|
56
|
+
/** RTO 契约达成(1/0,按层)。 */
|
|
57
|
+
healingContractMet;
|
|
58
|
+
/** 熔断器状态(state=closed|half-open|open,当前态为 1)。 */
|
|
59
|
+
circuitState;
|
|
60
|
+
/** 协同度 · 澄清率(0..1)。 */
|
|
61
|
+
clarifyRate;
|
|
62
|
+
/** 协同度 · 人工确认率(0..1)。 */
|
|
63
|
+
humanConfirmRate;
|
|
64
|
+
/** 协同度 · traceId 覆盖率(0..1)。 */
|
|
65
|
+
traceCoverage;
|
|
66
|
+
/** 协同度 · 复盘回流覆盖率(0..1)。 */
|
|
67
|
+
replayCoverage;
|
|
68
|
+
/** 能力供给 · 技能加载次数(skill 标签,§6.3)。 */
|
|
69
|
+
capabilitySkillsLoaded;
|
|
70
|
+
/** 能力供给 · MCP 工具调用次数(result=ok|error)。 */
|
|
71
|
+
capabilityMcpToolCalls;
|
|
72
|
+
/** 能力供给 · 能力包准入拒绝次数(allowlist enforce,§6.3)。 */
|
|
73
|
+
capabilityPluginDenied;
|
|
74
|
+
/** 语义执行 · LLM 步骤执行次数(skill 标签,M19)。 */
|
|
75
|
+
llmSteps;
|
|
76
|
+
/** 语义执行 · LLM 输出字段填充率(0..1,M19)。 */
|
|
77
|
+
llmFillRatio;
|
|
78
|
+
/** 语义执行 · LLM token 用量(agent_id/skill_id/scenario 三维分组,E0b 计量分口径)。 */
|
|
79
|
+
llmUsageTokens;
|
|
80
|
+
/** 语义执行 · LLM 调用次数(三维分组,E0b)。 */
|
|
81
|
+
llmUsageCalls;
|
|
82
|
+
/** 协同度累计(kind → total/hit)。 */
|
|
83
|
+
collaboration = new Map();
|
|
84
|
+
/** Exemplar 丢弃计数(仅在启用 exemplar 时注册)。 */
|
|
85
|
+
exemplarsDropped;
|
|
86
|
+
exemplarEnabled;
|
|
87
|
+
constructor(registry = new MetricsRegistry(), options = {}) {
|
|
88
|
+
const ex = options.exemplars ?? {};
|
|
89
|
+
this.exemplarEnabled = ex.enabled === true;
|
|
90
|
+
const exemplarOptions = this.exemplarEnabled
|
|
91
|
+
? {
|
|
92
|
+
enabled: true,
|
|
93
|
+
maxPerBucket: ex.maxPerBucket,
|
|
94
|
+
ttlMs: ex.ttlMs,
|
|
95
|
+
onDrop: () => this.exemplarsDropped?.inc(),
|
|
96
|
+
}
|
|
97
|
+
: { enabled: false };
|
|
98
|
+
this.registry = registry;
|
|
99
|
+
if (this.exemplarEnabled) {
|
|
100
|
+
this.exemplarsDropped = registry.counter('family_exemplars_dropped_total', 'Exemplar 超出每桶上限被丢弃的累计数');
|
|
101
|
+
}
|
|
102
|
+
this.taskExecuted = registry.counter('family_task_executed_total', '任务执行结果计数(outcome=completed|failed)');
|
|
103
|
+
this.taskDuration = registry.histogram('family_task_execution_duration_seconds', '任务执行时长(finishedAt-startedAt,秒)', undefined, exemplarOptions);
|
|
104
|
+
this.bridgeEvents = registry.counter('family_trajectory_bridge_events_total', '总线-轨迹桥接事件(result=accepted|rejected)');
|
|
105
|
+
this.learningCycles = registry.counter('family_learning_cycles_total', '学习周期执行次数');
|
|
106
|
+
this.learningPromoted = registry.counter('family_learning_promoted_total', '固化技能累计数');
|
|
107
|
+
this.learningRolledBack = registry.counter('family_learning_rolled_back_total', '回滚技能累计数');
|
|
108
|
+
this.regressionFailedCases = registry.gauge('family_learning_regression_failed_cases', '本周期学习回归失败用例数');
|
|
109
|
+
this.agreementRatio = registry.gauge('family_selfjudge_agreement_ratio', '自评-外验一致率(Phase B 门禁 > 0.9)');
|
|
110
|
+
this.mirageCount = registry.gauge('family_selfjudge_mirage_total', '海市蜃楼累计命中数');
|
|
111
|
+
this.memoryRetrieval = registry.histogram('family_memory_retrieval_duration_seconds', '记忆检索耗时(秒)', MEMORY_BUCKETS, exemplarOptions);
|
|
112
|
+
this.healingActions = registry.counter('family_healing_actions_total', '自愈动作计数(layer × status)');
|
|
113
|
+
this.healingRto = registry.gauge('family_healing_rto_seconds', '自愈 RTO(秒,按层)');
|
|
114
|
+
this.healingContractMet = registry.gauge('family_healing_contract_met', 'RTO 契约达成(1=达成 / 0=未达成)');
|
|
115
|
+
this.circuitState = registry.gauge('family_circuit_state', '熔断器当前状态(state=closed|half-open|open)');
|
|
116
|
+
this.clarifyRate = registry.gauge('family_collaboration_clarify_rate', '澄清率:触发澄清的请求 / 全部请求(0..1)');
|
|
117
|
+
this.humanConfirmRate = registry.gauge('family_collaboration_human_confirm_rate', '人工确认率:关键决策经人终审 / 全部关键决策(0..1)');
|
|
118
|
+
this.traceCoverage = registry.gauge('family_collaboration_trace_coverage', 'traceId 覆盖率:可追溯至审计链的决策 / 全部决策(0..1)');
|
|
119
|
+
this.replayCoverage = registry.gauge('family_collaboration_replay_coverage', '复盘覆盖率:已回流学习的周期 / 全部决策周期(0..1)');
|
|
120
|
+
this.capabilitySkillsLoaded = registry.counter('family_capability_skills_loaded_total', '技能加载次数(skill 标签,§6.3 能力供给)');
|
|
121
|
+
this.capabilityMcpToolCalls = registry.counter('family_capability_mcp_tool_calls_total', 'MCP 工具调用次数(result=ok|error,§6.3 能力供给)');
|
|
122
|
+
this.capabilityPluginDenied = registry.counter('family_capability_plugin_denied_total', '能力包准入拒绝次数(allowlist enforce 模式,§6.3 能力供给)');
|
|
123
|
+
this.llmSteps = registry.counter('family_llm_steps_total', 'LLM 语义执行步骤次数(skill 标签,M19 观测增强)');
|
|
124
|
+
this.llmFillRatio = registry.gauge('family_llm_output_fill_ratio', 'LLM 语义执行输出字段填充率(0..1,M19 观测增强;告警基线 0.8)');
|
|
125
|
+
this.llmUsageTokens = registry.counter('family_llm_usage_tokens_total', 'LLM token 用量(agent_id/skill_id/scenario 三维分组 · E0b 计量分口径)');
|
|
126
|
+
this.llmUsageCalls = registry.counter('family_llm_usage_calls_total', 'LLM 调用次数(agent_id/skill_id/scenario 三维分组 · E0b 计量分口径)');
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* 人机协同度埋点(P1-T4):按「命中 / 总数」折算并写入对应 Gauge。
|
|
130
|
+
* 零样本时 Gauge 不产生样本行(`/metrics` 仅输出 HELP/TYPE),不污染默认口径。
|
|
131
|
+
*/
|
|
132
|
+
recordCollaboration(kind, hit) {
|
|
133
|
+
const cur = this.collaboration.get(kind) ?? { total: 0, hit: 0 };
|
|
134
|
+
const next = { total: cur.total + 1, hit: cur.hit + (hit ? 1 : 0) };
|
|
135
|
+
this.collaboration.set(kind, next);
|
|
136
|
+
this.collaborationGauge(kind).set(next.hit / next.total);
|
|
137
|
+
}
|
|
138
|
+
/** 协同度快照(测试与面板读取;零样本返回 rate=0)。 */
|
|
139
|
+
collaborationSnapshot() {
|
|
140
|
+
const kinds = ['clarification', 'human-confirm', 'trace', 'replay'];
|
|
141
|
+
return Object.fromEntries(kinds.map((kind) => {
|
|
142
|
+
const cur = this.collaboration.get(kind) ?? { total: 0, hit: 0 };
|
|
143
|
+
const rate = cur.total === 0 ? 0 : cur.hit / cur.total;
|
|
144
|
+
return [kind, { total: cur.total, hit: cur.hit, rate }];
|
|
145
|
+
}));
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* 复盘回流两端记账(P1-T4b 学习回流接线):
|
|
149
|
+
* collectedDelta = 决策周期入库(桥接受理侧,分母);labeledDelta = 已回流标注(分子)。
|
|
150
|
+
* 与 recordCollaboration 共用同一张累计表与 replay Gauge,口径一致。
|
|
151
|
+
*/
|
|
152
|
+
recordReplay(collectedDelta, labeledDelta) {
|
|
153
|
+
const cur = this.collaboration.get('replay') ?? { total: 0, hit: 0 };
|
|
154
|
+
const next = { total: cur.total + collectedDelta, hit: cur.hit + labeledDelta };
|
|
155
|
+
this.collaboration.set('replay', next);
|
|
156
|
+
if (next.total > 0)
|
|
157
|
+
this.replayCoverage.set(next.hit / next.total);
|
|
158
|
+
}
|
|
159
|
+
collaborationGauge(kind) {
|
|
160
|
+
switch (kind) {
|
|
161
|
+
case 'clarification':
|
|
162
|
+
return this.clarifyRate;
|
|
163
|
+
case 'human-confirm':
|
|
164
|
+
return this.humanConfirmRate;
|
|
165
|
+
case 'trace':
|
|
166
|
+
return this.traceCoverage;
|
|
167
|
+
case 'replay':
|
|
168
|
+
return this.replayCoverage;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* 桥接事件埋点(TrajectoryBridge.onEvent 直连)。
|
|
173
|
+
* 受理时同时记录任务结果与执行时长(payload 字段缺失则跳过时长)。
|
|
174
|
+
*/
|
|
175
|
+
recordBridgeEvent(event, accepted) {
|
|
176
|
+
this.bridgeEvents.inc({ result: accepted ? 'accepted' : 'rejected' });
|
|
177
|
+
if (!accepted)
|
|
178
|
+
return;
|
|
179
|
+
const p = event.payload;
|
|
180
|
+
if (!p || typeof p.completed !== 'boolean')
|
|
181
|
+
return;
|
|
182
|
+
this.taskExecuted.inc({ outcome: p.completed ? 'completed' : 'failed' });
|
|
183
|
+
if (typeof p.startedAt === 'number' && typeof p.finishedAt === 'number') {
|
|
184
|
+
const seconds = (p.finishedAt - p.startedAt) / 1000;
|
|
185
|
+
if (seconds >= 0) {
|
|
186
|
+
if (this.exemplarEnabled && event.key.traceId) {
|
|
187
|
+
this.taskDuration.observe(seconds, {}, {
|
|
188
|
+
value: seconds,
|
|
189
|
+
timestampMs: Date.now(),
|
|
190
|
+
labels: { trace_id: event.key.traceId },
|
|
191
|
+
});
|
|
192
|
+
}
|
|
193
|
+
else {
|
|
194
|
+
this.taskDuration.observe(seconds);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
/** 学习周期埋点(LearningLoop.onCycle 直连)。 */
|
|
200
|
+
recordCycle(report) {
|
|
201
|
+
this.learningCycles.inc();
|
|
202
|
+
this.learningPromoted.inc({}, report.promoted.length);
|
|
203
|
+
this.learningRolledBack.inc({}, report.rolledBack.length);
|
|
204
|
+
let failedCases = 0;
|
|
205
|
+
for (const r of report.regressions)
|
|
206
|
+
failedCases += r.regressions.length;
|
|
207
|
+
this.regressionFailedCases.set(failedCases);
|
|
208
|
+
}
|
|
209
|
+
/** 自愈记账埋点(RollbackController / DegradationController 产出)。 */
|
|
210
|
+
recordHealing(outcome) {
|
|
211
|
+
this.healingActions.inc({ layer: outcome.layer, status: outcome.status });
|
|
212
|
+
if (typeof outcome.rtoSeconds === 'number') {
|
|
213
|
+
this.healingRto.set(outcome.rtoSeconds, { layer: outcome.layer });
|
|
214
|
+
}
|
|
215
|
+
this.healingContractMet.set(outcome.contractMet ? 1 : 0, { layer: outcome.layer });
|
|
216
|
+
}
|
|
217
|
+
/** 熔断器状态埋点(三态互斥:当前态置 1,其余置 0)。 */
|
|
218
|
+
recordCircuitState(state) {
|
|
219
|
+
for (const s of ['closed', 'half-open', 'open']) {
|
|
220
|
+
this.circuitState.set(s === state ? 1 : 0, { state: s });
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
/** 能力供给 · 技能加载埋点(§6.3;接线:capability-instrumentation.instrumentSkillRegistry)。 */
|
|
224
|
+
recordSkillLoaded(skillId) {
|
|
225
|
+
this.capabilitySkillsLoaded.inc({ skill: skillId });
|
|
226
|
+
}
|
|
227
|
+
/** 能力供给 · MCP 工具调用埋点(§6.3;接线:capability-instrumentation.instrumentMcpDispatcher)。 */
|
|
228
|
+
recordMcpToolCall(result) {
|
|
229
|
+
this.capabilityMcpToolCalls.inc({ result });
|
|
230
|
+
}
|
|
231
|
+
/** 能力供给 · 准入拒绝埋点(§6.3;接线:capability-instrumentation.instrumentCapabilityAllowlist)。 */
|
|
232
|
+
recordPluginDenied(pluginId) {
|
|
233
|
+
this.capabilityPluginDenied.inc({ plugin: pluginId });
|
|
234
|
+
}
|
|
235
|
+
/** 语义执行埋点(M19;接线:skill-step-executor 注入 metrics 自动上报)。 */
|
|
236
|
+
recordLlmExecution(skillId, steps, filled, fields) {
|
|
237
|
+
this.llmSteps.inc({ skill: skillId }, steps);
|
|
238
|
+
this.llmFillRatio.set(fields > 0 ? filled / fields : 1);
|
|
239
|
+
}
|
|
240
|
+
/**
|
|
241
|
+
* LLM 用量分口径埋点(E0b):agent_id / skill_id / scenario 三维分组计数——
|
|
242
|
+
* 家族用量报表口径地基(入住率报表按维度聚合导出;缺省维度归 unknown)。
|
|
243
|
+
*/
|
|
244
|
+
recordLlmUsage(tags, totalTokens, calls = 1) {
|
|
245
|
+
const labels = {
|
|
246
|
+
agent_id: tags.agentId ?? 'unknown',
|
|
247
|
+
skill_id: tags.skillId ?? 'unknown',
|
|
248
|
+
scenario: tags.scenario ?? 'unknown',
|
|
249
|
+
};
|
|
250
|
+
if (totalTokens > 0)
|
|
251
|
+
this.llmUsageTokens.inc(labels, totalTokens);
|
|
252
|
+
this.llmUsageCalls.inc(labels, calls);
|
|
253
|
+
}
|
|
254
|
+
/** 一致性指标埋点(ConsistencyTracker.snapshot 直连;无样本时保留上次值)。 */
|
|
255
|
+
recordConsistency(snapshot) {
|
|
256
|
+
if (snapshot.consistencyRate !== undefined)
|
|
257
|
+
this.agreementRatio.set(snapshot.consistencyRate);
|
|
258
|
+
this.mirageCount.set(snapshot.mirageCount);
|
|
259
|
+
}
|
|
260
|
+
/** 记忆检索耗时埋点(毫秒入参,秒级输出;传 traceId 且启用 exemplar 时附带样例)。 */
|
|
261
|
+
observeMemoryRetrieval(milliseconds, traceId) {
|
|
262
|
+
if (milliseconds < 0)
|
|
263
|
+
return;
|
|
264
|
+
const seconds = milliseconds / 1000;
|
|
265
|
+
if (this.exemplarEnabled && traceId) {
|
|
266
|
+
this.memoryRetrieval.observe(seconds, {}, {
|
|
267
|
+
value: seconds,
|
|
268
|
+
timestampMs: Date.now(),
|
|
269
|
+
labels: { trace_id: traceId },
|
|
270
|
+
});
|
|
271
|
+
return;
|
|
272
|
+
}
|
|
273
|
+
this.memoryRetrieval.observe(seconds);
|
|
274
|
+
}
|
|
275
|
+
/** Exemplar 是否启用(供协议协商)。 */
|
|
276
|
+
get exemplarsEnabled() {
|
|
277
|
+
return this.exemplarEnabled;
|
|
278
|
+
}
|
|
279
|
+
/** 渲染 Prometheus 文本 exposition(0.0.4)。 */
|
|
280
|
+
render() {
|
|
281
|
+
return this.registry.render();
|
|
282
|
+
}
|
|
283
|
+
/** 渲染 OpenMetrics 1.0(末尾 `# EOF`)。 */
|
|
284
|
+
renderOpenMetrics() {
|
|
285
|
+
return this.registry.renderOpenMetrics();
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
/**
|
|
289
|
+
* 记忆编排器埋点包装(装饰器):对 retrieve 计时并上报,其余方法透传。
|
|
290
|
+
* 零侵入接入「知」支柱检索链路(MemoryOrchestratorImpl 无需改动)。
|
|
291
|
+
*/
|
|
292
|
+
export function instrumentMemoryOrchestrator(inner, metrics) {
|
|
293
|
+
return new Proxy(inner, {
|
|
294
|
+
get(target, prop, receiver) {
|
|
295
|
+
const value = Reflect.get(target, prop, receiver);
|
|
296
|
+
if (prop === 'retrieve' && typeof value === 'function') {
|
|
297
|
+
return async (...args) => {
|
|
298
|
+
const start = Date.now();
|
|
299
|
+
try {
|
|
300
|
+
return await value.apply(target, args);
|
|
301
|
+
}
|
|
302
|
+
finally {
|
|
303
|
+
// ctx(第二参)若带 traceId,则用于 exemplar 下钻(L7)
|
|
304
|
+
const ctx = args[1];
|
|
305
|
+
const traceId = typeof ctx?.traceId === 'string' ? ctx.traceId : undefined;
|
|
306
|
+
metrics.observeMemoryRetrieval(Date.now() - start, traceId);
|
|
307
|
+
}
|
|
308
|
+
};
|
|
309
|
+
}
|
|
310
|
+
return typeof value === 'function' ? value.bind(target) : value;
|
|
311
|
+
},
|
|
312
|
+
});
|
|
313
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 09-可观测性 barrel:指标注册 / 业务埋点 / 暴露服务统一出口。
|
|
3
|
+
*/
|
|
4
|
+
export * from './metrics-registry.js';
|
|
5
|
+
export * from './family-metrics.js';
|
|
6
|
+
export * from './metrics-server.js';
|
|
7
|
+
export * from './collaboration-instrumentation.js';
|
|
8
|
+
export * from './capability-instrumentation.js';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 09-可观测性 barrel:指标注册 / 业务埋点 / 暴露服务统一出口。
|
|
3
|
+
*/
|
|
4
|
+
export * from './metrics-registry.js';
|
|
5
|
+
export * from './family-metrics.js';
|
|
6
|
+
export * from './metrics-server.js';
|
|
7
|
+
export * from './collaboration-instrumentation.js';
|
|
8
|
+
export * from './capability-instrumentation.js';
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 轻量指标注册器(metrics-registry)——「09-可观测性」基础设施(v2.7.0,P0 数据面)。
|
|
3
|
+
* 职责:以**零运行时依赖**实现 Prometheus 三大基础指标(Counter / Gauge / Histogram),
|
|
4
|
+
* 并按 Prometheus 文本 exposition 格式渲染(# HELP / # TYPE / 样本行)。
|
|
5
|
+
* 边界:只做指标存储与渲染;指标语义与埋点归 family-metrics,HTTP 暴露归 metrics-server。
|
|
6
|
+
*
|
|
7
|
+
* 设计约束(对齐仓库零依赖原则):
|
|
8
|
+
* - 不引入 prom-client;哈希/标签/分桶全部内置;
|
|
9
|
+
* - 渲染确定性:指标按注册顺序、同类标签按 key 字典序输出,便于 diff 与快照测试;
|
|
10
|
+
* - Histogram 输出 `_bucket{le=...}` / `_sum` / `_count`,直接兼容 histogram_quantile()。
|
|
11
|
+
*/
|
|
12
|
+
/** 指标类型(Prometheus 文本协议)。 */
|
|
13
|
+
export type MetricType = 'counter' | 'gauge' | 'histogram';
|
|
14
|
+
/** 标签集合(键值均为字符串)。 */
|
|
15
|
+
export type LabelSet = Readonly<Record<string, string>>;
|
|
16
|
+
/** Exemplar 配置(v2.8.0 / L7)。默认关闭,关闭时不改变任何输出。 */
|
|
17
|
+
export interface ExemplarOptions {
|
|
18
|
+
/** 是否启用 exemplar(默认 false)。 */
|
|
19
|
+
readonly enabled?: boolean;
|
|
20
|
+
/** 每个桶最多保留的 exemplar 数(默认 1,超出保留最新)。 */
|
|
21
|
+
readonly maxPerBucket?: number;
|
|
22
|
+
/** exemplar 存活毫秒(默认 60s,渲染时惰性清理)。 */
|
|
23
|
+
readonly ttlMs?: number;
|
|
24
|
+
/** 丢弃回调(内部用于累加 `family_exemplars_dropped_total`)。 */
|
|
25
|
+
readonly onDrop?: () => void;
|
|
26
|
+
}
|
|
27
|
+
/** 单条 exemplar(OpenMetrics:样本值 + 关联标签 + 时间戳)。 */
|
|
28
|
+
export interface Exemplar {
|
|
29
|
+
/** 触发该 exemplar 的观测值。 */
|
|
30
|
+
readonly value: number;
|
|
31
|
+
/** 观测时刻(毫秒)。 */
|
|
32
|
+
readonly timestampMs: number;
|
|
33
|
+
/** 关联标签,约定只放 `trace_id` 等低基数、非敏感键。 */
|
|
34
|
+
readonly labels?: LabelSet;
|
|
35
|
+
}
|
|
36
|
+
/** 指标元信息。 */
|
|
37
|
+
export interface MetricDescriptor {
|
|
38
|
+
readonly name: string;
|
|
39
|
+
readonly help: string;
|
|
40
|
+
readonly type: MetricType;
|
|
41
|
+
}
|
|
42
|
+
/** 默认直方图分桶(秒级:任务时长 / 检索耗时通用)。 */
|
|
43
|
+
export declare const DEFAULT_BUCKETS: readonly number[];
|
|
44
|
+
/** 标签集合的取值序列(用于按标签聚合)。 */
|
|
45
|
+
interface Series {
|
|
46
|
+
readonly labels: LabelSet;
|
|
47
|
+
readonly key: string;
|
|
48
|
+
}
|
|
49
|
+
/** Counter(单调递增)。 */
|
|
50
|
+
export declare class Counter {
|
|
51
|
+
readonly descriptor: MetricDescriptor;
|
|
52
|
+
private readonly values;
|
|
53
|
+
constructor(descriptor: MetricDescriptor);
|
|
54
|
+
/** 递增(默认 +1)。 */
|
|
55
|
+
inc(labels?: LabelSet, value?: number): void;
|
|
56
|
+
/** 当前值。 */
|
|
57
|
+
value(labels?: LabelSet): number;
|
|
58
|
+
/** 渲染样本行(不含 HELP/TYPE)。 */
|
|
59
|
+
render(): string[];
|
|
60
|
+
/** 全部序列(供聚合/调试)。 */
|
|
61
|
+
series(): readonly Series[];
|
|
62
|
+
}
|
|
63
|
+
/** Gauge(可增可减可设)。 */
|
|
64
|
+
export declare class Gauge {
|
|
65
|
+
readonly descriptor: MetricDescriptor;
|
|
66
|
+
private readonly values;
|
|
67
|
+
constructor(descriptor: MetricDescriptor);
|
|
68
|
+
set(value: number, labels?: LabelSet): void;
|
|
69
|
+
inc(labels?: LabelSet, value?: number): void;
|
|
70
|
+
dec(labels?: LabelSet, value?: number): void;
|
|
71
|
+
value(labels?: LabelSet): number;
|
|
72
|
+
render(): string[];
|
|
73
|
+
}
|
|
74
|
+
/** Histogram(累积分桶 + 总和 + 计数 + 可选 exemplar)。 */
|
|
75
|
+
export declare class Histogram {
|
|
76
|
+
readonly descriptor: MetricDescriptor;
|
|
77
|
+
private readonly buckets;
|
|
78
|
+
private readonly values;
|
|
79
|
+
private readonly exemplarEnabled;
|
|
80
|
+
private readonly maxPerBucket;
|
|
81
|
+
private readonly ttlMs;
|
|
82
|
+
private readonly onDrop?;
|
|
83
|
+
constructor(descriptor: MetricDescriptor, buckets?: readonly number[], exemplars?: ExemplarOptions);
|
|
84
|
+
/** exemplar 是否启用(供协议协商与测试)。 */
|
|
85
|
+
get exemplarsEnabled(): boolean;
|
|
86
|
+
/**
|
|
87
|
+
* 观测一个值(秒)。
|
|
88
|
+
* 第三参仅在 exemplar 启用时生效;未启用时完全忽略,保证默认输出不变。
|
|
89
|
+
*/
|
|
90
|
+
observe(value: number, labels?: LabelSet, exemplar?: Exemplar): void;
|
|
91
|
+
/** 观测总数。 */
|
|
92
|
+
count(labels?: LabelSet): number;
|
|
93
|
+
/** 观测总和。 */
|
|
94
|
+
sum(labels?: LabelSet): number;
|
|
95
|
+
/** 渲染样本行(累积分桶 + +Inf + _sum + _count)。 */
|
|
96
|
+
render(): string[];
|
|
97
|
+
/**
|
|
98
|
+
* 渲染 OpenMetrics 样本行:在落点桶后附 exemplar。
|
|
99
|
+
* 格式:`<bucket> <count> # {trace_id="..."} <value> <ts秒>`
|
|
100
|
+
*/
|
|
101
|
+
renderOpenMetrics(): string[];
|
|
102
|
+
/** 值 → 落点桶索引(超出最大上界归入 +Inf 桶)。 */
|
|
103
|
+
private bucketIndex;
|
|
104
|
+
/** 单个桶的 exemplar 后缀(取最新存活项;过期项在此惰性清理)。 */
|
|
105
|
+
private exemplarSuffix;
|
|
106
|
+
}
|
|
107
|
+
/** 指标注册器:持有全部指标并渲染完整 exposition 文本。 */
|
|
108
|
+
export declare class MetricsRegistry {
|
|
109
|
+
private readonly metrics;
|
|
110
|
+
counter(name: string, help: string): Counter;
|
|
111
|
+
gauge(name: string, help: string): Gauge;
|
|
112
|
+
histogram(name: string, help: string, buckets?: readonly number[], exemplars?: ExemplarOptions): Histogram;
|
|
113
|
+
/** 是否存在启用 exemplar 的直方图(供协议协商)。 */
|
|
114
|
+
get exemplarsEnabled(): boolean;
|
|
115
|
+
/** 渲染 Prometheus 文本 exposition(末尾带换行,符合 exposition 规范)。 */
|
|
116
|
+
render(): string;
|
|
117
|
+
/**
|
|
118
|
+
* 渲染 OpenMetrics 1.0(末尾以 `# EOF` 结束)。
|
|
119
|
+
* 直方图在落点桶后附 exemplar;Counter/Gauge 输出与 0.0.4 一致。
|
|
120
|
+
*/
|
|
121
|
+
renderOpenMetrics(): string;
|
|
122
|
+
}
|
|
123
|
+
export {};
|