Non-autoregressive System 1 decision engine. Typed choice, score and yes/no decisions over any text in a single forward pass, in 100+ languages, with a router that picks the right checkpoint per request.
Python calibrationclassificationdecision-modelhuggingfacejevmodernbertmultilingualnlppythonpytorchroutingtyped-decisionszero-shot
Merge PR #750
Nandakishora0fae41a65dc
diff --cc laya-ts/src/agent.tsindex 8b1a12d4,b28e3f49..1a7b4ec6--- a/laya-ts/src/agent.ts+++ b/laya-ts/src/agent.ts@@@ -17,12 -17,11 +17,12 @@@ importserializeState,softmax,tempBucket,+ unpermuteProbs,} from "./common.js";-import type { BinningMap, MinConfidence, OptionStats, SequenceStats } from "./common.js";+import type { BinningMap, InternalQ, MinConfidence, OptionStats, SequenceStats } from "./common.js";import type { Batch, SessionProvider } from "./providers.js";import { encodeWithData, parseTokenizerJson, type TokenizerLike } from "./tokenizer.js";- import { decide, type DecideOptions, type DecisionResult } from "./structured.js";+ import { decide, decideBatch, type DecideOptions, type DecideBatchOptions, type DecisionResult } from "./structured.js";import {HookRegistry,PredictContext,diff --cc laya-ts/src/router.tsindex 40ac2b35,6e42438d..acd38eb7--- a/laya-ts/src/router.ts+++ b/laya-ts/src/router.ts@@@ -1,7 -1,7 +1,7 @@@import { analyse, type AnalyseResult } from "./lang.js";-import type { PredictOptions, QuestionDef, SystemOneResult } from "./agent.js";+import { checkQuestion, type PredictOptions, type QuestionDef, type SystemOneResult } from "./agent.js";import { checkMinConfidence, flagLowConfidence } from "./common.js";- import { decide, type DecideOptions, type DecisionResult } from "./structured.js";+ import { decide, decideBatch, type DecideOptions, type DecideBatchOptions, type DecisionResult } from "./structured.js";import {HookRegistry,PredictContext,