본문 바로가기
오늘의 자연어 처리

[2023-09-08] 오늘의 자연어처리

by 지환이아빠 2023. 9. 8.
반응형

Offensive Hebrew Corpus and Detection using BERT

 

Offensive language detection has been well studied in many languages, but it is lagging behind in low-resource languages, such as Hebrew. In this paper, we present a new offensive language corpus in Hebrew. A total of 15,881 tweets were retrieved from Twitter. Each was labeled with one or more of five classes (abusive, hate, violence, pornographic, or none offensive) by Arabic-Hebrew bilingual speakers. The annotation process was challenging as each annotator is expected to be familiar with the Israeli culture, politics, and practices to understand the context of each tweet. We fine-tuned two Hebrew BERT models, HeBERT and AlephBERT, using our proposed dataset and another published dataset. We observed that our data boosts HeBERT performance by 2% when combined with D_OLaH. Fine-tuning AlephBERT on our data and testing on D_OLaH yields 69% accuracy, while fine-tuning on D_OLaH and testing on our data yields 57% accuracy, which may be an indication to the generalizability our data offers. Our dataset and fine-tuned models are available on GitHub and Huggingface.

 

모욕적인 언어 탐지는 많은 언어에서 잘 연구되어 왔지만 히브리어와 같은 저자원 언어에서 뒤처지고 있다. 이 논문에서 우리는 히브리어로 새로운 모욕적인 언어 말뭉치를 제시하다. 총 15,881개의 트윗이 있다 트위터에서 검색했습니다. 각각은 5개의 클래스 중 하나 또는 그 이상으로 레이블이 지정되었습니다 (학대, 증오, 폭력, 포르노, 또는 전혀 모욕적이지 않은) 아랍어-히브류의 이중 언어 구사자. 주석 과정은 각 주석자들이 힘들었기 때문이다 이스라엘의 문화, 정치, 그리고 실천에 익숙할 것으로 기대된다 각 트윗의 맥락을 이해합니다. 히브리어 BERT 모델 두 개를 미세 조정했는데, 제안된 데이터 세트와 다른 게시된 데이터 세트를 사용하여 HeBERT와 AlephBERT. 우리는 우리의 데이터가 다음과 결합할 때 HeBERT 성능을 2% 향상시킨다는 것을 관찰했다 D_OLAH. 데이터에 대한 AlephBERT 미세 조정 및 D_OLAH 테스트를 통해 69%의 성과 달성 D_OLAH를 미세 조정하고 데이터 테스트를 통해 57%의 정확도를 얻을 수 있습니다 정확성은 우리 데이터가 제공하는 일반화 가능성에 대한 표시일 수 있습니다. 우리의 데이터 세트와 미세 조정된 모델은 깃허브와 허깅페이스에서 이용할 수 있다. 

 

 

Certifying LLM Safety against Adversarial Prompting

 

Large language models (LLMs) released for public use incorporate guardrails to ensure their output is safe, often referred to as "model alignment." An aligned language model should decline a user's request to produce harmful content. However, such safety measures are vulnerable to adversarial prompts, which contain maliciously designed token sequences to circumvent the model's safety guards and cause it to produce harmful content. In this work, we introduce erase-and-check, the first framework to defend against adversarial prompts with verifiable safety guarantees. We erase tokens individually and inspect the resulting subsequences using a safety filter. Our procedure labels the input prompt as harmful if any subsequences or the input prompt are detected as harmful by the filter. This guarantees that any adversarial modification of a harmful prompt up to a certain size is also labeled harmful. We defend against three attack modes: i) adversarial suffix, which appends an adversarial sequence at the end of the prompt; ii) adversarial insertion, where the adversarial sequence is inserted anywhere in the middle of the prompt; and iii) adversarial infusion, where adversarial tokens are inserted at arbitrary positions in the prompt, not necessarily as a contiguous block. Empirical results demonstrate that our technique obtains strong certified safety guarantees on harmful prompts while maintaining good performance on safe prompts. For example, against adversarial suffixes of length 20, it certifiably detects 93% of the harmful prompts and labels 94% of the safe prompts as safe using the open source language model Llama 2 as the safety filter.

 

공용으로 출시된 대형 언어 모델(LLM)에는 가드레일이 통합되어 있습니다 출력물의 안전성을 보장하기 위해 "모델 정렬"이라고도 합니다 안 정렬된 언어 모델은 유해한 언어를 생성하기 위한 사용자의 요청을 거절해야 한다 만족할 만한. 그러나 그러한 안전조치는 적대적인 지시에 취약하다, 악의적으로 설계된 토큰 시퀀스를 포함하고 있습니다 안전요원을 배치하여 유해한 내용물을 생성하게 한다. 이번 작업에서는 저희가 적국을 방어하기 위한 최초의 틀인 삭제와 견제를 도입하다 확인 가능한 안전 보장 메시지가 표시됩니다. 우리는 토큰을 개별적으로 지우고 안전 필터를 사용하여 결과를 검사한다. 당사의 절차 레이블 입력 프롬프트는 어떤 후속 프로그램이나 입력 프롬프트가 있는 경우 유해한 것으로 간주됩니다 필터에 의해 유해한 것으로 감지됩니다. 이것은 어떤 적대적인 것도 보장한다 특정 크기까지 유해한 프롬프트를 수정하는 것도 유해하다고 표시됩니다. 우리는 세 가지 공격 모드로부터 방어한다: i) 적대적 접미사는 다음과 같다 프롬프트 끝의 적대적 시퀀스; ii) 적대적 삽입, 여기서 적대적 시퀀스는 프롬프트의 중간에 삽입된다 iii) 적대적 토큰을 임의로 삽입하는 적대적 주입 프롬프트의 위치, 반드시 연속적인 블록으로서는 아닙니다. 경험적 결과는 우리의 기술이 강력한 인증된 안전성을 얻는다는 것을 보여준다 안전한 상태에서 양호한 성능을 유지하면서 유해한 프롬프트에 대한 보장 프롬프트가 표시됩니다. 예를 들어, 길이 20의 대립 접미사에 대해 증명 가능하게 유해 프롬프트의 93%를 감지하고 안전 프롬프트의 94%를 안전한 것으로 표시합니다 오픈 소스 언어 모델 라마 2를 안전 필터로 사용한다. 

 

 

Leave no Place Behind: Improved Geolocation in Humanitarian Documents

 

Geographical location is a crucial element of humanitarian response, outlining vulnerable populations, ongoing events, and available resources. Latest developments in Natural Language Processing may help in extracting vital information from the deluge of reports and documents produced by the humanitarian sector. However, the performance and biases of existing state-of-the-art information extraction tools are unknown. In this work, we develop annotated resources to fine-tune the popular Named Entity Recognition (NER) tools Spacy and roBERTa to perform geotagging of humanitarian texts. We then propose a geocoding method FeatureRank which links the candidate locations to the GeoNames database. We find that not only does the humanitarian-domain data improves the performance of the classifiers (up to F1 = 0.92), but it also alleviates some of the bias of the existing tools, which erroneously favor locations in the Western countries. Thus, we conclude that more resources from non-Western documents are necessary to ensure that off-the-shelf NER systems are suitable for the deployment in the humanitarian sector.

 

지리적 위치는 인도주의적 대응의 중요한 요소이다, 취약한 모집단, 진행 중인 이벤트 및 사용 가능한 리소스의 개요를 설명합니다. 자연어 처리의 최신 발전은 중요한 것을 추출하는 데 도움을 줄 수 있다 보고서와 문서의 홍수로부터 정보는 인도주의적 부문. 그러나 기존의 성능과 편향은 최첨단 정보 추출 도구는 알려지지 않았다. 이번 작업에서는 저희가 주석이 달린 자원을 개발하여 인기 있는 명명된 개체 인식을 미세 조정한다 (NER) Spacy와 roBERTA는 인도주의 텍스트의 지오태깅을 수행하는 도구이다. 우리가 그런 다음 후보 위치를 연결하는 지오코딩 방법 FeatureRank를 제안한다 GeoNames 데이터베이스로 이동할 수 있습니다. 우리는 인도주의적 영역만이 아니라는 것을 발견했다 데이터는 분류기의 성능을 향상시키지만(F1 = 0.92까지), 또한 기존 도구의 일부 편향을 완화합니다. 이는 잘못 선호합니다 서구 국가들의 위치들. 따라서, 우리는 더 많은 자원이 기성품 NER 시스템을 보장하기 위해서는 비서구 문서가 필요하다 인도주의 분야에 배치하기에 적합하다. 

 

 

반응형

댓글