@fenglimg/fabric-server 2.2.0-rc.8 → 2.2.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/dist/index.d.ts CHANGED
@@ -62,6 +62,9 @@ interface KnowledgeCensus {
62
62
  personal: number;
63
63
  project: number;
64
64
  };
65
+ broad_by_type: Record<string, number>;
66
+ /** count of narrow-scope kept entries (file-specific; only合计, not per-type). */
67
+ narrow_total: number;
65
68
  /** entries专属 to OTHER projects that filterByActiveProject removed. */
66
69
  dropped_other_project: number;
67
70
  /** kept (post-filter) total. */
@@ -538,6 +541,37 @@ declare function extractKnowledge(projectRoot: string, input: FabExtractKnowledg
538
541
  */
539
542
  declare function reviewKnowledge(projectRoot: string, input: FabReviewInput): Promise<FabReviewOutput>;
540
543
 
544
+ /** A summary to be cold-judged, keyed by its stable_id. */
545
+ interface ColdEvalCandidate {
546
+ stable_id: string;
547
+ summary: string;
548
+ }
549
+ /** The verdict the external cold-eval judge returns per candidate. */
550
+ interface ColdEvalVerdict {
551
+ stable_id: string;
552
+ /** true when the summary alone is act-on sufficient without the body. */
553
+ self_sufficient: boolean;
554
+ /** When not self-sufficient, the judge's suggested act-on rewrite. */
555
+ suggested_summary?: string;
556
+ /** Short rationale (pointer-vs-thesis) for the verdict. */
557
+ reason?: string;
558
+ }
559
+ /** The batch request handed to the external (maestro delegate) cold-eval judge. */
560
+ interface ColdEvalBatch {
561
+ rubric: string;
562
+ candidates: ColdEvalCandidate[];
563
+ }
564
+ declare const COLD_EVAL_RUBRIC: string;
565
+ /**
566
+ * Build the cold-eval batch request for the external judge. Pure + deterministic:
567
+ * drops blank summaries (nothing to judge) and pairs the candidates with the
568
+ * zero-context rubric. The fabric-review skill hands the result to
569
+ * `maestro delegate` and applies the returned {@link ColdEvalVerdict}[] via
570
+ * fab_review modify. Returns a batch with an empty candidate list when nothing is
571
+ * judgeable, so callers can short-circuit without a delegate round-trip.
572
+ */
573
+ declare function buildColdEvalBatch(candidates: ColdEvalCandidate[]): ColdEvalBatch;
574
+
541
575
  type StoredEventLedgerEvent = EventLedgerEvent;
542
576
  type ReadEventLedgerOptions = {
543
577
  event_type?: EventLedgerEvent["event_type"];
@@ -823,4 +857,4 @@ interface ShutdownHandlerDeps {
823
857
  */
824
858
  declare function createShutdownHandler(deps: ShutdownHandlerDeps): () => void;
825
859
 
826
- export { AGENTS_MD_RESOURCE_URI, type AlwaysActiveBody, type ArchiveHistoryEntry, type ArchiveHistoryReport, type CiteCoverageReport, type ConflictEntry, type ConflictJudge, type ConflictLintReport, type ConflictPair, type ConflictVerdict, DEFAULT_CONFLICT_SIMILARITY_THRESHOLD, type DoctorApplyLintMutation, type DoctorApplyLintMutationKind, type DoctorApplyLintReport, type DoctorFixReport, type DoctorIssue, type DoctorReport, EVENT_LEDGER_PATH, type EnrichDescriptionsCandidate, type EnrichDescriptionsMode, type EnrichDescriptionsReport, FABRIC_SERVER_INSTRUCTIONS, type HistoryAllReport, type HistoryDayRow, type InFlightTracker, type KnowledgeCensus, LEDGER_PATH, LEGACY_LEDGER_PATH, METRICS_LEDGER_PATH, METRIC_COUNTER_NAMES, type MetricCounterName, type MetricsRow, type PlanContextInput, type PlanContextResult, type RecallInput, type RecallResult, type RequirementProfile, type SelectionTokenState, type ShutdownHandlerDeps, type UnboundProjectViolation, appendEventLedgerEvent, buildAlwaysActiveBodies, buildKnowledgeCensus, bumpCounter, contextCache, createFabricServer, createInFlightTracker, createShutdownHandler, detectUnboundProject, drainCounters, enrichDescriptions, extractKnowledge, findConflictCandidates, flushAndSyncEventLedger, flushMetrics, formatPreexistingRootMessage, getEventLedgerPath, getLedgerPath, getLegacyLedgerPath, getMetricsLedgerPath, lintConflicts, loadConflictEntries, pairSimilarity, planContext, readEventLedger, readLedger, readMetrics, readSelectionToken, recall, rehydrateAgentsMetaAt, resolveLedgerPaths, reviewKnowledge, runDoctorApplyLint, runDoctorArchiveHistory, runDoctorCiteCoverage, runDoctorConflictLint, runDoctorFix, runDoctorHistoryAll, runDoctorReport, startMetricsFlush, startRotationTick, startStdioServer, stopMetricsFlush, stopRotationTick };
860
+ export { AGENTS_MD_RESOURCE_URI, type AlwaysActiveBody, type ArchiveHistoryEntry, type ArchiveHistoryReport, COLD_EVAL_RUBRIC, type CiteCoverageReport, type ColdEvalBatch, type ColdEvalCandidate, type ColdEvalVerdict, type ConflictEntry, type ConflictJudge, type ConflictLintReport, type ConflictPair, type ConflictVerdict, DEFAULT_CONFLICT_SIMILARITY_THRESHOLD, type DoctorApplyLintMutation, type DoctorApplyLintMutationKind, type DoctorApplyLintReport, type DoctorFixReport, type DoctorIssue, type DoctorReport, EVENT_LEDGER_PATH, type EnrichDescriptionsCandidate, type EnrichDescriptionsMode, type EnrichDescriptionsReport, FABRIC_SERVER_INSTRUCTIONS, type HistoryAllReport, type HistoryDayRow, type InFlightTracker, type KnowledgeCensus, LEDGER_PATH, LEGACY_LEDGER_PATH, METRICS_LEDGER_PATH, METRIC_COUNTER_NAMES, type MetricCounterName, type MetricsRow, type PlanContextInput, type PlanContextResult, type RecallInput, type RecallResult, type RequirementProfile, type SelectionTokenState, type ShutdownHandlerDeps, type UnboundProjectViolation, appendEventLedgerEvent, buildAlwaysActiveBodies, buildColdEvalBatch, buildKnowledgeCensus, bumpCounter, contextCache, createFabricServer, createInFlightTracker, createShutdownHandler, detectUnboundProject, drainCounters, enrichDescriptions, extractKnowledge, findConflictCandidates, flushAndSyncEventLedger, flushMetrics, formatPreexistingRootMessage, getEventLedgerPath, getLedgerPath, getLegacyLedgerPath, getMetricsLedgerPath, lintConflicts, loadConflictEntries, pairSimilarity, planContext, readEventLedger, readLedger, readMetrics, readSelectionToken, recall, rehydrateAgentsMetaAt, resolveLedgerPaths, reviewKnowledge, runDoctorApplyLint, runDoctorArchiveHistory, runDoctorCiteCoverage, runDoctorConflictLint, runDoctorFix, runDoctorHistoryAll, runDoctorReport, startMetricsFlush, startRotationTick, startStdioServer, stopMetricsFlush, stopRotationTick };