JUNGU commited on
Commit
79962ad
โ€ข
1 Parent(s): 3f3b508

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +19 -19
app.py CHANGED
@@ -14,25 +14,8 @@ def main():
14
 
15
  if st.button("Find Keywords"):
16
 
17
- # few-shot learning์„ ์ด์šฉํ•œ task_description
18
- task_description = """You are a useful helper that generates annotated text for Python's st-annotated-text library. Your job is to identify the topic of the fingerprint and highlight the key words needed to convey meaning. The output should be formatted in the following way:
19
- annotated_text(
20
- "This ",
21
- ("is", ""),
22
- " some ",
23
- ("annotated", ""),
24
- ("text", ""),
25
- " for those of ",
26
- ("you", ""),
27
- " who ",
28
- ("like", ""),
29
- " this sort of ",
30
- ("thing", ""),
31
- ". "
32
- )"""
33
-
34
-
35
- # task_description = """You are a helpful assistant that generates annotated text for the st-annotated-text library in Python. Highlight the key terms that are most important in the context of the sentence, especially focusing on the main subject involved. Your output should be formatted in the following way for text:
36
  # annotated_text(
37
  # "This ",
38
  # ("is", ""),
@@ -47,6 +30,23 @@ def main():
47
  # ("thing", ""),
48
  # ". "
49
  # )"""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
50
 
51
  #์ถœ๋ ฅ ํŒŒ์ธํŠœ๋‹ ์—ฌ๋Ÿฌ๋ถ„์€ Python์˜ st-annotated-text ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ๋ฅผ ์œ„ํ•ด ์ฃผ์„์ด ๋‹ฌ๋ฆฐ ํ…์ŠคํŠธ๋ฅผ ์ƒ์„ฑํ•˜๋Š” ์œ ์šฉํ•œ ๋„์šฐ๋ฏธ์ž…๋‹ˆ๋‹ค. ์ง€๋ฌธ์˜ ์ฃผ์ œ๋ฅผ ํŒŒ์•…ํ•˜๊ณ  ์˜๋ฏธ ์ „๋‹ฌ์— ํ•„์š”ํ•œ ํ•ต์‹ฌ์–ด๋ฅผ ๊ฐ•์กฐ ํ‘œ์‹œํ•˜๋Š” ๊ฒƒ์ด ์—ฌ๋Ÿฌ๋ถ„์˜ ์ž„๋ฌด์ž…๋‹ˆ๋‹ค. ์ถœ๋ ฅ๋ฌผ์˜ ํ˜•์‹์€ ๋‹ค์Œ๊ณผ ๊ฐ™์€ ๋ฐฉ์‹์œผ๋กœ ์ง€์ •ํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
52
 
 
14
 
15
  if st.button("Find Keywords"):
16
 
17
+ # # few-shot learning์„ ์ด์šฉํ•œ task_description
18
+ # task_description = """You are a useful helper that generates annotated text for Python's st-annotated-text library. Your job is to identify the topic of the fingerprint and highlight the key words needed to convey meaning. The output should be formatted in the following way:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  # annotated_text(
20
  # "This ",
21
  # ("is", ""),
 
30
  # ("thing", ""),
31
  # ". "
32
  # )"""
33
+
34
+
35
+ task_description = """ You are a useful helper that generates annotated text for Python's st-annotated-text library. Your task is to identify the topic of the passage and highlight the key words needed to convey the meaning. You should be able to identify the main points. Also, please mark keywords based on the different paragraphs and headings provided in the text. The output should be formatted in the following way:
36
+ annotated_text(
37
+ "This ",
38
+ ("is", ""),
39
+ " some ",
40
+ ("annotated", ""),
41
+ ("text", ""),
42
+ " for those of ",
43
+ ("you", ""),
44
+ " who ",
45
+ ("like", ""),
46
+ " this sort of ",
47
+ ("thing", ""),
48
+ ". "
49
+ )"""
50
 
51
  #์ถœ๋ ฅ ํŒŒ์ธํŠœ๋‹ ์—ฌ๋Ÿฌ๋ถ„์€ Python์˜ st-annotated-text ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ๋ฅผ ์œ„ํ•ด ์ฃผ์„์ด ๋‹ฌ๋ฆฐ ํ…์ŠคํŠธ๋ฅผ ์ƒ์„ฑํ•˜๋Š” ์œ ์šฉํ•œ ๋„์šฐ๋ฏธ์ž…๋‹ˆ๋‹ค. ์ง€๋ฌธ์˜ ์ฃผ์ œ๋ฅผ ํŒŒ์•…ํ•˜๊ณ  ์˜๋ฏธ ์ „๋‹ฌ์— ํ•„์š”ํ•œ ํ•ต์‹ฌ์–ด๋ฅผ ๊ฐ•์กฐ ํ‘œ์‹œํ•˜๋Š” ๊ฒƒ์ด ์—ฌ๋Ÿฌ๋ถ„์˜ ์ž„๋ฌด์ž…๋‹ˆ๋‹ค. ์ถœ๋ ฅ๋ฌผ์˜ ํ˜•์‹์€ ๋‹ค์Œ๊ณผ ๊ฐ™์€ ๋ฐฉ์‹์œผ๋กœ ์ง€์ •ํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.
52