Automatically scanned data. Review the source before installing. Levels describe capabilities, not a safety certification.
View matches (16)
Execute commands · line37 linesrc/logic/prompt-translation/prompt-translation.tsconst isCommand = (text: string, commands: readonly string[]) => commands.includes(/^\/(\S+)/.exec(text)?.[1] ?? '')
Model calls · line40 linesrc/hooks/features/learning/learning.tsxconst translation = await Answers.of($.model.complete(request))
Model calls · line64 linesrc/hooks/features/learning/learning.tsxconst card = WordCards.of(await Answers.of($.model.complete(WordCards.request(await settingsOf($), { word, restated }, await $.session.surfaces()))), { word, restated })
Model calls · line73 linesrc/hooks/features/learning/learning.tsxconst answer = await Answers.of($.model.complete(WordAspects.request(await settingsOf($), at.aspect, { word: at.word, restated })))
Model calls · line119 linesrc/hooks/features/learning/learning.tsxawait showSymbols($, lines, Pronunciations.of(await Answers.of($.model.complete(Pronunciations.request(await settingsOf($), lines)))))
Model calls · line148 linesrc/hooks/features/learning/learning.tsxawait showReply($, key, ReplyTranslations.checked(text, await Answers.of($.model.complete(request))))
Model calls · line164 linesrc/hooks/features/learning/learning.tsxconst coach = await Answers.of($.model.complete(SpeakingPractice.request(await settingsOf($), asked)))
Model calls · line181 linesrc/hooks/features/learning/learning.tsxconst version = request && (await Answers.of($.model.complete(request, { signal })))
Execute commands · line38 linesrc/logic/draft-translation/draft-translation.tsconst name = /^\/(\S*)/.exec(draft)?.[1]
Execute commands · line52 linesrc/logic/draft-translation/draft-translation.tsreturn new RegExp(`(?<!${inWord})${mark.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')}(?!${inWord})`, 'u').exec(draft)?.index ?? -1
Execute commands · line46 linesrc/logic/pronunciation/pronunciation.tsreturn { n: Number(/^\/?\[(\d+)\]/.exec(line)?.[1] ?? 0), isSlashed: line.startsWith('/'), symbol: symbol && `/${symbol}/` }
Execute commands · line57 linesrc/logic/reply-translation/reply-translation.tsconst isIntoTarget = ({ native }: Settings, value: string) => /^FROM:(.*)$/m.exec(value)?.[1]?.trim().toLowerCase() === native.trim().toLowerCase()
Execute commands · line43 linesrc/logic/word-aspect/word-aspect.tsconst [, name = '', value = ''] = /^([A-Z]+):\s*(.+)$/.exec(line.trim()) ?? []
Execute commands · line43 linesrc/logic/word-card/word-card.tsconst card = { unit: field(text, 'UNIT'), pron: field(text, 'PRON'), caption: field(text, 'CAPTION'), svg: /<svg[\s\S]*<\/svg>/.exec(text)?.[0] ?? '' }
Execute commands · line47 linesrc/logic/word-card/word-card.tsconst field = (text: string, name: string) => new RegExp(`^${name}:[ \\t]*(.+)$`, 'm').exec(text)?.[1]?.trim() ?? ''
Execute commands · line16 linesrc/logic/word-line/word-line.tsconst split = (text: string) => /^(\s*)(?:([-*+]|\d+[.)]|#{1,6}|>)\s+)?(.*)$/.exec(text)?.slice(1) ?? []