评测与研究
基于TypeSafe的Jev构建的TLA+验证共识内核,经过1680次混沌测试药房决策,无错误判定,包含影片、代码和所有通话记录。
Never confidently wrong: a TLA+-verified consensus kernel around TypeSafe's Jev, run through 1,680 chaos-tested pharmacy decisions with zero wrong verdicts. Film, code, and every captured call.
const DEFAULT_BASE_URL: &str = "https://api.typesafe.ai";consensus/rust/consensus-kernel/src/jev.rs:25
链接指向我们抓取当天的那个 commit,行号是准的。
下面是从这个项目源码里原样取出来的 question 组合。
is_regulation是/否Is the subject of this text a law or regulation?
mentions_deadline是/否Does this text state a reporting deadline?
mentions_fines是/否Does this text describe financial penalties?
mentions_scope是/否Does this text describe a geographic scope?
mentions_date是/否Does this text state a date it took effect?
mentions_controllers是/否Does this text place obligations on data controllers?
mentions_consent是/否Does this text discuss obtaining user consent?
mentions_dpo是/否Does this text mention a Data Protection Officer?
import { experimental_evaluate as evaluate } from 'ai';
const { answers } = await evaluate({
model: 'typesafe-ai/jev',
state,
questions: {
is_regulation: { type: 'boolean', instructions: 'Is the subject of this text a law or regulation?' },
mentions_deadline: { type: 'boolean', instructions: 'Does this text state a reporting deadline?' },
mentions_fines: { type: 'boolean', instructions: 'Does this text describe financial penalties?' },
mentions_scope: { type: 'boolean', instructions: 'Does this text describe a geographic scope?' },
mentions_date: { type: 'boolean', instructions: 'Does this text state a date it took effect?' },
mentions_controllers: { type: 'boolean', instructions: 'Does this text place obligations on data controllers?' },
mentions_consent: { type: 'boolean', instructions: 'Does this text discuss obtaining user consent?' },
mentions_dpo: { type: 'boolean', instructions: 'Does this text mention a Data Protection Officer?' },
},
});is_regulation是/否Is the subject of this text a law or regulation?
mentions_consent是/否Does this text discuss obtaining user consent?
severity打分How severe are the penalties described?
0 — No penalties1 — Moderate penalties2 — Severe penaltiestopic选项What is the primary subject of this text?
privacy_law — Data protection or privacy regulationtax_law — Taxation rulesemployment_law — Labour or employment rulesimport { experimental_evaluate as evaluate } from 'ai';
const { answers } = await evaluate({
model: 'typesafe-ai/jev',
state,
questions: {
is_regulation: { type: 'boolean', instructions: 'Is the subject of this text a law or regulation?' },
mentions_consent: { type: 'boolean', instructions: 'Does this text discuss obtaining user consent?' },
severity: { type: 'score', instructions: 'How severe are the penalties described?',
criteria: ['No penalties', 'Moderate penalties', 'Severe penalties'] },
topic: { type: 'choice', instructions: 'What is the primary subject of this text?',
criteria: { privacy_law: 'Data protection or privacy regulation', tax_law: 'Taxation rules', employment_law: 'Labour or employment rules' } },
},
});billing是/否Is this message about a billing or payment matter?
technical是/否Does this message report a technical malfunction?
urgent是/否Does this message convey urgency?
import { experimental_evaluate as evaluate } from 'ai';
const { answers } = await evaluate({
model: 'typesafe-ai/jev',
state,
questions: {
billing: { type: 'boolean', instructions: 'Is this message about a billing or payment matter?' },
technical: { type: 'boolean', instructions: 'Does this message report a technical malfunction?' },
urgent: { type: 'boolean', instructions: 'Does this message convey urgency?' },
},
});department选项Which team should handle this ticket?
billing — Payment, invoicing, or subscription issuestechnical — Bugs, outages, or integration problemssales — Pricing, upgrades, or new accountsfrustration打分How frustrated the customer appears
0 — Calm, just stating facts1 — Frustrated but civil2 — Very angry, strong languageis_urgent是/否The message conveys urgency or time-sensitivity
import { experimental_evaluate as evaluate } from 'ai';
const { answers } = await evaluate({
model: 'typesafe-ai/jev',
state,
questions: {
department: { type: 'choice', instructions: 'Which team should handle this ticket?',
criteria: { billing: 'Payment, invoicing, or subscription issues', technical: 'Bugs, outages, or integration problems', sales: 'Pricing, upgrades, or new accounts' } },
frustration: { type: 'score', instructions: 'How frustrated the customer appears',
criteria: ['Calm, just stating facts', 'Frustrated but civil', 'Very angry, strong language'] },
is_urgent: { type: 'boolean', instructions: 'The message conveys urgency or time-sensitivity' },
},
});