nblog_duo 0.0.67 → 0.0.79

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/nblog_duo.rb +204 -133
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 32be681d6aa2c5ea7f576ee6a65a2743432ac7556eb7a689cbfeb91756f83c94
4
- data.tar.gz: a568440813e460a2fd872a7d42add1edf779df54a009f0627ad1fbc6ef8e13a1
3
+ metadata.gz: 16bacc65bd2507a5cba7950a748fffb95a23b4d535365ab99838cd790677fe72
4
+ data.tar.gz: a2aa69e059efdb23d7755a6514b7f8141c2858ae91cdd9bd2cf082e794a7fd97
5
5
  SHA512:
6
- metadata.gz: 690967f42eb6c90231410f570d4769b7a1855b631f4080691d970592846bfb826a28f154e01cda9e5c46a56241dc87197bcbe52f02015eccfcc2db24e9f8a040
7
- data.tar.gz: 1bcb4daa76ea1d8a89bf392b00c824d50809fd984f16f408c746a2c6986190d9174d7e7e510191269ac695cdf6b14cd5dcc21ba2b32f593ae65331fa143db3e3
6
+ metadata.gz: '08dc667f9a51c2da10687b3ae12ee5f591c69c40a198eb20a4476a4cdca1bbd4734ec1f7f1a0ec4c58af8544154ccfd459c971a7b532d502494920963e0395f7'
7
+ data.tar.gz: 2657492071bef35b031a2c00aca02b9a5b838b6bbc6746ee615af9772e54b71e406a15270852ff26fa63415adc623f4af7f93abf7ccb2a3da268292e106c9016
data/lib/nblog_duo.rb CHANGED
@@ -22,93 +22,107 @@ using Rainbow
22
22
  include Glimmer
23
23
 
24
24
  class Chat
25
- def initialize(api_key)
25
+ def initialize(api_key, gpt_keyword_prompt)
26
26
  @api_key = api_key
27
+ @gpt_keyword_prompt = gpt_keyword_prompt
27
28
  end
28
29
 
29
- def message2(keyword)
30
- url = 'https://api.openai.com/v1/chat/completions'
31
- h = {
32
- 'Content-Type' => 'application/json',
33
- 'Authorization' => 'Bearer ' + @api_key
34
- }
35
- d = {
36
- #'model' => 'gpt-3.5-turbo',
37
- 'model' => 'gpt-4',
38
- 'messages' => [{
39
- "role" => "assistant",
40
- "content" => keyword.to_s+" 소개하는 글을 1500자에서 2500자 사이로 만들어줘"
41
- }]
42
- }
43
- answer = ''
44
- begin
45
- req = HTTP.headers(h).post(url, :json => d)
46
- print(req.to_s)
47
- answer = JSON.parse(req.to_s)['choices'][0]['message']['content']
48
- rescue => e
49
- begin
50
- answer = JSON.parse(req.to_s)['choices'][0]['message']['message']
51
- rescue
30
+ def message(keyword)
31
+ puts 'Sending request to GPT...(키워드 기반 글 생성 중...)'
52
32
 
33
+ # "키워드 기반 글 생성 중..." 메시지 출력 스레드
34
+ thread = Thread.new do
35
+ while true
36
+ print "▶"
37
+ sleep 3
53
38
  end
54
39
  end
55
40
 
56
-
57
- print('api return ==> ')
58
- puts(answer)
59
-
60
- return answer
61
- end
62
-
63
- def message(keyword)
64
- puts 'chat gpt ...'
65
41
  url = 'https://api.openai.com/v1/chat/completions'
66
- h = {
42
+ headers = {
67
43
  'Content-Type' => 'application/json',
68
44
  'Authorization' => 'Bearer ' + @api_key
69
45
  }
70
- d = {
71
- #'model' => 'gpt-3.5-turbo',
46
+
47
+ # 사용자로부터 받은 입력과 GPT 프롬프트의 토큰 수 계산
48
+ message_tokens = calculate_tokens(keyword) + calculate_tokens(@gpt_keyword_prompt)
49
+
50
+ # 8,192 토큰을 초과하지 않도록 최대 토큰 수를 설정
51
+ max_response_tokens = [8192 - message_tokens, 4000].min # 8,192 - 입력된 토큰 수, 4,000 이하로 설정
52
+
53
+ # 요청 데이터 설정
54
+ data = {
72
55
  'model' => 'gpt-4',
73
- 'messages' => [{
74
- "role" => "assistant",
75
- "content" => keyword.to_s+" 관련된 글을 1500자에서 2500자 사이로 만들어줘"
76
- }]
56
+ 'messages' => [
57
+ {
58
+ "role" => "assistant",
59
+ "content" => "#{keyword}\n#{@gpt_keyword_prompt}"
60
+ }
61
+ ],
62
+ 'max_tokens' => max_response_tokens # 최대 응답 토큰 설정
77
63
  }
64
+
65
+
66
+
78
67
  answer = ''
79
68
  begin
80
- req = HTTP.headers(h).post(url, :json => d)
81
- print(req.to_s)
82
- answer = JSON.parse(req.to_s)['choices'][0]['message']['content']
83
- rescue => e
84
- begin
85
- answer = JSON.parse(req.to_s)['choices'][0]['message']['message']
86
- rescue
69
+ req = HTTP.headers(headers).post(url, :json => data)
87
70
 
71
+ # 상태 코드 확인
72
+ if req.status != 200
73
+ raise "HTTP Error: #{req.status}, Response Body: #{req.body.to_s}"
88
74
  end
89
- end
90
- con = 0
91
- while con > 5
92
- answer = answer + message2(keyword)
93
- if answer.length > 2000
94
- break
75
+
76
+ # 응답 내용 출력 (디버깅용)
77
+ response = JSON.parse(req.to_s)
78
+
79
+
80
+ # 응답 데이터에서 안전하게 값 추출
81
+ if response['choices'] && response['choices'][0] && response['choices'][0]['message']
82
+ answer = response['choices'][0]['message']['content']
83
+ else
84
+ raise "Invalid API response format"
95
85
  end
96
- con += 1
86
+ rescue => e
87
+ # 오류 메시지 출력
88
+ puts "Error occurred: #{e.message}"
89
+ answer = "오류가 발생했습니다."
97
90
  end
98
91
 
99
- print('api return ==> ')
100
- puts(answer)
92
+ # "생성 중..." 메시지 출력 종료
93
+ thread.kill
101
94
 
95
+ # 결과 로그 출력
96
+ puts "Final API response ==> #{answer}"
102
97
  return answer
103
98
  end
99
+
100
+ def calculate_tokens(text)
101
+ # 간단한 방식으로 텍스트의 토큰 수 계산 (정확도는 다를 수 있음)
102
+ # OpenAI API는 1토큰이 대략 4글자 정도임
103
+ text.split(/\s+/).length # 간단한 단어 수로 계산
104
+ end
104
105
  end
105
106
 
107
+
108
+
109
+
110
+
106
111
  class Chat_title
107
- def initialize(api_key)
112
+ def initialize(api_key, gpt_title_prompt)
108
113
  @api_key = api_key
114
+ @gpt_title_prompt = gpt_title_prompt
109
115
  end
110
116
 
111
117
  def message(title)
118
+ puts 'Sending request to GPT...(제목 생성 중...)'
119
+ # "키워드 기반 글 생성 중..." 메시지를 별도 스레드로 처리
120
+ thread = Thread.new do
121
+ while true
122
+ print "▶"
123
+ sleep(3)
124
+ end
125
+ end
112
126
  url = 'https://api.openai.com/v1/chat/completions'
113
127
  headers = {
114
128
  'Content-Type' => 'application/json',
@@ -122,15 +136,15 @@ class Chat_title
122
136
  },
123
137
  {
124
138
  "role" => "user",
125
- "content" => "#{title}\n위 문장을 비슷한 길이로 ChatGPT의 멘트는 빼고 표현을 더 추가해서 하나만 만들어줘."
139
+ "content" => "#{@gpt_title_prompt}\n#{title}"
126
140
  }]
127
141
  }
128
142
 
129
143
  begin
130
144
  req = HTTP.headers(headers).post(url, json: data)
131
- puts "HTTP Status: #{req.status}" # 상태 코드 확인
145
+
132
146
  response = JSON.parse(req.body.to_s)
133
- puts "API Response: #{response}" # 전체 응답 출력
147
+
134
148
 
135
149
  if req.status == 429
136
150
  return "API 요청 제한을 초과했습니다. 플랜 및 할당량을 확인하세요."
@@ -138,11 +152,18 @@ class Chat_title
138
152
 
139
153
  # 응답 데이터에서 안전하게 값 추출
140
154
  answer = response.dig('choices', 0, 'message', 'content')
141
- answer ||= (title) # 응답이 없을 경우 기본 메시지 설정
155
+
156
+ # 따옴표 제거
157
+ answer = answer.gsub('"', '') if answer
158
+
159
+ answer ||= title # 응답이 없을 경우 기본 메시지 설정
142
160
  rescue => e
143
161
  puts "Error: #{e.message}"
144
162
  answer = "오류가 발생했습니다."
145
163
  end
164
+
165
+ # "생성 중..." 메시지 출력 종료
166
+ thread.kill
146
167
 
147
168
  puts 'API return ==> '
148
169
  puts answer
@@ -150,12 +171,23 @@ class Chat_title
150
171
  end
151
172
  end
152
173
 
174
+
153
175
  class Chat_content
154
- def initialize(api_key)
176
+ def initialize(api_key, gpt_content_prompt)
155
177
  @api_key = api_key
178
+ @gpt_content_prompt = gpt_content_prompt
156
179
  end
157
180
 
158
181
  def message(content)
182
+ puts 'Sending request to GPT...(내용 변형 중...)'
183
+ puts '주의:GPT 특성상 원고 길이가 공백 포함 4천자를 넘기면 오류가 발생할 수 있습니다.'
184
+ # "키워드 기반 글 생성 중..." 메시지를 별도 스레드로 처리
185
+ thread = Thread.new do
186
+ while true
187
+ print "▶"
188
+ sleep(3)
189
+ end
190
+ end
159
191
 
160
192
  url = 'https://api.openai.com/v1/chat/completions'
161
193
  headers = {
@@ -170,15 +202,16 @@ class Chat_content
170
202
  },
171
203
  {
172
204
  "role" => "user",
173
- "content" => "#{content}\nChatGPT의 멘트는 빼고 위 전체적인 내용의 형식을 똑같이 표현을 더 추가하고 유사어로 변경하여 하나 만들어줘! 전화번호,연락처,가격,홈페이지안내 ,상담안내 관련 문구는 유지해야해"
205
+ "content" => "#{@gpt_content_prompt}\n#{content}"
206
+
174
207
  }]
175
208
  }
176
209
 
177
210
  begin
178
211
  req = HTTP.headers(headers).post(url, json: data)
179
- puts "HTTP Status: #{req.status}" # 상태 코드 확인
212
+
180
213
  response = JSON.parse(req.body.to_s)
181
- puts "API Response: #{response}" # 전체 응답 출력
214
+
182
215
 
183
216
  if req.status == 429
184
217
  return "API 요청 제한을 초과했습니다. 플랜 및 할당량을 확인하세요."
@@ -192,6 +225,9 @@ class Chat_content
192
225
  answer = "오류가 발생했습니다."
193
226
  end
194
227
 
228
+ # "생성 중..." 메시지 출력 종료
229
+ thread.kill
230
+
195
231
  puts 'API return ==> '
196
232
  puts answer
197
233
  answer
@@ -199,6 +235,7 @@ class Chat_content
199
235
  end
200
236
 
201
237
 
238
+
202
239
  #############################################gpt############################################
203
240
 
204
241
  class Naver
@@ -297,6 +334,7 @@ class Naver
297
334
 
298
335
 
299
336
 
337
+
300
338
  def login(user_id, user_pw, proxy)
301
339
  @user_id = user_id
302
340
  @user_id11 = user_id
@@ -401,7 +439,7 @@ class Naver
401
439
  end
402
440
  end
403
441
  return 0
404
- @driver.quit
442
+ @driver.quit
405
443
  end
406
444
  end
407
445
 
@@ -701,6 +739,7 @@ class Naver
701
739
  rescue
702
740
  end
703
741
 
742
+
704
743
  begin
705
744
  #제목 입력
706
745
  wait = Selenium::WebDriver::Wait.new(:timeout => 10)
@@ -717,9 +756,9 @@ class Naver
717
756
  puts "Failed to close tab: #{e.message}"
718
757
  end
719
758
  end
720
- return 0
721
- @driver.quit
722
- end
759
+ return 0
760
+ @driver.quit
761
+ end
723
762
 
724
763
  ele = @driver.find_element(:xpath, '//*[@draggable="false"]')
725
764
  @driver.action.click(ele).perform
@@ -1626,10 +1665,10 @@ class Naver
1626
1665
  return 0
1627
1666
  @driver.quit
1628
1667
  end
1629
-
1630
1668
 
1631
1669
 
1632
-
1670
+
1671
+
1633
1672
  category = option['category']
1634
1673
  begin
1635
1674
  p category
@@ -1715,6 +1754,7 @@ class Naver
1715
1754
 
1716
1755
  # puts data['documentModel'] = data['documentModel'].to_json
1717
1756
 
1757
+
1718
1758
  if option['발행'] == '2' #저장
1719
1759
  sleep(dd_time.to_i)
1720
1760
  @driver.find_element(:xpath, '//*[@class="save_btn__bzc5B"]').click
@@ -1791,7 +1831,7 @@ class Naver
1791
1831
 
1792
1832
  end
1793
1833
 
1794
-
1834
+
1795
1835
 
1796
1836
  end
1797
1837
  end
@@ -2403,56 +2443,44 @@ class Wordpress
2403
2443
 
2404
2444
  # ADB 서버 초기화
2405
2445
  puts 'adb kill-server'
2406
- Open3.capture3('adb kill-server')
2407
- sleep(2)
2446
+ Open3.capture3('./adb kill-server')
2447
+ sleep(3)
2408
2448
 
2409
2449
  # 다시 ADB 서버 실행
2410
2450
  puts 'adb start-server'
2411
- Open3.capture3('adb start-server')
2412
- sleep(2)
2451
+ Open3.capture3('./adb start-server')
2452
+ sleep(3)
2413
2453
 
2414
2454
  # 데이터를 끄고 켜기
2415
2455
  puts 'adb -s ' + device_id + ' shell svc data disable'
2416
- stdout2, stderr2, status2 = Open3.capture3('./adb -s ' + device_id + ' shell svc data disable')
2417
-
2418
- if status2.success?
2419
- sleep(3)
2420
- puts 'adb -s ' + device_id + ' shell svc data enable'
2421
- Open3.capture3('./adb -s ' + device_id + ' shell svc data enable')
2422
- sleep(3)
2423
- puts 'adb ok'
2424
- sleep(8)
2425
-
2426
- # IP 변경을 확인하는 람다 함수
2427
- robot_ip = lambda do
2428
- loop do # 무한 루프
2429
- begin
2430
- http = HTTP.get('https://www.findip.kr/')
2431
- noko = Nokogiri::HTML(http.to_s)
2432
- new_ip = noko.xpath('/html/body/header/h2').text.strip
2433
-
2434
- if new_ip != @my_ip
2435
- @my_ip = new_ip
2436
- puts "IP 변경됨: #{@my_ip}"
2437
- break # IP가 변경되었으면 루프 종료
2438
- else
2439
- puts 'IP가 변경되지 않음. 재시도...'
2440
- sleep(3) # 3초 후 재시도
2441
- end
2442
- rescue => e
2443
- puts "IP 확인 중 오류 발생: #{e.message}. 재시도 중..."
2444
- sleep(3) # 3초 후 재시도
2445
- end
2446
- end
2456
+ stdout2, stderr2, status2 = Open3.capture3('./adb -s '+device_id+' shell svc data disable')
2457
+ sleep(3)
2458
+ puts 'adb -s ' + device_id + ' shell svc data enable'
2459
+ Open3.capture3('./adb -s '+device_id+' shell svc data enable')
2460
+ sleep(3)
2461
+ puts 'adb ok'
2462
+ sleep(8)
2463
+
2464
+ robot_ip = lambda do
2465
+ http = HTTP.get('https://www.findip.kr/')
2466
+ noko = Nokogiri::HTML(http.to_s)
2467
+ if noko.xpath('/html/body/header/h2').text != @my_ip
2468
+ @my_ip = noko.xpath('/html/body/header/h2').text
2469
+ puts "IP 변경됨[ #{@my_ip} ]"
2470
+ else
2471
+ puts @my_ip
2472
+ puts '제시도...'
2473
+ sleep(3)
2474
+ robot_ip[]
2447
2475
  end
2448
- robot_ip[] # 최초 호출
2449
- else
2450
- puts 'Failed to disable data. Error: ' + stderr2
2451
- end
2476
+ end
2477
+ robot_ip[]
2478
+
2452
2479
  else
2453
- puts 'adb error, unable to get devices. Error: ' + stderr
2480
+ puts 'adb error pass'
2454
2481
  end
2455
- end
2482
+ end
2483
+
2456
2484
 
2457
2485
  check_success = 1
2458
2486
  @data['table'][index][-1] = 0
@@ -2471,10 +2499,19 @@ class Wordpress
2471
2499
  end
2472
2500
 
2473
2501
  if @data['포스트설정']['gpt제목'].checked?
2474
- chat = Chat_title.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'))
2502
+ gpt_title_prompt = @data['포스트설정']['gpt제목_프롬프트'].text.to_s.force_encoding('utf-8')
2503
+
2504
+ # 공백을 포함한 빈 문자열을 체크하기 위해 strip을 사용
2505
+ gpt_title_prompt_sample = gpt_title_prompt.strip.empty? ? "프롬프트: 문장을 비슷한 길이로 ChatGPT의 멘트는 빼고 표현을 더 추가해서 하나만 만들어줘." : gpt_title_prompt
2506
+
2507
+ # gpt_title_prompt_sample을 Chat_title 객체에 전달
2508
+ chat = Chat_title.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'), gpt_title_prompt_sample)
2509
+
2510
+ # 메시지 요청 후 title에 저장
2475
2511
  gpt_text1 = chat.message(title)
2476
2512
  title = gpt_text1.to_s
2477
2513
  end
2514
+
2478
2515
 
2479
2516
 
2480
2517
  @data['table'][index][-1] = 5
@@ -2517,18 +2554,16 @@ class Wordpress
2517
2554
 
2518
2555
 
2519
2556
  if @data['포스트설정']['gpt내용'].checked?
2557
+ gpt_content_prompt = @data['포스트설정']['gpt내용_프롬프트'].text.to_s.force_encoding('utf-8')
2520
2558
  api_key = @data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8')
2521
- #key_change = @data['포스트설정']['특정단어키워드로변경값'].text.to_s.force_encoding('utf-8')
2522
- #imotcon_change = @data['포스트설정']['스티커로변경단어'].text.to_s.force_encoding('utf-8')
2523
- #template_change = @data['포스트설정']['내템플릿변경단어'].text.to_s.force_encoding('utf-8')
2524
- #ttdanar_change = @data['포스트설정']['단어링크적용단어'].text.to_s.force_encoding('utf-8')
2525
- #sajine_change = @data['포스트설정']['단어사진으로변경단어'].text.to_s.force_encoding('utf-8')
2526
- #mov_change = @data['포스트설정']['영상으로변경단어'].text.to_s.force_encoding('utf-8')
2527
- #map_change = @data['포스트설정']['지도로변경단어'].text.to_s.force_encoding('utf-8')
2528
- #inyong9_change = @data['포스트설정']['인용구변경단어'].text.to_s.force_encoding('utf-8')
2529
-
2530
2559
 
2531
- chat = Chat_content.new(api_key)
2560
+ # 공백을 포함한 빈 문자열을 체크하기 위해 strip을 사용
2561
+ gpt_content_prompt_sample = gpt_content_prompt.strip.empty? ? "프롬프트:ChatGPT의 멘트는 빼고 위 전체적인 내용의 형식을 똑같이 표현을 더 추가하고 유사어로 변경하여 하나 만들어줘! 전화번호,연락처,가격,홈페이지안내 ,상담안내 관련 문구는 유지해야해" : gpt_content_prompt
2562
+
2563
+ # Chat_content 객체 생성 시 api_key와 gpt_content_prompt_sample을 두 개의 인자로 전달
2564
+ chat = Chat_content.new(api_key, gpt_content_prompt_sample)
2565
+
2566
+ # 메시지 요청 후 content에 저장
2532
2567
  gpt_text3 = chat.message(content)
2533
2568
  content = gpt_text3.to_s
2534
2569
  end
@@ -2732,13 +2767,17 @@ class Wordpress
2732
2767
  @data['table'] << []
2733
2768
  @data['table'].pop
2734
2769
  if @data['포스트설정']['gpt키워드'].checked?
2735
- chat = Chat.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'))
2770
+ gpt_keyword_prompt = @data['포스트설정']['gpt키워드_프롬프트'].text.to_s.force_encoding('utf-8')
2771
+ gpt_keyword_prompt_sample = gpt_keyword_prompt.strip.empty? ? "프롬프트: 관련된 글을 1500자에서 2500자 사이로 만들어줘" : gpt_keyword_prompt
2772
+ chat = Chat.new(@data['포스트설정']['api_key'].text.to_s.force_encoding('utf-8'), gpt_keyword_prompt)
2736
2773
  gpt_text = chat.message(keyword)
2737
- content = content.to_s + "\n(자동생성글)\n" + gpt_text.to_s
2774
+ #content = content.to_s + "\n(자동생성글)\n" + gpt_text.to_s
2775
+ content = content.to_s + "(자동생성글)" + gpt_text.to_s
2738
2776
  elsif @data['포스트설정']['내용을자동생성'].checked?
2739
2777
  content = auto_text
2740
2778
  elsif @data['포스트설정']['내용과자동생성'].checked?
2741
- content = content + "\n(자동생성글)\n" + auto_text
2779
+ #content = content + "\n(자동생성글)\n" + auto_text
2780
+ content = content + "(자동생성글)" + auto_text
2742
2781
  end
2743
2782
 
2744
2783
  if @data['포스트설정']['내용키워드삽입'].checked?
@@ -2773,7 +2812,8 @@ class Wordpress
2773
2812
  end
2774
2813
 
2775
2814
  if @data['포스트설정']['내용을자동생성'].checked?
2776
- content2 = content.split("\n")
2815
+ #content2 = content.split("\n")
2816
+ content2 = content.split
2777
2817
  end
2778
2818
 
2779
2819
  if @data['포스트설정']['내용과자동생성'].checked? or @data['포스트설정']['gpt키워드'].checked?
@@ -4094,6 +4134,11 @@ class Wordpress
4094
4134
  }
4095
4135
  }
4096
4136
  } }
4137
+ horizontal_box{
4138
+ stretchy false
4139
+ @data['포스트설정']['gpt키워드_프롬프트'] = entry(){
4140
+ text '프롬프트:관련 글을 1500자에서 2500자 사이로 만들어줘'
4141
+ }}
4097
4142
  horizontal_box{
4098
4143
  stretchy false
4099
4144
  grid{
@@ -4210,6 +4255,11 @@ class Wordpress
4210
4255
 
4211
4256
 
4212
4257
  }}}
4258
+ horizontal_box{
4259
+ stretchy false
4260
+ @data['포스트설정']['gpt제목_프롬프트'] = entry(){
4261
+ text '프롬프트:비슷한 길이로 제목으로 사용할수있게 하나만 만들어줘'
4262
+ }}
4213
4263
  horizontal_box{
4214
4264
  stretchy false
4215
4265
  grid{
@@ -4323,6 +4373,11 @@ class Wordpress
4323
4373
 
4324
4374
 
4325
4375
  }}}
4376
+ horizontal_box{
4377
+ stretchy false
4378
+ @data['포스트설정']['gpt내용_프롬프트'] = entry(){
4379
+ text '프롬프트:동의어,유사어를 이용해 변경해줘'
4380
+ }}
4326
4381
  horizontal_box{
4327
4382
  stretchy false
4328
4383
  grid{
@@ -4932,7 +4987,7 @@ class Wordpress
4932
4987
  left 1
4933
4988
  text 'URL'
4934
4989
  }
4935
- @data['포스트설정']['내용을자동생성'] = checkbox('키워드기반 생성으로만 등록(GPT사용시 자체 생성)'){
4990
+ @data['포스트설정']['내용을자동생성'] = checkbox('키워드기반 글만 등록(GPT사용시 체크 해제)'){
4936
4991
  top 9
4937
4992
  left 0
4938
4993
  on_toggled{
@@ -4944,10 +4999,19 @@ class Wordpress
4944
4999
  end
4945
5000
  }
4946
5001
  }
4947
-
4948
-
5002
+ label('※GPT사용시 내용설정 탭에서 설정'){
5003
+ top 9
5004
+ left 1
5005
+ }
5006
+
5007
+ label('※GPT 미 사용시 세팅 권장'){
5008
+ top 9
5009
+ left 3
5010
+ }
5011
+
5012
+
4949
5013
  aa1 = 2
4950
- @data['포스트설정']['내용과자동생성'] = checkbox('내용파일+키워드기반 생성 등록(GPT사용시 자체 생성)') {
5014
+ @data['포스트설정']['내용과자동생성'] = checkbox('원고+키워드기반 등록(GPT사용시 체크 해제)') {
4951
5015
  top 10 + aa1
4952
5016
  left 0
4953
5017
  on_toggled {
@@ -4963,7 +5027,14 @@ class Wordpress
4963
5027
  end
4964
5028
  }
4965
5029
  }
4966
-
5030
+ label('※GPT사용시 내용설정 탭에서 설정'){
5031
+ top 10 + aa1
5032
+ left 1
5033
+ }
5034
+ label('※GPT 미 사용시 세팅 권장'){
5035
+ top 10 + aa1
5036
+ left 3
5037
+ }
4967
5038
  @data['포스트설정']['내용투명'] = checkbox('키워드 기반 자동 생성글 안보이게 처리') {
4968
5039
  top 11 + aa1
4969
5040
  left 0
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nblog_duo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.67
4
+ version: 0.0.79
5
5
  platform: ruby
6
6
  authors:
7
7
  - zon
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-02-12 00:00:00.000000000 Z
11
+ date: 2025-02-13 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: File to Clipboard gem
14
14
  email: mymin26@naver.com