Skip to content

Commit

Permalink
perf: adjust dict prompt
Browse files Browse the repository at this point in the history
  • Loading branch information
tisfeng committed Dec 28, 2023
1 parent 418f77d commit 81cda19
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -350,8 +350,8 @@ - (NSArray *)translatioMessages:(NSString *)text from:(EZLanguage)sourceLanguage
NSString *rememberWordPrompt = [NSString stringWithFormat:@"Look up disassembly and association methods to remember it, desired display format: \"%@: xxx \" \n", howToRemember];
prompt = [prompt stringByAppendingString:rememberWordPrompt];

// NSString *cognatesPrompt = [NSString stringWithFormat:@"\nLook up its most commonly used <%@> cognates, no more than 6, desired display format: \"%@: xxx \" ", sourceLanguage, cognate];
NSString *cognatesPrompt = [NSString stringWithFormat:@"\nLook up main <%@> words with the same root word as \"%@\", no more than 6, excluding phrases, display all parts of speech and meanings of the same root word, pos always displays its English abbreviation. If there are words with the same root, show format: \"%@: xxx \", otherwise don't display it. ", sourceLanguage, word, cognate];
// NSString *cognatesPrompt = [NSString stringWithFormat:@"\nLook up its most commonly used <%@> cognates, no more than 4, desired display format: \"%@: xxx \" ", sourceLanguage, cognate];
NSString *cognatesPrompt = [NSString stringWithFormat:@"\nLook up main <%@> words with the same root word as \"%@\", no more than 4, excluding phrases, display all parts of speech and meanings of the same root word, pos always displays its English abbreviation. If there are words with the same root, show format: \"%@: xxx \", otherwise don't display it. ", sourceLanguage, word, cognate];
prompt = [prompt stringByAppendingString:cognatesPrompt];
}

Expand All @@ -362,7 +362,7 @@ - (NSArray *)translatioMessages:(NSString *)text from:(EZLanguage)sourceLanguage
NSString *antonymsPrompt = [NSString stringWithFormat:@"\nLook up its main <%@> near antonyms, no more than 3, If it has antonyms, show format: \"%@: xxx \" \n", sourceLanguage, antonym];
prompt = [prompt stringByAppendingString:antonymsPrompt];

NSString *phrasePrompt = [NSString stringWithFormat:@"\nLook up its main <%@> phrases, no more than 5, If it has phrases, show format: \"%@: xxx \" \n", sourceLanguage, commonPhrases];
NSString *phrasePrompt = [NSString stringWithFormat:@"\nLook up its main <%@> phrases, no more than 3, If it has phrases, show format: \"%@: xxx \" \n", sourceLanguage, commonPhrases];
prompt = [prompt stringByAppendingString:phrasePrompt];
}

Expand Down

0 comments on commit 81cda19

Please sign in to comment.