More work on CC display
This commit is contained in:
parent
27b27876c0
commit
a27864e3d2
7 changed files with 45 additions and 20 deletions
|
|
@ -138,7 +138,7 @@ const ruleAiGenerated = (): FlagMatchRule[] => {
|
|||
];
|
||||
};
|
||||
|
||||
const aiHintFlags = (): FlagMatchRule[] => {
|
||||
const ruleAiMeta = (): FlagMatchRule[] => {
|
||||
const knownAIServices = [
|
||||
"ChatGPT",
|
||||
"OpenAI-API",
|
||||
|
|
@ -292,9 +292,17 @@ export const extractProofHintFlags = (proof?: Proof): ProofHintFlags | undefined
|
|||
if (matchFlag(ruleScreenshotMeta(), proof).result) {
|
||||
generator = "screenshot";
|
||||
generatorSource = "metadata";
|
||||
} else if (matchFlag(ruleAiMeta(), proof).result) {
|
||||
generator = "ai";
|
||||
generatorSource = "metadata";
|
||||
}
|
||||
}
|
||||
|
||||
// Do we have any data? Else, return "undefined", we don't just want to send an object with all defaults.
|
||||
if (source.length === 0 && dateCreated.length === 0 && generator === "unknown") {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
const flags: ProofHintFlags = {
|
||||
valid: valid,
|
||||
device: source && source.length == 1 ? source[0].value : undefined,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue